Closed raffaem closed 2 years ago
Which version are you using?
Thanks for the fast answer
Which version are you using?
$ python
Python 3.10.1 (tags/v3.10.1:2cd268a, Dec 6 2021, 19:10:37) [MSC v.1929 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import pybliometrics
>>> print(pybliometrics.__version__)
3.1.0
I'm pretty sure the issue is that the config.ini
file is not in the same drive as the python script that uses pybliometrics.
I moved the Python script to the same drive of config.ini and it fixed the issue.
Or it may have been that the python script was on a network shared folder with UNC path.
I'm almost certain it's the latter. We had this issue too. Turned out to be two different home directories. You can check that with pybliometrics.scopus.CONFIG_FILE
from different locations.
so the gist is: don't put you python scripts in a network shared folder?
should we write that in the docs?
Nada, looks like it's the exact same config file:
Microsoft Windows [Versione 10.0.19041.1348]
rdpclient@XXXXXXXX C:\Users\rdpclient
$ python
Python 3.10.1 (tags/v3.10.1:2cd268a, Dec 6 2021, 19:10:37) [MSC v.1929 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import pybliometrics
>>> pybliometrics.scopus.CONFIG_FILE
WindowsPath('C:/Users/rdpclient/.pybliometrics/config.ini')
>>> exit()
rdpclient@XXXXX C:\Users\rdpclient
$ pushd XXXXXX
rdpclient@XXXX Y:\
$ python
Python 3.10.1 (tags/v3.10.1:2cd268a, Dec 6 2021, 19:10:37) [MSC v.1929 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import pybliometrics
>>> pybliometrics.scopus.CONFIG_FILE
WindowsPath('C:/Users/rdpclient/.pybliometrics/config.ini')
Turned out I didn't fix this bug as I though previously. But now it is :)
Must have been frightening for first-time users to get this long traceback upon creation of the configuration file - even though it would work on the second attempt.