BookmarkSubscribeRSS Feed
Romilson
Calcite | Level 5

Boa noite! Estou com problemas pra uso do sas com o colab ou jupyter notebook, pois esta aparencendo esse erro abaixo:

 
!pip install saspy
 
import saspy
 
Cheguei a colocar também um parâmetro aqui ( )- cfgname='default'
sas_session = saspy.SASsession()   

 

Using SAS Config named: default
The OS Error was:
No such file or directory
SAS Connection failed. No connection established. Double check your settings in sascfg_personal.py file.
Attempted to run program /opt/sasinside/SASHome/SASFoundation/9.4/bin/sas_u8 with the following parameters:['/opt/sasinside/SASHome/SASFoundation/9.4/bin/sas_u8', '-nodms', '-stdio', '-terminal', '-nosyntaxcheck', '-pagesize', 'MAX', '']
If no OS Error above, try running the following command (where saspy is running) manually to see what is wrong:
/opt/sasinside/SASHome/SASFoundation/9.4/bin/sas_u8 -nodms -stdio -terminal -nosyntaxcheck -pagesize MAX  

SAS Connection failed. No connection established. Double check your settings in sascfg_personal.py file.
Attempted to run program /opt/sasinside/SASHome/SASFoundation/9.4/bin/sas_u8 with the following parameters:['/opt/sasinside/SASHome/SASFoundation/9.4/bin/sas_u8', '-nodms', '-stdio', '-terminal', '-nosyntaxcheck', '-pagesize', 'MAX', '']
Try running the following command (where saspy is running) manually to see if you can get more information on what went wrong:
/opt/sasinside/SASHome/SASFoundation/9.4/bin/sas_u8 -nodms -stdio -terminal -nosyntaxcheck -pagesize MAX  

No SAS process attached. SAS process has terminated unexpectedly.
Invalid response from SAS on inital submission. printing the SASLOG as diagnostic

---------------------------------------------------------------------------
SASIOConnectionError                      Traceback (most recent call last)
<ipython-input-37-96d33f5d856e> in <module>
----> 1 sas_session = saspy.SASsession()

/usr/local/lib/python3.9/dist-packages/saspy/sasbase.py in __init__(self, **kwargs)
    606 
    607            if failed:
--> 608               raise SASIOConnectionError(res)
    609 
    610            if self.pyenc is not None:

SASIOConnectionError: Failure establishing SASsession.
No SAS process attached. SAS process has terminated unexpectedly.



1 REPLY 1
sastpw
SAS Employee

You have to configure SASPy to know where SAS is and how to connect to it.

 

Error:

The OS Error was:
No such file or directory
SAS Connection failed. No connection established. Double check your settings in sascfg_personal.py file.
Attempted to run program /opt/sasinside/SASHome/SASFoundation/9.4/bin/sas_u8 

/opt/tsasinside/SASHomeSASFoundation/9.4/bin/sas_u8 isn't on the machine you're trying to use. 

 

See the configuration documentation here: https://sassoftware.github.io/saspy/configuration.html#