Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TypeError: unicode argument expected, got 'str' #99

Open
ZDAHWYB opened this issue Sep 21, 2020 · 1 comment
Open

TypeError: unicode argument expected, got 'str' #99

ZDAHWYB opened this issue Sep 21, 2020 · 1 comment

Comments

@ZDAHWYB
Copy link

ZDAHWYB commented Sep 21, 2020

ROS Melodic
ubuntu 18.04
python 2.7
when I write rosrun robot_upstart install mbot_gazebo/launch/mbot_laser_nav_gazebo.launch
then show the error:
Traceback (most recent call last):
File "/home/huanyu/catkin_ws/src/robot_upstart/scripts/install", line 32, in
exit(main())
File "/home/huanyu/catkin_ws/src/robot_upstart/src/robot_upstart/install_script.py", line 123, in main
j.install(Provider=provider)
File "/home/huanyu/catkin_ws/src/robot_upstart/src/robot_upstart/job.py", line 162, in install
installation_files = p.generate_install()
File "/home/huanyu/catkin_ws/src/robot_upstart/src/robot_upstart/providers.py", line 179, in generate_install
"content": self._fill_template("templates/systemd_job.conf.em"), "mode": 0o644}
File "/home/huanyu/catkin_ws/src/robot_upstart/src/robot_upstart/providers.py", line 229, in _fill_template
self.interpreter.file(f)
File "/usr/lib/python2.7/dist-packages/em.py", line 2359, in file
self.safe(scanner, done, locals)
File "/usr/lib/python2.7/dist-packages/em.py", line 2401, in safe
self.parse(scanner, locals)
File "/usr/lib/python2.7/dist-packages/em.py", line 2421, in parse
token.run(self, locals)
File "/usr/lib/python2.7/dist-packages/em.py", line 1107, in run
interpreter.write(self.data)
File "/usr/lib/python2.7/dist-packages/em.py", line 2172, in write
self.stream().write(data)
File "/usr/lib/python2.7/dist-packages/em.py", line 538, in write
self.filter.write(data)
TypeError: unicode argument expected, got 'str'

@melnarte
Copy link

melnarte commented Sep 28, 2020

ROS melodic
PRETTY_NAME="Raspbian GNU/Linux 10 (buster)"
python 2.7
when I want to upstart my own package, I write

rosrun robot_upstart install qr_configuration/launch/configuration.launch

then show the error:

/lib/systemd/systemd
Traceback (most recent call last):
File "/path/robot_upstart/scripts/install", line 32, in
exit(main())
File "/path/robot_upstart/src/robot_upstart/install_script.py", line 123, in main
j.install(Provider=provider)
File "/path/robot_upstart/src/robot_upstart/job.py", line 162, in install
installation_files = p.generate_install()
File "/path/robot_upstart/src/robot_upstart/providers.py", line 179, in generate_install
"content": self._fill_template("templates/systemd_job.conf.em"), "mode": 0o644}
File "/path/robot_upstart/src/robot_upstart/providers.py", line 229, in _fill_template
self.interpreter.file(f)
File "/usr/lib/python2.7/dist-packages/em.py", line 2359, in file
self.safe(scanner, done, locals)
File "/usr/lib/python2.7/dist-packages/em.py", line 2401, in safe
self.parse(scanner, locals)
File "/usr/lib/python2.7/dist-packages/em.py", line 2421, in parse
token.run(self, locals)
File "/usr/lib/python2.7/dist-packages/em.py", line 1107, in run
interpreter.write(self.data)
File "/usr/lib/python2.7/dist-packages/em.py", line 2172, in write
self.stream().write(data)
File "/usr/lib/python2.7/dist-packages/em.py", line 538, in write
self.filter.write(data)
TypeError: unicode argument expected, got 'str'

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

No branches or pull requests

2 participants