[issue45596] Python opens the ./<string> file on exception while using -c

Julien Palard report at bugs.python.org
Sun Oct 24 05:38:17 EDT 2021


New submission from Julien Palard <julien+python at palard.fr>:

When running `python -c 'raise ValueError'` Python tries to open the '<string>' file, so:

    $ echo Coucou > '<string>'
    $ python -c 'raise ValueError'
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
        Coucou
    ValueError

----------
messages: 404922
nosy: mdk
priority: normal
severity: normal
status: open
title: Python opens the ./<string> file on exception while using -c

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue45596>
_______________________________________


More information about the Python-bugs-list mailing list