byob icon indicating copy to clipboard operation
byob copied to clipboard

Can't run setup.py

Open andreiverse opened this issue 7 years ago • 10 comments


$ python setup.py                                                                                                                                                            Traceback (most recent call last):                                                                                                                                             File "setup.py", line 61, in                                                                                                                                           main()                                                                                                                                                                     File "setup.py", line 18, in main                                                                                                                                              logging.basicConfig(level=logging.DEBUG, handler=logging.StreamHandler())                                                                                                  File "C:\Program Files\Python37\lib\logging\__init__.py", line 1921, in basicConfig                                                                                            raise ValueError('Unrecognised argument(s): %s' % keys)                                                                                                                  ValueError: Unrecognised argument(s): handler
--

$ python -V                                                                                                                                                                  Python 3.7.2
--

andreiverse avatar Feb 12 '19 16:02 andreiverse

Traceback (most recent call last): File "setup.py", line 61, in main() File "setup.py", line 18, in main logging.basicConfig(level=logging.DEBUG, handler=logging.StreamHandler()) File "C:\Program Files\Python37\lib\logging_init_.py", line 1921, in basicConfig raise ValueError('Unrecognised argument(s): %s' % keys) ValueError: Unrecognised argument(s): handler

andreiverse avatar Feb 12 '19 16:02 andreiverse

I haven't been able to reproduce this error. What OS are you running it on? Which version of Python are you using?

malwaredllc avatar Feb 16 '19 15:02 malwaredllc

windows 10 pro and python 3.7.2

zing145 avatar Mar 02 '19 20:03 zing145

im having the same problem

zing145 avatar Mar 02 '19 20:03 zing145

Try running it with python 2 really quick and let me know if there's still an error. That will help isolate the issue.

malwaredllc avatar Mar 04 '19 02:03 malwaredllc

After reading the setup.py file, I recommend using the nested pip module within python for WIndows OS, as it is a bit cleaner over the "where" function in Windows; In fact I'm not certain that function works the way it is anticipated in some scenarios.

In place of "pip install <requirement", try "python -m pip install " -- this should be functional for 3.x, and the latest 2.7.x.

---edit ... although as I think about that, just import pip and install using the package rather than subproc? There's different ways to solve this issue, but I think the output you'll get from "where" is not consistent enough and in the same pattern as "which" to be counted on.

You would need to check for multiple return items or parse locals/try to execute "pip" alone and then search and parse on failure.

intrct avatar Mar 09 '19 22:03 intrct

See if the changes here do anything for you... I don't have a Windows system to test on at the moment, apologies.

https://github.com/intrct/byob/tree/issue%2396 specifically; https://github.com/intrct/byob/commit/c216adafca6aedb43eb17b4e86d98eeeec8aa969

intrct avatar Mar 09 '19 22:03 intrct

hey! im testing this at Win/lin/arm environments and workaround from @intrct working for me

at install on windows systems down virtual environment/or not, install requirements like this : python -m pip install -r byob\requirements.txt

netzulo avatar Mar 24 '19 13:03 netzulo

I think standardizing on the python -m pip install -r is an ideal scenario @netzulo ;

This is somewhat backwards compatible with newer 2.x, but on issues like this BYOB maybe should only focus on 3.x and less about 2.x; it will be deprecated soon.

intrct avatar Mar 24 '19 14:03 intrct

This issue has been fixed in pull request #99

malwaredllc avatar Mar 30 '19 22:03 malwaredllc