Admin
Maybe another __init__.py in the src folder too
Votes
0
Replies
24
Participants
Unknown
Messages
25
Admin
Maybe another __init__.py in the src folder too
Rank 2: Process
but i already put __init__.py in src
Admin
Sorry I meant the url gen folder
Rank 2: Process
locally still the same error
Admin
I wonder if that space in the folder name is giving it problems 🧐
Rank 2: Process
let me try without space then
Rank 2: Process
Rank 2: Process
Rank 2: Process
now the folder name is urlGen_S4
Rank 2: Process
Rank 2: Process
i'm trying to do this way but still shows error
Rank 2: Process
this is when i did same locally (using sntwitter part)
Admin
Why can't you install this using requirements.txt?
Rank 2: Process
Rank 2: Process
pip3 install git+https://github.com/JustAnotherArchivist/snscrape.git
Admin
No...not with git
Rank 2: Process
currently this is dev version of the package that works
Rank 2: Process
so when put git+https://github.com/JustAnotherArchivist/snscrape.git in requirements.txt it's shows build error
Admin
No, install it normally like any other pypi package
Rank 2: Process
normally i just put snscrape in requirements.txt but the current version of this package shows some error so the developer suggested to use this git+https://github.com/JustAnotherArchivist/snscrape.git
Rank 2: Process
@Steven it finally imported it
Rank 2: Process
Admin
i meant to do this:
Admin
output
Admin
ok...i know why the relative import didn't work now. the stacktrace is:
Traceback (most recent call last):
File "/usr/local/src/userlib/src/index.py", line 8, in main
from .snscrape.modules import twitter as sntwitter
File "/usr/local/src/userlib/src/snscrape/modules/__init__.py", line 17, in <module>
_import_modules()
File "/usr/local/src/userlib/src/snscrape/modules/__init__.py", line 13, in _import_modules
module = importer.find_module(moduleName).load_module(moduleName)
File "/usr/local/src/userlib/src/snscrape/modules/facebook.py", line 10, in <module>
import snscrape.base
They try to find the module from the global scope, which won't show up