1

Stuck in debugging a python script (using 'requests' library to achieve 'curl' type function) for the last 2 hours

Worked fine yesterday in Python REPL.. Throws exception when put in a long exisitng .py script.. Works fine again when put in Python REPL

Found out that when in REPL, I am careful to import 'requests' library every time but ignored when typing in .py script
(Feeling stupid)

Lesson learned: Don't use "generic exceptions"!! They never let you know what the real problem is.

Comments
  • 1
    Try using a python IDE or plugin to your text editor , may streamline your work and help get rid of static problems.
Add Comment