[pypy-issue] Issue #3100: " ValueError: Unmatched '{' " while formatting "{:[XYZ}" (pypy/pypy)

Adrien Gabillaud issues-reply at bitbucket.org
Thu Oct 24 15:58:52 EDT 2019


New issue 3100: " ValueError: Unmatched '{' " while formatting "{:[XYZ}"
https://bitbucket.org/pypy/pypy/issues/3100/valueerror-unmatched-while-formatting-xyz

Adrien Gabillaud:

Hi. I’m sorry if this is alreay solved in latest release, I was not able to test with most recent version of PyPy, but I preferred to report this just in case.

‌

This code snippet:

```
class Foo:
    def __format__(self, f):
        return "!"

print("{:[XYZ}".format(Foo()))
```

Raise an error `ValueError: Unmatched '{'` on PyPy 3.5 while it works fine on CPython.

‌




More information about the pypy-issue mailing list