igbot icon indicating copy to clipboard operation
igbot copied to clipboard

[BUG] challenge_required with send_photo method

Open b177y opened this issue 4 years ago • 5 comments

Example file

Describe the bug

Attempting to send image over dm using bot.send_photo([userid], filepath), it returns a 400 error and says challenge required.

Log

>>> bot.send_photo(['IDNUM'], "FILEPATH")
2020-03-15 16:43:03,392 - ERROR - Request returns 400 error!
2020-03-15 16:43:03,392 - INFO - Instagram's error message: challenge_required
2020-03-15 16:43:03,392 - INFO - Instagram's error message: {}
2020-03-15 16:43:03,392 - INFO - Message to ['196029714'] wasn't sent
False

To Reproduce

Steps to reproduce the behavior:

  1. Run import instabot
  2. Run bot = instabot.Bot()
  3. Run bot.login()
  4. Choose logged in user
  5. Run bot.send_photo(['IDNUM'], "FILEPATH")

Expected behavior

The jpg image at FILEPATH should be sent to the user with id of IDNUM

Additional context I don't have 2fa so the challenge shouldn't be a 2fa challenge. Login is always successful.

Version

Python version (python -v): Python 3.8.1

Operating Systeem: Win/Linux/MacOS: Manjaro Linux

b177y avatar Mar 15 '20 17:03 b177y

The app gets an error. :( log bad indentation of a sequence entry at line 22, column 2: - content: ^ YAMLException: bad indentation of a sequence entry at line 22, column 2: - content: ^ at generateError (/app/node_modules/js-yaml/lib/js-yaml/loader.js:167:10) at throwError (/app/node_modules/js-yaml/lib/js-yaml/loader.js:173:9) at readBlockSequence (/app/node_modules/js-yaml/lib/js-yaml/loader.js:962:7) at composeNode (/app/node_modules/js-yaml/lib/js-yaml/loader.js:1390:45) at readBlockMapping (/app/node_modules/js-yaml/lib/js-yaml/loader.js:1089:11) at composeNode (/app/node_modules/js-yaml/lib/js-yaml/loader.js:1359:12) at readDocument (/app/node_modules/js-yaml/lib/js-yaml/loader.js:1519:3) at loadDocuments (/app/node_modules/js-yaml/lib/js-yaml/loader.js:1575:5) at load (/app/node_modules/js-yaml/lib/js-yaml/loader.js:1596:19) at Object.safeLoad (/app/node_modules/js-yaml/lib/js-yaml/loader.js:1618:10) at Object.parseConfig (/app/dist/parser.js:16:21) at /app/dist/robot.js:73:39 at step (/app/dist/robot.js:33:23) at Object.next (/app/dist/robot.js:14:53) at fulfilled (/app/dist/robot.js:5:58)

close-issue-app[bot] avatar Mar 15 '20 17:03 close-issue-app[bot]

Hey @b177y,

We did a quick check and this issue looks very darn similar to

  • #1362 - Bump pytest from 5.3.5 to 5.4.0
  • #1361 - [QUESTION] Where were photos downloaded by download_photos_by_hashtag.py saved?
  • #1359 - Need Help converting Media_id into user_id for follow?

This could be a coincidence, but if any of these issues solves your problem then I did a good job :smile:

If not, the maintainers will get to this issue shortly.

Cheers, Your Friendly Neighborhood ProBot

duplicate-issues[bot] avatar Mar 15 '20 17:03 duplicate-issues[bot]

Same issue here 2020-03-16 06:31:58,441 - INFO - Not yet logged in starting: PRE-LOGIN FLOW! 2020-03-16 06:32:00,329 - ERROR - Request returns 400 error! 2020-03-16 06:32:00,329 - INFO - Instagram's error message: challenge_required 2020-03-16 06:32:00,329 - INFO - Error type: checkpoint_challenge_required 2020-03-16 06:32:00,331 - WARNING - NO MORE PHOTO TO UPLOAD

Laeka avatar Mar 16 '20 06:03 Laeka

Same Issue:

2020-04-05 16:23:58,372 - INFO - Not yet logged in starting: PRE-LOGIN FLOW!
2020-04-05 16:24:00,512 - ERROR - Request returns 400 error!
2020-04-05 16:24:00,513 - INFO - Instagram's error message: challenge_required
2020-04-05 16:24:00,513 - INFO - Error type: checkpoint_challenge_required
2020-04-05 16:24:00,513 - INFO - Going to like media with hashtag #fashion.

jephjohnson avatar Apr 05 '20 21:04 jephjohnson

Same!

tambu22 avatar Apr 17 '20 19:04 tambu22