pytest-dev / unittest2pytest

helps rewriting Python `unittest` test-cases into `pytest` test-cases
GNU General Public License v3.0
128 stars 27 forks source link

ParseError: bad input: type=22, value='=', context=('', (62, 54)) #60

Closed AABur closed 2 years ago

AABur commented 2 years ago
❯ unittest2pytest git_machete/tests/functional/test_machete.py

RefactoringTool: Can't parse git_machete/tests/functional/test_machete.py: ParseError: bad input: type=22, value='=', context=('', (62, 54))
RefactoringTool: No files need to be modified.
RefactoringTool: There was 1 error:
RefactoringTool: Can't parse git_machete/tests/functional/test_machete.py: ParseError: bad input: type=22, value='=', context=('', (62, 54))
AABur commented 2 years ago

I figured out that the error concerns -p, --print-function Modify the grammar so that print() is a function Problem solved!

jaraco commented 2 years ago

I encountered this error today too. Why not make --print-function the default?