instascrape
instascrape copied to clipboard
ValueError while Scrapping Posts
Describe the bug
Scrapping post using Post
method gives error.
Traceback (most recent call last):
File "/instagram-scrapping/main.py", line 23, in <module>
post.scrape(headers=headers)
File "lib/python3.7/site-packages/instascrape/scrapers/post.py", line 88, in scrape
return_instance.upload_date = datetime.datetime.fromtimestamp(return_instance.timestamp)
ValueError: Invalid value NaN (not a number)
To Reproduce Steps to reproduce the behavior:
from instascrape import Post
headers = {'user-agent': '', 'cookie': 'sessionid:{SESSION_ID}'}
post = Post("https://www.instagram.com/p/CaDMviujr4q/")
post.scrape(headers=headers)
Expected behavior Dictionary with Keys mentioned in Wiki-Scrapped Data points
Desktop (please complete the following information):
- OS: [Ubuntu 18.04 LTS]
- Browser [chrome]
- Version [insta-scrape: 2.1.2, chrome: 98.0.4758.80, Python: 3.7.11]
@89z Thank You for your prompt reply, But I was looking solution(s) in Python.
I have an alternate package that works:
package main import "github.com/89z/mech/instagram" func main() { login, err := instagram.NewLogin(username, password) if err != nil { panic(err) } items, err := login.Items("CaDMviujr4q") if err != nil { panic(err) } for _, item := range items { println(item.Caption.Text) } }
where is this suppose to go ?
I have the same problem.
I have the same problem as well
Me too, I have tired with the example script for joebien, get the same error.
Likewise
I have the same problem as well
I have the same problem as well
same issue