4955: rbt command fails on systems with en_US locale not installed

marky1991

What version are you running?

rbt --version
RBTools 2.0.1 (Python 3.10.1)

What steps will reproduce the problem?

  1. rbt post

What is the expected output? What do you see instead?

Expected behavior: A review is created.
Observed behavior: It fails with an error message

What operating system are you using?

Artix linux

Attach the debug out from the command.

$ rbt <command> --debug <args>
<debug output>

rbt post
WARNING: Unable to parse SVN client version triple from "svn: warning: cannot set LC_CTYPE locale
svn: warning: environment variable LC_ALL is en_US.UTF-8
svn: warning: please check that your locale name is correct
1.14.1". Assuming version 0.0.0.
ERROR: Error validating diff

/branches/21D/framework/pyserver/common/lgfapi/parsers.py: The file was not found in the repository. (HTTP 400, API Error 207)

Please provide any additional information below

In my locale.gen, I only have es_MX.UTF-8 enabled.

My locale configs:

$ locale
LANG=es_MX.UTF-8
LC_CTYPE=es_MX.UTF-8
LC_NUMERIC="es_MX.UTF-8"
LC_TIME="es_MX.UTF-8"
LC_COLLATE="es_MX.UTF-8"
LC_MONETARY="es_MX.UTF-8"
LC_MESSAGES=es_MX.UTF-8
LC_PAPER="es_MX.UTF-8"
LC_NAME="es_MX.UTF-8"
LC_ADDRESS="es_MX.UTF-8"
LC_TELEPHONE="es_MX.UTF-8"
LC_MEASUREMENT="es_MX.UTF-8"
LC_IDENTIFICATION="es_MX.UTF-8"
LC_ALL=

$ locale -a
C
es_MX.utf8
POSIX

To work around this issue, I will be uncommenting en_US.utf-8, but I don't think this should be mandatory.

#1 marky1991

I was wrong, I was invoking the rbt command from the wrong directory. After having regenerated the locale files for en_US, I removed the en_US locale files and tried to post another review and it created the review as expected. It does still output the warnings pasted in my original report in the terminal though, which is non-ideal, but given that it at least worked, it's not as a big deal to me.