[issue16974] when "python -c command" does a traceback, it open the file "<string>"

Ramchandra Apte report at bugs.python.org
Wed Jan 16 13:29:31 CET 2013


Ramchandra Apte added the comment:

+1

On 16 January 2013 17:43, R. David Murray <report at bugs.python.org> wrote:

>
> R. David Murray added the comment:
>
> Ideally there would be an unambiguous way to know if the object came from
> a file or some other source (say, __file__ is None and another special
> attribute gives the clue to the actual source), but that's not the way
> things work now, and for backward compatibility reasons I doubt that we can
> change it.  I'm sure there are programs that depend on at least '<string>',
> if not some of the other places where a similar thing is done.
>
> ----------
>
> _______________________________________
> Python tracker <report at bugs.python.org>
> <http://bugs.python.org/issue16974>
> _______________________________________
>

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue16974>
_______________________________________


More information about the Python-bugs-list mailing list