DIGITALCRIMINAL / ArchivedUltimaScraper

Scrape content from OnlyFans and Fansly
GNU General Public License v3.0
948 stars 39 forks source link

temp_json_auth["auth"] - OF #324

Closed d3ibis closed 2 years ago

d3ibis commented 2 years ago

Downloaded latest code, entered all details in auth, started it & got this:

Choose Sites: 0 = All | 1 = OnlyFans | 2 = Fansly | 3 = StarsAVN 1 Traceback (most recent call last): File "/Users/d3ibis/Downloads/OnlyFans/start_ofd.py", line 66, in asyncio.run(main()) File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/asyncio/runners.py", line 44, in run return loop.run_until_complete(main) File "/Library/Frameworks/Python.framework/Versions/3.10/lib/python3.10/asyncio/base_events.py", line 641, in run_until_complete return future.result() File "/Users/d3ibis/Downloads/OnlyFans/start_ofd.py", line 52, in main api = await main_datascraper.start_datascraper(config, site_name) File "/Users/d3ibis/Downloads/OnlyFans/datascraper/main_datascraper.py", line 129, in start_datascraper await default(datascraper) File "/Users/d3ibis/Downloads/OnlyFans/datascraper/main_datascraper.py", line 55, in default await main_helper.process_profiles(api, global_settings) File "/Users/d3ibis/Downloads/OnlyFans/helpers/main_helper.py", line 976, in process_profiles json_auth = temp_json_auth["auth"] KeyError: 'auth'

any ideas ? ThanQ <3

dunkethee commented 2 years ago

Are you on Mac OS? It looks like the issue involves including .DS_Store in a list of folders when it shouldn't be.

Fix:

In helpers/main_helper.py, find the function remove_mandatory_files (starts at line 1181 in current version). In that function, change the line (1183) from:

folders = [x for x in files if x not in matches]

to:

folders = [x for x in files if x.name not in matches]

d3ibis commented 2 years ago

Are you on Mac OS? It looks like the issue involves including .DS_Store in a list of folders when it shouldn't be.

Fix:

In helpers/main_helper.py, find the function remove_mandatory_files (starts at line 1181 in current version). In that function, change the line (1183) from:

folders = [x for x in files if x not in matches]

to:

folders = [x for x in files if x.name not in matches]

Yes I'm on mac, downloaded previous release and now working normally, will try ur solution, ThanQ!

d3ibis commented 2 years ago

Worked, ThanQ!

Nick05491 commented 2 years ago

@DIGITALCRIMINALS can we implement this fix for all users?

misterscraper commented 2 years ago

Are you on Mac OS? It looks like the issue involves including .DS_Store in a list of folders when it shouldn't be.

Fix:

In helpers/main_helper.py, find the function remove_mandatory_files (starts at line 1181 in current version). In that function, change the line (1183) from:

folders = [x for x in files if x not in matches]

to:

folders = [x for x in files if x.name not in matches]

this fixed my issue!