[Tutor] Help me to debug this script .. I tried but ....
Asrarahmed Kadri
ajkadri at googlemail.com
Sun Nov 5 17:14:09 CET 2006
When I am running the script from the command line, its working fine but
when I am trying to run from Pythonwin, its giving me error.
Can anyone explain the reason?
Regards,
Asrarahmed
On 11/5/06, Kent Johnson <kent37 at tds.net> wrote:
>
> Dustin J. Mitchell wrote:
> > Asrarahmed Kadri wrote:
> >>
> "C:\Python24\Lib\site-packages\pythonwin\pywin\framework\scriptutils.py",
> >> line 310, in RunScript
> >> exec codeObject in __main__.__dict__
> >> File "C:\project stuff-programs\Scriptdate.py", line 18, in ?
> >> t1 = my_version_datecheck.dateCheck(dt1,0)
> >> File "my_version_datecheck.py", line 38, in dateCheck
> >> import traceback
> >> NameError: global name 'traceback' is not defined
> >
> > This tells you everything you need to know right here.
> >
> > What version of Python are you using? I know traceback existed at least
> in
> > 2.3. Might be time to consider an upgrade.
>
> If traceback was not a valid module name the import would raise
> ImportError, not NameError.
>
> Something strange is going on here; have you shown us all the code?
>
> Kent
>
> _______________________________________________
> Tutor maillist - Tutor at python.org
> http://mail.python.org/mailman/listinfo/tutor
>
--
To HIM you shall return.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.python.org/pipermail/tutor/attachments/20061105/cd8a4a5c/attachment.html
More information about the Tutor
mailing list