Skip to content
This repository has been archived by the owner on Feb 13, 2019. It is now read-only.

preflight barfs if hostname has ' #35

Open
Rumbles opened this issue May 19, 2016 · 0 comments
Open

preflight barfs if hostname has ' #35

Rumbles opened this issue May 19, 2016 · 0 comments

Comments

@Rumbles
Copy link

Rumbles commented May 19, 2016

As per:

https://groups.google.com/d/msg/simian-discuss/cm6SDsBM3dA/HRLpAjyeFgAJ

If the client hostname contains a ' symbol (which is Mac default), preflight barfs:

admin$ sudo /usr/local/munki/preflight --debug
WARNING:root:facter hostname empty; fetching from sys_config
Traceback (most recent call last):
File "/usr/local/munki/simian_client.py", line 87, in
sys.exit(main(sys.argv[1:]))
File "/usr/local/munki/simian_client.py", line 73, in main
preflight.RunPreflight(runtype, server_url=server_url)
File "/usr/local/munki/simian/lib/python2.7/site-packages/simian-2.4-py2.7.egg/simian/mac/client/preflight.py", line 371, in RunPreflight
secure_config, client_id, user_settings, client_exit)
File "/usr/local/munki/simian/lib/python2.7/site-packages/simian-2.4-py2.7.egg/simian/mac/client/preflight.py", line 114, in LoginToServer
client_id_str = flight_common.DictToStr(client_id)
File "/usr/local/munki/simian/lib/python2.7/site-packages/simian-2.4-py2.7.egg/simian/mac/client/flight_common.py", line 530, in DictToStr
value = value.decode('utf-8')
File "/usr/local/munki/simian/lib/python2.7/encodings/utf_8.py", line 16, in decode
return codecs.utf_8_decode(input, errors, True)
UnicodeEncodeError: 'ascii' codec can't encode character u'\u2019' in position 5: ordinal not in range(128)

Running current clone, on OS X 10.11

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant