[go: up one dir, main page]

Skip to content

Marge crashing with an UnicodeEncodeError

Created by: aschmolck

  File "/nix/store/q0m1zzzkxhliiyjhvhidisx9ja196v64-python3.6-marge-0.3.2/lib/python3.6/site-packages/marge/job.py", line 55, in execute
    self.rebase_and_accept(approvals)
  File "/nix/store/q0m1zzzkxhliiyjhvhidisx9ja196v64-python3.6-marge-0.3.2/lib/python3.6/site-packages/marge/job.py", line 111, in rebase_and_accept
    tested_by=tested_by,
  File "/nix/store/q0m1zzzkxhliiyjhvhidisx9ja196v64-python3.6-marge-0.3.2/lib/python3.6/site-packages/marge/job.py", line 298, in push_rebased_and_rewritten_version
    start_commit='origin/' + target_branch,
  File "/nix/store/q0m1zzzkxhliiyjhvhidisx9ja196v64-python3.6-marge-0.3.2/lib/python3.6/site-packages/marge/git.py", line 52, in tag_with_trailer
    self.git('filter-branch', '--force', '--msg-filter', filter_script, commit_range)
  File "/nix/store/q0m1zzzkxhliiyjhvhidisx9ja196v64-python3.6-marge-0.3.2/lib/python3.6/site-packages/marge/git.py", line 138, in git
    return _run(*command, env=env, check=True, timeout=TIMEOUT_IN_SECS)
  File "/nix/store/q0m1zzzkxhliiyjhvhidisx9ja196v64-python3.6-marge-0.3.2/lib/python3.6/site-packages/marge/git.py", line 147, in _run
    with subprocess.Popen(args, env=env, stdout=PIPE, stderr=PIPE) as process:
  File "/nix/store/an47r56zf6xn6fp2kyfygdy8xbplzyc2-python3-3.6.1/lib/python3.6/subprocess.py", line 707, in __init__
    restore_signals, start_new_session)
  File "/nix/store/an47r56zf6xn6fp2kyfygdy8xbplzyc2-python3-3.6.1/lib/python3.6/subprocess.py", line 1260, in _execute_child
    restore_signals, start_new_session, preexec_fn)
UnicodeEncodeError: 'ascii' codec can't encode character '\xe3' in position 25: ordinal not in range(128)
Traceback (most recent call last):
  File "/nix/store/q0m1zzzkxhliiyjhvhidisx9ja196v64-python3.6-marge-0.3.2/bin/.marge.app-wrapped", line 4, in <module>
    marge.app.main()
  File "/nix/store/q0m1zzzkxhliiyjhvhidisx9ja196v64-python3.6-marge-0.3.2/lib/python3.6/site-packages/marge/app.py", line 151, in main
    marge_bot.start()
  File "/nix/store/q0m1zzzkxhliiyjhvhidisx9ja196v64-python3.6-marge-0.3.2/lib/python3.6/site-packages/marge/bot.py", line 36, in start
    self._run(repo_manager)
  File "/nix/store/q0m1zzzkxhliiyjhvhidisx9ja196v64-python3.6-marge-0.3.2/lib/python3.6/site-packages/marge/bot.py", line 90, in _run
    merge_job.execute()
  File "/nix/store/q0m1zzzkxhliiyjhvhidisx9ja196v64-python3.6-marge-0.3.2/lib/python3.6/site-packages/marge/job.py", line 55, in execute
    self.rebase_and_accept(approvals)
  File "/nix/store/q0m1zzzkxhliiyjhvhidisx9ja196v64-python3.6-marge-0.3.2/lib/python3.6/site-packages/marge/job.py", line 111, in rebase_and_accept
    tested_by=tested_by,
  File "/nix/store/q0m1zzzkxhliiyjhvhidisx9ja196v64-python3.6-marge-0.3.2/lib/python3.6/site-packages/marge/job.py", line 298, in push_rebased_and_rewritten_version
    start_commit='origin/' + target_branch,
  File "/nix/store/q0m1zzzkxhliiyjhvhidisx9ja196v64-python3.6-marge-0.3.2/lib/python3.6/site-packages/marge/git.py", line 52, in tag_with_trailer
    self.git('filter-branch', '--force', '--msg-filter', filter_script, commit_range)
  File "/nix/store/q0m1zzzkxhliiyjhvhidisx9ja196v64-python3.6-marge-0.3.2/lib/python3.6/site-packages/marge/git.py", line 138, in git
    return _run(*command, env=env, check=True, timeout=TIMEOUT_IN_SECS)
  File "/nix/store/q0m1zzzkxhliiyjhvhidisx9ja196v64-python3.6-marge-0.3.2/lib/python3.6/site-packages/marge/git.py", line 147, in _run
    with subprocess.Popen(args, env=env, stdout=PIPE, stderr=PIPE) as process:
  File "/nix/store/an47r56zf6xn6fp2kyfygdy8xbplzyc2-python3-3.6.1/lib/python3.6/subprocess.py", line 707, in __init__
    restore_signals, start_new_session)
  File "/nix/store/an47r56zf6xn6fp2kyfygdy8xbplzyc2-python3-3.6.1/lib/python3.6/subprocess.py", line 1260, in _execute_child
    restore_signals, start_new_session, preexec_fn)
UnicodeEncodeError: 'ascii' codec can't encode character '\xe3' in position 25: ordinal not in range(128)

There are two bugs here:

  • we should always force utf-8 encoding and decoding, locale be damned (the problem here almost certainly is that the LANG/LC_ALL are not .utf-8)
  • marge-bot should unassign hereself on failure