Giter Club home page Giter Club logo

Comments (15)

mileyvirus avatar mileyvirus commented on May 30, 2024 1

EDIT

I found the post with the same ID of one who had the -001-11-30T00:00:00+00:00 date and it doesn't show a date on OnlyFans so it's probably a placeholder that means that no date was specified on upload or something. Usually the media URLs have the date inside but these faulty ones don't.

from ultimascraper.

mileyvirus avatar mileyvirus commented on May 30, 2024 1

Thank you, latest commits successfully caught the error and now my dump is complete!
You're on fire with this repo bruh 🔥

from ultimascraper.

UltimaHoarder avatar UltimaHoarder commented on May 30, 2024 1

I also forgot to mention that if the date matches the template date, the script will either use the last grabbed date OR use the 00-00-0000 date.

I forgot to add this feature in.

else:
      dt = datetime.fromisoformat(media_api["postedAt"]).replace(tzinfo=None).strftime(date_format)
      master_date = dt

I updated onlyfans.py

from ultimascraper.

UltimaHoarder avatar UltimaHoarder commented on May 30, 2024

An issue was open yesterday that they fixed this by updating to Python 3.7 (It's also the version I'm working with)

from ultimascraper.

mileyvirus avatar mileyvirus commented on May 30, 2024

I saw that but I'm on macOS and I also have Python 3.7 🤔

Python 3.7.3 (default, Mar 27 2019, 09:23:15) 
[Clang 10.0.1 (clang-1001.0.46.3)] on darwin

(I manually added #!/usr/bin/env python3 on top of the script)

from ultimascraper.

UltimaHoarder avatar UltimaHoarder commented on May 30, 2024

I see what's wrong with it.
It says this

-001-11-30

But it's supposed to be similar to this 01-11-30. I need to see a full dump. So I will update the script and message back to see if it fixes it

from ultimascraper.

mileyvirus avatar mileyvirus commented on May 30, 2024

Dude almost the same error… ☹
How can I help?

Photos Completed
Traceback (most recent call last):
  File "/OnlyFans.py", line 143, in media_scraper
    dt = datetime.fromisoformat(media_api["postedAt"]).replace(tzinfo=None).strftime('%d-%m-%Y')
ValueError: Invalid isoformat string: '-001-11-30T00:00:00+00:00'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/OnlyFans.py", line 223, in <module>
    scrape_choice()
  File "/OnlyFans.py", line 92, in scrape_choice
    media_scraper(video_api, location, j_directory, only_links)
  File "/OnlyFans.py", line 149, in media_scraper
    dt = datetime.strptime(found.replace("_", "-"), '%Y-%m-%d').strftime('%d-%m-%Y')
  File "/usr/local/Cellar/python/3.7.3/Frameworks/Python.framework/Versions/3.7/lib/python3.7/_strptime.py", line 577, in _strptime_datetime
    tt, fraction, gmtoff_fraction = _strptime(data_string, format)
  File "/usr/local/Cellar/python/3.7.3/Frameworks/Python.framework/Versions/3.7/lib/python3.7/_strptime.py", line 359, in _strptime
    (data_string, format))
ValueError: time data '2' does not match format '%Y-%m-%d'

from ultimascraper.

UltimaHoarder avatar UltimaHoarder commented on May 30, 2024

Did you update to the latest comit because I'm supposed to be catching this error

from ultimascraper.

mileyvirus avatar mileyvirus commented on May 30, 2024

Yes, I did! I'm using commit bd73222 on the master branch.

from ultimascraper.

UltimaHoarder avatar UltimaHoarder commented on May 30, 2024

Ah, it seems that the fallback method of getting the date doesn't work. I forgot to catch that datetime error as well. I'm not at home yet so I can't fix the code. If I were to get the real date I would need to see a dump of the json there too

from ultimascraper.

mileyvirus avatar mileyvirus commented on May 30, 2024

I sent you the resulting json response from
https://onlyfans.com/api2/v2/users/{redacted}/posts/videos?limit=10&offset=110&order=publish_date_desc&app-token={redacted} via email at [email protected].

You'll see that the first video has that garbage postedAt date:
postedAt: "-001-11-30T00:00:00+00:00"

it's rare but I saw that at least 7 videos had that date.

from ultimascraper.

UltimaHoarder avatar UltimaHoarder commented on May 30, 2024

Ahh okay, nice. I will just filter that out and hopefully, it will be fixed c: Thanks!
I added a commit

from ultimascraper.

UltimaHoarder avatar UltimaHoarder commented on May 30, 2024

Updated the script

from ultimascraper.

mileyvirus avatar mileyvirus commented on May 30, 2024

Hmm 🤔, I don't get it. Right now I see I have some 00-00-0000 files so I don't understand what you're mentioning.

Do you think I should redump my profile?

from ultimascraper.

UltimaHoarder avatar UltimaHoarder commented on May 30, 2024

Oh yeah, you'll need to rescrape the profile to see the change. You should see one template date or none at all. They should all have "valid dates" in the commit I did 10 minutes ago

from ultimascraper.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.