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

snactor run fails when producing non utf-8 character #569

Open
kokesak opened this issue Oct 9, 2019 · 2 comments
Open

snactor run fails when producing non utf-8 character #569

kokesak opened this issue Oct 9, 2019 · 2 comments
Labels

Comments

@kokesak
Copy link
Member

kokesak commented Oct 9, 2019

Actual behavior
Snactor run fails when actor produce non UTF-8 character.

To Reproduce
Create new actor which uses external command (eg. printf) to create non UTF-8 characeter.

See error

2019-10-09 07:58:42.842 DEBUG    PID: 5218 leapp.actors.runner: External command has finished: ['/tmp/xcase.runpath.RPGkTxRo/xcase-relics/Err=plain,Out=noutf8,Es=zero,Dbg=yes/script.sh']
Process Process-3:
Traceback (most recent call last):
  File "/usr/lib64/python2.7/multiprocessing/process.py", line 258, in _bootstrap
    self.run()
  File "/usr/lib64/python2.7/multiprocessing/process.py", line 114, in run
    self._target(*self._args, **self._kwargs)
  File "/usr/lib/python2.7/site-packages/leapp/repository/actor_definition.py", line 63, in _do_run
    target_actor(logger=logger, messaging=messaging, config_model=config_model).run(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/leapp/actors/__init__.py", line 320, in run
    self.process(*args)
  File "/tmp/xcase.runpath.RPGkTxRo/xcase-relics/Err=plain,Out=noutf8,Es=zero,Dbg=yes/Run/actors/runner/actor.py", line 17, in process
    run(["/tmp/xcase.runpath.RPGkTxRo/xcase-relics/Err=plain,Out=noutf8,Es=zero,Dbg=yes/script.sh"])
  File "/usr/lib/python2.7/site-packages/leapp/libraries/stdlib/__init__.py", line 177, in run
    result = _call(args, callback_raw=callback_raw, callback_linebuffered=callback_linebuffered, env=env)
  File "/usr/lib/python2.7/site-packages/leapp/libraries/stdlib/call.py", line 180, in _call
    **extra
  File "/usr/lib/python2.7/site-packages/leapp/libraries/stdlib/call.py", line 60, in _multiplex
    linebufs[fd] += decoders[fd].decode(read)
  File "/usr/lib64/python2.7/codecs.py", line 296, in decode
    (result, consumed) = self._buffer_decode(data, self.errors, final)
UnicodeDecodeError: 'utf8' codec can't decode byte 0x80 in position 5: invalid start byte


=======================================================================================
Actor runner unexpectedly terminated with exit code: 1 - Please check the above details
=======================================================================================
@kokesak kokesak added the bug label Oct 9, 2019
@bocekm
Copy link
Member

bocekm commented Oct 10, 2019

Note: this is irrelevant to locale - it may be for example listing directories whose names contain utf-8 chars. Do you know if it also happening during leapp upgrade, or just snactor run?

@kokesak
Copy link
Member Author

kokesak commented Oct 11, 2019

It seems like it's only happening during snactor run, no error happend durnig leapp upgrade.

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

No branches or pull requests

2 participants