commit | 791a46ed58f74d673cf2c0d81deec57155bf7583 | [log] [tgz] |
---|---|---|
author | Lysandros Nikolaou <lisandrosnik@gmail.com> | Tue May 26 04:24:31 2020 +0300 |
committer | GitHub <noreply@github.com> | Tue May 26 02:24:31 2020 +0100 |
tree | 26b3037aba7bcaafdb3a3f83ec73ebdc835511df | |
parent | 6cb0ad20396116b5076a58b05b55286d6d5e0c94 [diff] |
[3.9] bpo-38964: Print correct filename on a SyntaxError in an fstring (GH-20399) (GH-20404) When a `SyntaxError` in the expression part of a fstring is found, the filename attribute of the `SyntaxError` is always `<fstring>`. With this commit, it gets changed to always have the name of the file the fstring resides in. Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>. (cherry picked from commit f7b1e461567e5e3fa3ba46f589d9edc1b45b2dd0)