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

fix: patch update_category_in_ltds_certificate #28168

Conversation

rohitwaghchaure
Copy link
Collaborator

Issue

Executing erpnext.patches.v13_0.update_category_in_ltds_certificate in v13_develop_site (_47304362d8865a95)
Traceback (most recent call last):
  File "/Users/rohitwaghchaure/.pyenv/versions/3.7.2/lib/python3.7/runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "/Users/rohitwaghchaure/.pyenv/versions/3.7.2/lib/python3.7/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/apps/frappe/frappe/utils/bench_helper.py", line 104, in <module>
    main()
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/apps/frappe/frappe/utils/bench_helper.py", line 18, in main
    click.Group(commands=commands)(prog_name='bench')
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/env/lib/python3.7/site-packages/click/core.py", line 829, in __call__
    return self.main(*args, **kwargs)
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/env/lib/python3.7/site-packages/click/core.py", line 782, in main
    rv = self.invoke(ctx)
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/env/lib/python3.7/site-packages/click/core.py", line 1259, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/env/lib/python3.7/site-packages/click/core.py", line 1259, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/env/lib/python3.7/site-packages/click/core.py", line 1066, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/env/lib/python3.7/site-packages/click/core.py", line 610, in invoke
    return callback(*args, **kwargs)
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/env/lib/python3.7/site-packages/click/decorators.py", line 21, in new_func
    return f(get_current_context(), *args, **kwargs)
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/apps/frappe/frappe/commands/__init__.py", line 26, in _func
    ret = f(frappe._dict(ctx.obj), *args, **kwargs)
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/apps/frappe/frappe/commands/site.py", line 309, in migrate
    skip_search_index=skip_search_index
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/apps/frappe/frappe/migrate.py", line 68, in migrate
    frappe.modules.patch_handler.run_all(skip_failing)
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/apps/frappe/frappe/modules/patch_handler.py", line 36, in run_all
    run_patch(patch)
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/apps/frappe/frappe/modules/patch_handler.py", line 25, in run_patch
    if not run_single(patchmodule = patch):
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/apps/frappe/frappe/modules/patch_handler.py", line 66, in run_single
    return execute_patch(patchmodule, method, methodargs)
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/apps/frappe/frappe/modules/patch_handler.py", line 86, in execute_patch
    frappe.get_attr(patchmodule.split()[0] + ".execute")()
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/apps/erpnext/erpnext/patches/v13_0/update_category_in_ltds_certificate.py", line 17, in execute
    ldc.tax_withholding_category.isnull()
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/apps/frappe/frappe/query_builder/utils.py", line 60, in execute_query
    return frappe.db.sql(query, *args, **kwargs)
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/apps/frappe/frappe/database/database.py", line 155, in sql
    self._cursor.execute(query)
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/env/lib/python3.7/site-packages/pymysql/cursors.py", line 148, in execute
    result = self._query(query)
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/env/lib/python3.7/site-packages/pymysql/cursors.py", line 310, in _query
    conn.query(q)
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/env/lib/python3.7/site-packages/pymysql/connections.py", line 548, in query
    self._affected_rows = self._read_query_result(unbuffered=unbuffered)
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/env/lib/python3.7/site-packages/pymysql/connections.py", line 775, in _read_query_result
    result.read()
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/env/lib/python3.7/site-packages/pymysql/connections.py", line 1156, in read
    first_packet = self.connection._read_packet()
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/env/lib/python3.7/site-packages/pymysql/connections.py", line 725, in _read_packet
    packet.raise_for_error()
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/env/lib/python3.7/site-packages/pymysql/protocol.py", line 221, in raise_for_error
    err.raise_mysql_exception(self._data)
  File "/Users/rohitwaghchaure/Documents/frappe_develop/frappe-bench/env/lib/python3.7/site-packages/pymysql/err.py", line 143, in raise_mysql_exception
    raise errorclass(errno, errval)
pymysql.err.OperationalError: (1054, "Unknown column 'ldc.tax_withholding_category' in 'field list'")

@codecov
Copy link

codecov bot commented Oct 31, 2021

Codecov Report

Merging #28168 (cae29b7) into develop (fb9e72c) will increase coverage by 0.00%.
The diff coverage is n/a.

@@           Coverage Diff            @@
##           develop   #28168   +/-   ##
========================================
  Coverage    55.39%   55.40%           
========================================
  Files         1248     1248           
  Lines        67721    67721           
========================================
+ Hits         37512    37518    +6     
+ Misses       30209    30203    -6     
Impacted Files Coverage Δ
erpnext/utilities/product.py 15.94% <0.00%> (-34.79%) ⬇️
erpnext/shopping_cart/product_info.py 32.35% <0.00%> (-20.59%) ⬇️
...payroll/doctype/income_tax_slab/income_tax_slab.py 85.71% <0.00%> (-14.29%) ⬇️
...ctype/woocommerce_settings/woocommerce_settings.py 80.39% <0.00%> (-3.93%) ⬇️
...e/asset_value_adjustment/asset_value_adjustment.py 87.80% <0.00%> (-3.66%) ⬇️
...e/shopping_cart_settings/shopping_cart_settings.py 66.03% <0.00%> (-1.89%) ⬇️
...ctype/accounting_dimension/accounting_dimension.py 64.34% <0.00%> (-1.56%) ⬇️
erpnext/shopping_cart/product_query.py 61.19% <0.00%> (-1.50%) ⬇️
...e/period_closing_voucher/period_closing_voucher.py 88.23% <0.00%> (-1.48%) ⬇️
erpnext/portal/utils.py 30.00% <0.00%> (-1.43%) ⬇️
... and 17 more

@rohitwaghchaure rohitwaghchaure merged commit 69dd8b7 into frappe:develop Oct 31, 2021
rohitwaghchaure added a commit that referenced this pull request Oct 31, 2021
…se/pr-28168

fix: patch update_category_in_ltds_certificate (backport #28168)
rohitwaghchaure added a commit that referenced this pull request Oct 31, 2021
…-28168

fix: patch update_category_in_ltds_certificate (backport #28168)
asoral pushed a commit to asoral/erpnext that referenced this pull request Nov 12, 2021
…-release/pr-28168

fix: patch update_category_in_ltds_certificate (backport frappe#28168)
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 9, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant