-
Notifications
You must be signed in to change notification settings - Fork 7.4k
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
fix: bad strings format for command get-untraslated #34361
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mmdanny89
requested review from
rohitwaghchaure,
s-aga-r,
nextchamp-saqib,
deepeshgarg007 and
ruthra-kumar
as code owners
March 8, 2023 14:39
github-actions
bot
added
accounts
needs-tests
This PR needs automated unit-tests.
labels
Mar 8, 2023
akiratfli
pushed a commit
to akiratfli/erpnext
that referenced
this pull request
May 12, 2023
(cherry picked from commit ca10e2b)
frappe-pr-bot
pushed a commit
that referenced
this pull request
May 16, 2023
## [14.24.2](v14.24.1...v14.24.2) (2023-05-16) ### Bug Fixes * add missing options for `Content Align` ([3697e8f](3697e8f)) * allow over-payment against SO ([#35079](#35079)) ([fe9e0c2](fe9e0c2)) * bad strings format for command get-untraslated ([#34361](#34361)) ([5a54296](5a54296)) * bad strings format for update-translations ([#34592](#34592)) ([e3c1d73](e3c1d73)) * bom item filter issue ([098603d](098603d)) * cancelled vouchers in tax withheld vouchers list ([#35309](#35309)) ([c41e1d7](c41e1d7)) * enqueue submit/cancel action for stock entry to avoid time out error ([457846e](457846e)) * force to do reposting for cancelled document ([6f96e5d](6f96e5d)) * function `batch_no` should only be declared once ([#35115](#35115)) ([26928b3](26928b3)) * incorrect packing items ([ab56470](ab56470)) * inventory dimension for inter company transfer return use case ([6d121b8](6d121b8)) * inventory dimension for material transfer not working ([1d8050d](1d8050d)) * item list view not working ([d9efa66](d9efa66)) * port option for additional_conditions in item wise sales register ([#35187](#35187)) ([42037f9](42037f9)) * recalculate costs in SCR while reposting ([9a8ee62](9a8ee62)) * sales person allocated amount calculation error nonetype and float ([#35293](#35293)) ([3a7c69f](3a7c69f)) * test case ([3f8928b](3f8928b)) * test case ([9b2b467](9b2b467)) * typo ([2772a91](2772a91)) * unable to create partial invoice with auto fetch terms enabled ([#35285](#35285)) ([fa9fa97](fa9fa97)) * update workstation hour rate when workstation change in job card ([bc88415](bc88415)) * **UX:** misc "home" onboarding improvements (backport [#35319](#35319)) ([#35321](#35321)) ([f8c58b6](f8c58b6)) * validate for active sla ([#32132](#32132)) ([38e27a6](38e27a6)) ### Performance Improvements * cache and simplify queries for holiday list (backport [#35315](#35315)) ([#35318](#35318)) ([0e78403](0e78403))
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
When run: bench get-untranslated --app erpnext es /some/path/es.txt raise exception:
Traceback (most recent call last): File "/home/frappe/.pyenv/versions/3.10.5/lib/python3.10/runpy.py", line 196, in _run_module_as_main return _run_code(code, main_globals, None, File "/home/frappe/.pyenv/versions/3.10.5/lib/python3.10/runpy.py", line 86, in _run_code exec(code, run_globals) File "/workspace/development/frappe-bench/apps/frappe/frappe/utils/bench_helper.py", line 109, in <module> main() File "/workspace/development/frappe-bench/apps/frappe/frappe/utils/bench_helper.py", line 18, in main click.Group(commands=commands)(prog_name="bench") File "/workspace/development/frappe-bench/env/lib/python3.10/site-packages/click/core.py", line 829, in __call__ return self.main(*args, **kwargs) File "/workspace/development/frappe-bench/env/lib/python3.10/site-packages/click/core.py", line 782, in main rv = self.invoke(ctx) File "/workspace/development/frappe-bench/env/lib/python3.10/site-packages/click/core.py", line 1259, in invoke return _process_result(sub_ctx.command.invoke(sub_ctx)) File "/workspace/development/frappe-bench/env/lib/python3.10/site-packages/click/core.py", line 1259, in invoke return _process_result(sub_ctx.command.invoke(sub_ctx)) File "/workspace/development/frappe-bench/env/lib/python3.10/site-packages/click/core.py", line 1066, in invoke return ctx.invoke(self.callback, **ctx.params) File "/workspace/development/frappe-bench/env/lib/python3.10/site-packages/click/core.py", line 610, in invoke return callback(*args, **kwargs) File "/workspace/development/frappe-bench/env/lib/python3.10/site-packages/click/decorators.py", line 21, in new_func return f(get_current_context(), *args, **kwargs) File "/workspace/development/frappe-bench/apps/frappe/frappe/commands/__init__.py", line 29, in _func ret = f(frappe._dict(ctx.obj), *args, **kwargs) File "/workspace/development/frappe-bench/apps/frappe/frappe/commands/translate.py", line 64, in get_untranslated frappe.translate.get_untranslated(lang, untranslated_file, get_all=all, app=app) File "/workspace/development/frappe-bench/apps/frappe/frappe/translate.py", line 1047, in get_untranslated messages.extend(get_messages_for_app(app_name)) File "/workspace/development/frappe-bench/apps/frappe/frappe/translate.py", line 434, in get_messages_for_app messages.extend(get_server_messages(app)) File "/workspace/development/frappe-bench/apps/frappe/frappe/translate.py", line 664, in get_server_messages messages.extend(get_messages_from_file(os.path.join(basepath, f))) File "/workspace/development/frappe-bench/apps/frappe/frappe/translate.py", line 730, in get_messages_from_file messages += extract_messages_from_python_code(file_contents) File "/workspace/development/frappe-bench/apps/frappe/frappe/translate.py", line 750, in extract_messages_from_python_code for message in extract_python( File "/workspace/development/frappe-bench/env/lib/python3.10/site-packages/babel/messages/extract.py", line 487, in extract_python value = eval(code, {'__builtins__': {}}, {}) File "<string>", line 2, in <module> NameError: name 'doc' is not defined
And Other exception raise is:
Traceback (most recent call last): File "/home/frappe/.pyenv/versions/3.10.5/lib/python3.10/runpy.py", line 196, in _run_module_as_main return _run_code(code, main_globals, None, File "/home/frappe/.pyenv/versions/3.10.5/lib/python3.10/runpy.py", line 86, in _run_code exec(code, run_globals) File "/workspace/development/frappe-bench/apps/frappe/frappe/utils/bench_helper.py", line 109, in <module> main() File "/workspace/development/frappe-bench/apps/frappe/frappe/utils/bench_helper.py", line 18, in main click.Group(commands=commands)(prog_name="bench") File "/workspace/development/frappe-bench/env/lib/python3.10/site-packages/click/core.py", line 829, in __call__ return self.main(*args, **kwargs) File "/workspace/development/frappe-bench/env/lib/python3.10/site-packages/click/core.py", line 782, in main rv = self.invoke(ctx) File "/workspace/development/frappe-bench/env/lib/python3.10/site-packages/click/core.py", line 1259, in invoke return _process_result(sub_ctx.command.invoke(sub_ctx)) File "/workspace/development/frappe-bench/env/lib/python3.10/site-packages/click/core.py", line 1259, in invoke return _process_result(sub_ctx.command.invoke(sub_ctx)) File "/workspace/development/frappe-bench/env/lib/python3.10/site-packages/click/core.py", line 1066, in invoke return ctx.invoke(self.callback, **ctx.params) File "/workspace/development/frappe-bench/env/lib/python3.10/site-packages/click/core.py", line 610, in invoke return callback(*args, **kwargs) File "/workspace/development/frappe-bench/env/lib/python3.10/site-packages/click/decorators.py", line 21, in new_func return f(get_current_context(), *args, **kwargs) File "/workspace/development/frappe-bench/apps/frappe/frappe/commands/__init__.py", line 29, in _func ret = f(frappe._dict(ctx.obj), *args, **kwargs) File "/workspace/development/frappe-bench/apps/frappe/frappe/commands/translate.py", line 64, in get_untranslated frappe.translate.get_untranslated(lang, untranslated_file, get_all=all, app=app) File "/workspace/development/frappe-bench/apps/frappe/frappe/translate.py", line 1047, in get_untranslated messages.extend(get_messages_for_app(app_name)) File "/workspace/development/frappe-bench/apps/frappe/frappe/translate.py", line 434, in get_messages_for_app messages.extend(get_server_messages(app)) File "/workspace/development/frappe-bench/apps/frappe/frappe/translate.py", line 664, in get_server_messages messages.extend(get_messages_from_file(os.path.join(basepath, f))) File "/workspace/development/frappe-bench/apps/frappe/frappe/translate.py", line 730, in get_messages_from_file messages += extract_messages_from_python_code(file_contents) File "/workspace/development/frappe-bench/apps/frappe/frappe/translate.py", line 750, in extract_messages_from_python_code for message in extract_python( File "/workspace/development/frappe-bench/env/lib/python3.10/site-packages/babel/messages/extract.py", line 487, in extract_python value = eval(code, {'__builtins__': {}}, {}) File "<string>", line 2, in <module> NameError: name 'row' is not defined
This is caused by bad string format. in this lines