Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 2013162

Summary: [ALL_LANG][RHSM CLI] Unlocalized message in syspurpose module.
Product: Red Hat Enterprise Linux 8 Reporter: Lijun Li <lijli>
Component: subscription-managerAssignee: Pino Toscano <ptoscano>
Status: CLOSED ERRATA QA Contact: Red Hat subscription-manager QE Team <rhsm-qe>
Severity: medium Docs Contact:
Priority: medium    
Version: 8.5CC: jsefler, jwboyer, ljanda, ptoscano, qe-i18n-bugs, redakkan
Target Milestone: rcKeywords: Translation, Triaged
Target Release: 8.6Flags: pm-rhel: mirror+
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: subscription-manager-1.28.24-1.el8 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2022-05-10 15:22:57 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Lijun Li 2021-10-12 09:28:47 UTC
Description of problem:
[ALL_LANG][RHSM CLI] Unlocalized message in syspurpose module.

Version-Release number of selected component (if applicable):
subscription-manager-1.28.21-2.el8.x86_64

How reproducible:
100%

Steps to Reproduce:
1. Run RHSM CLI with latest rhel8 workstation build.

Actual results:
[root@localhost ~]# syspurpose -h
usage: syspurpose [-h]
                  {set,unset,add,remove,set-role,unset-role,add-addons,remove-addons,unset-addons,set-sla,unset-sla,set-usage,unset-usage,show}
                  ...

System Syspurpose Management Tool
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^Unlocalized strings^^^^^^^^^^^^^^^^^^^^^^^^^

positional arguments:
  {set,unset,add,remove,set-role,unset-role,add-addons,remove-addons,unset-addons,set-sla,unset-sla,set-usage,unset-usage,show}
                        sub-command help
    set                 指定プロパティーの値を設定
    unset               指定プロパティーの値を無効化 (削除)
    add                 指定プロパティーに値を追加
    remove              指定プロパティーから値を削除
    set-role            システムロールをシステム syspurpose に設定
    unset-role          ロールの設定を削除
    add-addons          システム syspurpose にアドオンを追加
    remove-addons       システム syspurpose からアドオンを削除
    unset-addons        アドオンの設定を削除
    set-sla             システム SLA を設定
    unset-sla           SLA の設定を削除
    set-usage           システムの使用方法を設定します
    unset-usage         使用方法の設定を削除
    show                現行システムの syspurpose を表示します

optional arguments:
  -h, --help            show this help message and exit
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^Unlocalized strings^^^^^^^^^^^^^^^^^^^^^^^^^

[root@localhost ~]# syspurpose set test
usage: syspurpose set [-h] property value
syspurpose set: error: the following arguments are required: value
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^Unlocalized strings^^^^^^^^^^^^^^^^^^^^^^^^^

[root@localhost ~]# syspurpose add value test
Not adding value "test" to value; it already exists.
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^Unlocalized strings^^^^^^^^^^^^^^^^^^^^^^^^^


Expected results:
They should be localized.

Additional info:

Comment 2 Lijun Li 2021-10-25 08:13:01 UTC
Reproduced on latest build.

[root@localhost ~]# rpm -q subscription-manager
subscription-manager-1.28.21-3.el8.x86_64

Comment 4 Pino Toscano 2021-11-08 17:33:43 UTC
Few messages (4 in particular) are not translatable because our translations were not up-to-date with the translation templates :-( To avoid this problem, I enabled the "msgmerge" addon in Weblate.

Regarding the other issues:
- we need to translate the messages of the Python "argparse" module on our own, like done already by sub-man
- there were few UI strings actually not translatable

I created a PR that fixes the issues above:
https://github.com/candlepin/subscription-manager/pull/2868

To be fully fixed, there will be two steps needed:
- first, update the translation catalogs with the new messages; I will do it once the aforementioned PR is merged
- second, the new messages will need to be translated

Comment 8 John Sefler 2021-12-08 22:15:32 UTC
Pre-verifying the following CI build of python3-syspurpose which contains merged pull requests...
https://github.com/candlepin/subscription-manager/pull/2868
https://github.com/candlepin/subscription-manager/pull/2818

I will test with Korean (LANG=ko_KR.utf8) because this is currently the only language translated at 100%...

[root@ibm-x3650m4-01-vm-15 ~]# rpm -q python3-syspurpose
python3-syspurpose-1.28.24-1.git.29.21f2172.el8.x86_64


[root@ibm-x3650m4-01-vm-15 ~]# LANG=ko_KR.utf8 syspurpose -h
사용법: syspurpose [-h]
                {set,unset,add,remove,set-role,unset-role,add-addons,remove-addons,unset-addons,set-sla,unset-sla,set-usage,unset-usage,show}
                ...

시스템 Syspurpose 관리 도구

위치 인수:
  {set,unset,add,remove,set-role,unset-role,add-addons,remove-addons,unset-addons,set-sla,unset-sla,set-usage,unset-usage,show}
                        sub-command help
    set                 주어진 속성에 대한 값 설정
    unset               주어진 속성에 대한 설정 취소 (설정 지우기)
    add                 주어진 속성에 대한 값 추가
    remove              주어진 속성에서 값을 제거합니다
    set-role            시스템 역할을 시스템 syspurpose로 설정
    unset-role          역할 설정 삭제
    add-addons          시스템 syspurpose에 애드온 추가
    remove-addons       시스템 syspurpose에서 애드온 제거
    unset-addons        애드온 설정 삭제
    set-sla             시스템의 SLA 설정
    unset-sla           SLA 설정 해제
    set-usage           시스템의 사용 방법 설정
    unset-usage         사용 방법 설정 삭제
    show                현재 시스템의 syspurpose 표시

선택적인 인수:
  -h, --help            도움말 보기 및 종료

'syspurpose' 명령은 더 이상 사용되지 않으며 향후 주요 출시에서 제거될 것입니다. 앞으로 'subscription-manager
syspurpose' 명령을 사용하세요.

[root@ibm-x3650m4-01-vm-15 ~]# LANG=ko_KR.utf8 syspurpose set test
사용법: syspurpose set [-h] property value
syspurpose set: 오류: 다음 인수가 필요합니다: value

[root@ibm-x3650m4-01-vm-15 ~]# LANG=ko_KR.utf8 syspurpose add value test
'syspurpose' 명령은 더 이상 사용되지 않으며 향후 주요 출시에서 제거될 것입니다. 앞으로 'subscription-manager syspurpose' 명령을 사용하세요.
test가 value에 추가되었습니다.
value가 최신화되었습니다.

[root@ibm-x3650m4-01-vm-15 ~]# LANG=ko_KR.utf8 syspurpose add value test
'syspurpose' 명령은 더 이상 사용되지 않으며 향후 주요 출시에서 제거될 것입니다. 앞으로 'subscription-manager syspurpose' 명령을 사용하세요.
"test" 값이 value에 추가되지 않았습니다; 이미 존재합니다.
[root@ibm-x3650m4-01-vm-15 ~]# 

[root@ibm-x3650m4-01-vm-15 ~]# LANG=ko_KR.utf8 subscription-manager syspurpose -h
사용법: subscription-manager syspurpose [하위모듈] [옵션]

모든 시스템 목적 설정을 관리 할 수 있는 편리한 모듈

선택적인 인수:
  -h, --help            도움말 보기 및 종료
  --proxy PROXY_URL     hostname:port의 형식에서 프락시 URL
  --proxyuser PROXY_USER
                        기본 인증을 갖는 HTTP 프록시 사용자
  --proxypassword PROXY_PASSWORD
                        기본 인증을 갖는 HTTP 프록시 암호
  --noproxy NO_PROXY    HTTP 프록시를 사용하지 않는 호스트 접미사
  --show                현재 시스템 목적 표시

Syspurpose 하위모듈:
  
    addons              시스템 목적 추가구성 설정을 표시 또는 수정합니다
    role                시스템 목적 역할 설정을 표시 또는 수정합니다
    service-level       시스템 목적의 서비스-수준 설정을 보여주거나 변경합니다
    usage               시스템 목적 사용법 설정을 표시 또는 수정합니다

[root@ibm-x3650m4-01-vm-15 ~]# LANG=ko_KR.utf8 subscription-manager syspurpose set test
사용법: subscription-manager syspurpose [하위모듈] [옵션]
subscription-manager: 오류: argument : 잘못된 선택: 'set' ('addons', 'role', 'service-level', 'usage'에서 선택)


Verified:Tested - All of the "Unlocalized strings" from comment 1 are now translatable and have been completed in Korean.

Comment 11 Rehana 2022-02-17 11:49:08 UTC
Verifying on : 

# subscription-manager version
server type: This system is currently not registered.
subscription management server: 3.2.22-1
subscription management rules: 5.41
subscription-manager: 1.28.28-1.el8

# LANG=ko_KR.utf8 syspurpose -h
사용법: syspurpose [-h]
                {set,unset,add,remove,set-role,unset-role,add-addons,remove-addons,unset-addons,set-sla,unset-sla,set-usage,unset-usage,show}
                ...

시스템 Syspurpose 관리 도구

위치 인수:
  {set,unset,add,remove,set-role,unset-role,add-addons,remove-addons,unset-addons,set-sla,unset-sla,set-usage,unset-usage,show}
                        sub-command help
    set                 주어진 속성에 대한 값 설정
    unset               주어진 속성에 대한 설정 취소 (설정 지우기)
    add                 주어진 속성에 대한 값 추가
    remove              주어진 속성에서 값을 제거합니다
    set-role            시스템 역할을 시스템 syspurpose로 설정
    unset-role          역할 설정 삭제
    add-addons          시스템 syspurpose에 애드온 추가
    remove-addons       시스템 syspurpose에서 애드온 제거
    unset-addons        애드온 설정 삭제
    set-sla             시스템의 SLA 설정
    unset-sla           SLA 설정 해제
    set-usage           시스템의 사용 방법 설정
    unset-usage         사용 방법 설정 삭제
    show                현재 시스템의 syspurpose 표시

선택적인 인수:
  -h, --help            도움말 보기 및 종료

'syspurpose' 명령은 더 이상 사용되지 않으며 향후 주요 출시에서 제거될 것입니다. 앞으로 'subscription-manager
syspurpose' 명령을 사용하세요.

# LANG=ko_KR.utf8 syspurpose set test
사용법: syspurpose set [-h] property value
syspurpose set: 오류: 다음 인수가 필요합니다: value

# LANG=ko_KR.utf8 syspurpose add value test
'syspurpose' 명령은 더 이상 사용되지 않으며 향후 주요 출시에서 제거될 것입니다. 앞으로 'subscription-manager syspurpose' 명령을 사용하세요.
"test"가 value에 추가되었습니다.
value가 최신화되었습니다.

# LANG=ko_KR.utf8 syspurpose add value test
'syspurpose' 명령은 더 이상 사용되지 않으며 향후 주요 출시에서 제거될 것입니다. 앞으로 'subscription-manager syspurpose' 명령을 사용하세요.
값 "test"이 value에 추가되지 않았습니다; 이미 존재합니다.

#  LANG=ko_KR.utf8 subscription-manager syspurpose -h
사용법: subscription-manager syspurpose [하위모듈] [옵션]

모든 시스템 목적 설정을 관리 할 수 있는 편리한 모듈

선택적인 인수:
  -h, --help            도움말 보기 및 종료
  --proxy PROXY_URL     hostname:port의 형식에서 프락시 URL
  --proxyuser PROXY_USER
                        기본 인증을 갖는 HTTP 프록시 사용자
  --proxypassword PROXY_PASSWORD
                        기본 인증을 갖는 HTTP 프록시 암호
  --noproxy NO_PROXY    HTTP 프록시를 사용하지 않는 호스트 접미사
  --show                현재 시스템 목적 표시

Syspurpose 하위모듈:
  
    addons              시스템 목적 추가구성 설정을 표시 또는 수정합니다
    role                시스템 목적 역할 설정을 표시 또는 수정합니다
    service-level       시스템 목적의 서비스-수준 설정을 보여주거나 변경합니다
    usage               시스템 목적 사용법 설정을 표시 또는 수정합니다

# LANG=ko_KR.utf8 subscription-manager syspurpose set test
사용법: subscription-manager syspurpose [하위모듈] [옵션]
subscription-manager: 오류: argument : 잘못된 선택: 'set' ('addons', 'role', 'service-level', 'usage'에서 선택)

Untranslated strings from comment 0 is now resolved. Moving the bug to verified.

Comment 13 errata-xmlrpc 2022-05-10 15:22:57 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (subscription-manager bug fix and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2022:2047