Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Errors in Python
#1
Dear All,
I faced the following issue: i created a code that crashed Spider (annaconda) program and Udacity (learning institute) python platform cause it ran indefinitely, it took me too long to know the mistake cause i couldn’t find any guidance in error message or so.

Can debugging help or it shall find no issues and will also excute the code and crash the program? if debugging can't help, can i approach python developers to propose a new type of error that might crash programs since they run indefinitely, and utilise debugging in this case?

Yours,
Reply
#2
Add some real-time print statements to know exactly where the program is hanging up
as a start, use something like:
print('Entering myfunction(zig) zig: {}'.format(zig))
replacing myfunction(zig) with actual method (or function) name.

Once you have isolated the problem to a specific area, you can add print before each statements to isolate the line (or lines) of code causing the actual problem.

print statements are your friend
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Linux, Python, C ++, Brain2 and errors. PiotrBujakowski 0 1,476 Jun-24-2024, 03:41 PM
Last Post: PiotrBujakowski
  When does Python detect Errors? stamp1t 1 3,640 Oct-21-2023, 05:53 PM
Last Post: deanhystad
  Python Request Errors PythonNoob1998 7 12,075 Jan-07-2021, 05:18 PM
Last Post: buran
  Pip Syntax Errors in CMD: Windows 10 and Python 3.8.1 jamesphopper 2 7,505 Feb-08-2020, 07:21 PM
Last Post: jamesphopper
  Python stops without errors shahgourav 4 4,402 Feb-04-2020, 11:44 PM
Last Post: micseydel
  Can the comments produce errors in python? newbieAuggie2019 9 8,327 Nov-26-2019, 12:19 AM
Last Post: micseydel
  Running into errors when installing pip and pip3 on python 2.7 and python 3.6 tej7gandhi 1 4,331 May-05-2019, 10:37 PM
Last Post: snippsat
  Python Errors kendias 26 31,118 May-25-2017, 06:43 PM
Last Post: kendias

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020