You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Original comment byjaraco (Bitbucket: jaraco, GitHub: jaraco):
Tail end of the traceback is:
self.install_script(dist, script_name, script_text, script_path)
File "/Users/alex_gaynor/projects/openstack-swiftclient/.tox/py34/lib/python3.4/site-packages/setuptools/command/easy_install.py", line 762, in install_script
script_text = (get_script_header(script_text) +
File "/Users/alex_gaynor/projects/openstack-swiftclient/.tox/py34/lib/python3.4/site-packages/setuptools/command/easy_install.py", line 1555, in get_script_header
first = (script_text+'\n').splitlines()
TypeError: can't concat bytes to str
I guess it's no surprise that when #210 was changed, it created this regression.
My initial instinct is to roll back the change that introduced the issue. I welcome alternative suggestions and especially welcome unit tests that capture these requirements.
The reasonning is that on windows the binary script must be open in binary. My initial naive approach breaks because in this part of the code, we still assume that the contents of scripts can only be text.
On unix, this doesn't break because text mode files are not converted, handling binary equally. But then Python3 tells us bytes are is not text...
Maybe we should call is_python_script() to choose the binary flag in the install_egg_scripts in develop command?