python3-zunclient - argument must be str, not bytes
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Zun |
Fix Committed
|
Critical
|
hongbin |
Bug Description
I ran into the stack trace below when trying to attach to an existing container while troubleshooting why I could not get an interactive session. I am running openstack stein release on Ubuntu 18.04 and building zun based off of the stable/stein branch. When I run `openstack --debug appcontainer run --interactive --name mycontainer4 --net network=
POST call to container for https:/
putting tty into raw mode
starting main loop in client
that output does not provide much detail on why it closed the connections so I ran `openstack appcontainer --debug exec --interactive mycontainer4 /bin/sh` and received a lot more detail. It seems to be a python2 vs python3 bug. see stack trace below. I have not done any testing using python-zunclient instead.
Truncated output
putting tty into raw mode
starting main loop in client
Traceback (most recent call last):
File "/usr/lib/
result = cmd.run(
File "/usr/lib/
return super(Command, self).run(
File "/usr/lib/
return_code = self.take_
File "/usr/lib/
websocketcl
File "/usr/lib/
wscls.
File "/usr/lib/
self.
File "/usr/lib/
self.
File "/usr/lib/
sys.
TypeError: write() argument must be str, not bytes
clean_up ExecContainer: write() argument must be str, not bytes
Traceback (most recent call last):
File "/usr/lib/
ret_val = super(OpenStack
File "/usr/lib/
result = self.run_
File "/usr/lib/
ret_value = super(OpenStack
File "/usr/lib/
result = cmd.run(
File "/usr/lib/
return super(Command, self).run(
File "/usr/lib/
return_code = self.take_
File "/usr/lib/
websocketcl
File "/usr/lib/
wscls.
File "/usr/lib/
self.
File "/usr/lib/
self.
File "/usr/lib/
sys.
TypeError: write() argument must be str, not bytes
END return value: 1
I can give you more details if needed
Changed in zun: | |
status: | New → Triaged |
importance: | Undecided → High |
assignee: | nobody → hongbin (hongbin034) |
@David,
Thanks for reporting the bug. I proposed a fix in master and will try to backport it to stable branches.