PEP 657: Fix alignment typo (#3605)

This commit is contained in:
William Andrea 2024-02-23 21:21:19 -05:00 committed by GitHub
parent c576162334
commit d294d5ef19
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 2 deletions

View File

@ -105,7 +105,7 @@ This problem presents itself in the following situations.
Traceback (most recent call last): Traceback (most recent call last):
File "test.py", line 1, in <module> File "test.py", line 1, in <module>
x = (a + b) @ (c + d) x = (a + b) @ (c + d)
ValueError: operands could not be broadcast together with shapes (1,2) (2,3) ValueError: operands could not be broadcast together with shapes (1,2) (2,3)
There is no clear indication as to which operation failed, was it the addition There is no clear indication as to which operation failed, was it the addition
on the left, the right or the matrix multiplication in the middle? With this on the left, the right or the matrix multiplication in the middle? With this
@ -115,7 +115,7 @@ This problem presents itself in the following situations.
File "test.py", line 1, in <module> File "test.py", line 1, in <module>
x = (a + b) @ (c + d) x = (a + b) @ (c + d)
~~^~~ ~~^~~
ValueError: operands could not be broadcast together with shapes (1,2) (2,3) ValueError: operands could not be broadcast together with shapes (1,2) (2,3)
Giving a much clearer and easier to debug error message. Giving a much clearer and easier to debug error message.