UltimaScraper icon indicating copy to clipboard operation
UltimaScraper copied to clipboard

'process_json_metadata' is not defined

Open Kurosaki22 opened this issue 5 years ago • 13 comments

Hi there,

Im receiving the following error from the latest commit:

Traceback (most recent call last): File "G:\Photo_OF_Scraper\OnlyFans\start_ofd.py", line 40, in main_datascraper.start_datascraper(json_config, site_name_lower) File "G:\Photo_OF_Scraper\OnlyFans\datascraper\main_datascraper.py", line 82, in start_datascraper paid_content = module.paid_content_scraper(apis) File "G:\Photo_OF_Scraper\OnlyFans\modules\onlyfans.py", line 343, in paid_content_scraper new_metadata_object, delete_metadatas = process_json_metadata( NameError: name 'process_json_metadata' is not defined

Kurosaki22 avatar Jan 06 '21 14:01 Kurosaki22

Set scrape_paid_content to false for now

UltimaHoarder avatar Jan 06 '21 14:01 UltimaHoarder

When I set it to false it will continue for a short time until this error shows up:

Traceback (most recent call last): File "G:\Photo_OF_Scraper\OnlyFans\start_ofd.py", line 40, in main_datascraper.start_datascraper(json_config, site_name_lower) File "G:\Photo_OF_Scraper\OnlyFans\datascraper\main_datascraper.py", line 85, in start_datascraper x = main_helper.process_names( File "G:\Photo_OF_Scraper\OnlyFans\helpers\main_helper.py", line 519, in process_names result = module.start_datascraper( File "G:\Photo_OF_Scraper\OnlyFans\modules\onlyfans.py", line 148, in start_datascraper results = prepare_scraper( File "G:\Photo_OF_Scraper\OnlyFans\modules\onlyfans.py", line 665, in prepare_scraper unrefined_set = pool.starmap(media_scraper, product( File "C:\Users\oehy2\AppData\Local\Programs\Python\Python39-32\lib\multiprocessing\pool.py", line 372, in starmap return self._map_async(func, iterable, starmapstar, chunksize).get() File "C:\Users\oehy2\AppData\Local\Programs\Python\Python39-32\lib\multiprocessing\pool.py", line 771, in get raise self._value File "C:\Users\oehy2\AppData\Local\Programs\Python\Python39-32\lib\multiprocessing\pool.py", line 125, in worker result = (True, func(*args, **kwds)) File "C:\Users\oehy2\AppData\Local\Programs\Python\Python39-32\lib\multiprocessing\pool.py", line 51, in starmapstar return list(itertools.starmap(args[0], args[1])) File "G:\Photo_OF_Scraper\OnlyFans\modules\onlyfans.py", line 892, in media_scraper new_post["text"] = media_api["rawText"] KeyError: 'rawText'

Kurosaki22 avatar Jan 06 '21 15:01 Kurosaki22

Yee, I've fixed that on my end but I haven't pushed the commit yet

UltimaHoarder avatar Jan 06 '21 15:01 UltimaHoarder

Should be fixed in the latest commit. You can turn it back on.

UltimaHoarder avatar Jan 06 '21 15:01 UltimaHoarder

Receiving this error now:

Traceback (most recent call last): File "G:\Photo_OF_Scraper\OnlyFans\start_ofd.py", line 40, in main_datascraper.start_datascraper(json_config, site_name_lower) File "G:\Photo_OF_Scraper\OnlyFans\datascraper\main_datascraper.py", line 82, in start_datascraper paid_content = module.paid_content_scraper(apis) File "G:\Photo_OF_Scraper\OnlyFans\modules\onlyfans.py", line 343, in paid_content_scraper new_metadata = media_scraper(paid_content, api, File "G:\Photo_OF_Scraper\OnlyFans\modules\onlyfans.py", line 903, in media_scraper if not media_api["canPurchase"]: KeyError: 'canPurchase'

Kurosaki22 avatar Jan 06 '21 15:01 Kurosaki22

Which model was it scraping and do you know if it was a post or an message?

UltimaHoarder avatar Jan 06 '21 16:01 UltimaHoarder

not sure if the lines directly above it are the right one

Scraping - jessicanigri | 10 / 24 Scraping [photo]. Should take less than a minute. Traceback (most recent call last): File "G:\Photo_OF_Scraper\OnlyFans\start_ofd.py", line 40, in main_datascraper.start_datascraper(json_config, site_name_lower) File "G:\Photo_OF_Scraper\OnlyFans\datascraper\main_datascraper.py", line 82, in start_datascraper paid_content = module.paid_content_scraper(apis) File "G:\Photo_OF_Scraper\OnlyFans\modules\onlyfans.py", line 343, in paid_content_scraper new_metadata = media_scraper(paid_content, api, File "G:\Photo_OF_Scraper\OnlyFans\modules\onlyfans.py", line 903, in media_scraper if not media_api["canPurchase"]: KeyError: 'canPurchase'

Kurosaki22 avatar Jan 06 '21 16:01 Kurosaki22

Have you bought any of her paid posts?

UltimaHoarder avatar Jan 06 '21 16:01 UltimaHoarder

Nevermind, I've got the error

UltimaHoarder avatar Jan 06 '21 16:01 UltimaHoarder

Ok had to check. Was pretty long ago that i bought one of her posts

Kurosaki22 avatar Jan 06 '21 16:01 Kurosaki22

Try the latest commit

UltimaHoarder avatar Jan 06 '21 17:01 UltimaHoarder

Sorry had dinner. Working again. Thanks :)

Kurosaki22 avatar Jan 06 '21 17:01 Kurosaki22

Just noticed the issue was #666 lul

UltimaHoarder avatar Jan 06 '21 17:01 UltimaHoarder