"Unparsable" NotImplemementedError when getting values from variables
See original GitHub issueIf setup.py gets setup() values from variables, the script blows up with a NotImplementedError:
Traceback (most recent call last):
File "site-packages/setup_py_upgrade.py", line 125, in visit_Call
value = ast.literal_eval(kwd.value)
File "ast.py", line 85, in literal_eval
return _convert(node_or_string)
File "ast.py", line 84, in _convert
raise ValueError('malformed node or string: ' + repr(node))
ValueError: malformed node or string: <_ast.Name object at 0x7fdf99964e10>
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "setup-py-upgrade", line 8, in <module>
sys.exit(main())
File "site-packages/setup_py_upgrade.py", line 167, in main
visitor.visit(tree)
File "ast.py", line 253, in visit
return visitor(node)
File "ast.py", line 261, in generic_visit
self.visit(item)
File "ast.py", line 253, in visit
return visitor(node)
File "ast.py", line 263, in generic_visit
self.visit(value)
File "ast.py", line 253, in visit
return visitor(node)
File "setup_py_upgrade.py", line 127, in visit_Call
raise NotImplementedError(f'unparsable: {kwd.arg}=')
NotImplementedError: unparsable: version=
This probably isn’t fully fixable as the variable could be a constant, or it might come from a separate python file, or even from reading some data from an external file.
Issue Analytics
- State:
- Created 4 years ago
- Comments:8 (5 by maintainers)
Top Results From Across the Web
How to define lazy variable in Python which will raise ...
With this code, accessing self.variable raises the exception with a very informative message: NotImplementedError: <__main__.
Read more >Not Implemented Error when trying to set initial variable values
I am doing an optimization problem in which the output is based on all the variables, but where PuLP only modifies/sets some of...
Read more >Unparsable date using Tmap - Talend Community
Hello guys,. How you are ? I'm facing a issue when i trying to parse a String column to Date. The error name...
Read more >ODI 11.1.1 - Problem setting Date Variable — oracle-tech
i have a problem setting a date-variable in my package. i'm getting error ODI-1237 when using the dateformat stated in the help-documentation.
Read more >set new constraint but got NotImplementedError
variable to 1, I said that because I've read the data, the model should be fine if it just build more launch station,...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
note that in the general case you’re asking setup-py-upgrade to solve the halting problem, which is intractable
there’s no reason to write a setup py like that, inline it and it’ll get converted – see above