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: not able to submit subcontracting pr (old flow) #39622

Conversation

rohitwaghchaure
Copy link
Collaborator

Issue

  File "apps/erpnext/erpnext/stock/doctype/purchase_receipt/purchase_receipt.py", line 377, in on_submit
    self.set_consumed_qty_in_subcontract_order()
  File "apps/erpnext/erpnext/controllers/subcontracting_controller.py", line 780, in set_consumed_qty_in_subcontract_order
    consumed_items, receipt_items = self.__update_consumed_materials(
                                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "apps/erpnext/erpnext/controllers/subcontracting_controller.py", line 288, in __update_consumed_materials
    consumed_materials = self.__get_consumed_items(doctype, receipt_items.keys())
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "apps/erpnext/erpnext/controllers/subcontracting_controller.py", line 263, in __get_consumed_items
    return frappe.get_all(
           ^^^^^^^^^^^^^^^
  File "apps/frappe/frappe/__init__.py", line 1970, in get_all
    return get_list(doctype, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "apps/frappe/frappe/__init__.py", line 1945, in get_list
    return frappe.model.db_query.DatabaseQuery(doctype).execute(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "apps/frappe/frappe/model/db_query.py", line 203, in execute
    result = self.build_and_run()
             ^^^^^^^^^^^^^^^^^^^^
  File "apps/frappe/frappe/model/db_query.py", line 243, in build_and_run
    return frappe.db.sql(
           ^^^^^^^^^^^^^^
  File "apps/frappe/frappe/database/database.py", line 235, in sql
    self._cursor.execute(query, values)
  File "env/lib/python3.11/site-packages/pymysql/cursors.py", line 153, in execute
    result = self._query(query)
             ^^^^^^^^^^^^^^^^^^
  File "env/lib/python3.11/site-packages/pymysql/cursors.py", line 322, in _query
    conn.query(q)
  File "env/lib/python3.11/site-packages/pymysql/connections.py", line 558, in query
    self._affected_rows = self._read_query_result(unbuffered=unbuffered)
                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "env/lib/python3.11/site-packages/pymysql/connections.py", line 822, in _read_query_result
    result.read()
  File "env/lib/python3.11/site-packages/pymysql/connections.py", line 1200, in read
    first_packet = self.connection._read_packet()
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "env/lib/python3.11/site-packages/pymysql/connections.py", line 772, in _read_packet
    packet.raise_for_error()
  File "env/lib/python3.11/site-packages/pymysql/protocol.py", line 221, in raise_for_error
    err.raise_mysql_exception(self._data)
  File "env/lib/python3.11/site-packages/pymysql/err.py", line 143, in raise_mysql_exception
    raise errorclass(errno, errval)
pymysql.err.OperationalError: (1054, "Unknown column 'serial_and_batch_bundle' in 'field list'")

@github-actions github-actions bot added the needs-tests This PR needs automated unit-tests. label Jan 29, 2024
@rohitwaghchaure rohitwaghchaure added backport version-15-hotfix and removed needs-tests This PR needs automated unit-tests. labels Jan 29, 2024
Copy link

codecov bot commented Jan 29, 2024

Codecov Report

Attention: 3 lines in your changes are missing coverage. Please review.

Comparison is base (ebc8230) 60.09% compared to head (0968118) 60.20%.
Report is 136 commits behind head on develop.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop   #39622      +/-   ##
===========================================
+ Coverage    60.09%   60.20%   +0.11%     
===========================================
  Files          757      757              
  Lines        70434    70802     +368     
===========================================
+ Hits         42325    42625     +300     
- Misses       28109    28177      +68     
Files Coverage Δ
erpnext/controllers/subcontracting_controller.py 89.43% <100.00%> (+0.05%) ⬆️
...tax_withholding_details/tax_withholding_details.py 81.14% <90.00%> (ø)

... and 35 files with indirect coverage changes

@rohitwaghchaure rohitwaghchaure merged commit 5cf47ae into frappe:develop Jan 29, 2024
15 checks passed
mergify bot pushed a commit that referenced this pull request Jan 29, 2024
rohitwaghchaure added a commit that referenced this pull request Jan 29, 2024
#39625)

fix: not able to submit subcontracting pr (old flow) (#39622)

(cherry picked from commit 5cf47ae)

Co-authored-by: rohitwaghchaure <rohitw1991@gmail.com>
frappe-pr-bot pushed a commit that referenced this pull request Jan 30, 2024
# [15.11.0](v15.10.8...v15.11.0) (2024-01-30)

### Bug Fixes

* AttributeError in company transaction deletion ([222005c](222005c))
* **Batch:** reload doc after splitting ([a97b8fd](a97b8fd))
* check page obj before adding menu ([0aa73e3](0aa73e3))
* default enable closing stock balance (backport [#39551](#39551)) ([#39554](#39554)) ([4853ab1](4853ab1))
* do not auto-populate item delivery date ([5cdc22a](5cdc22a))
* email list for auto reorder material request ([98c5653](98c5653))
* enqueue JV submission when more than 100 accounts ([07bcc24](07bcc24))
* fetch correct quantity and amount for grouped asset ([3bdd1e9](3bdd1e9))
* honour currency precision while fetching balance ([e0a3820](e0a3820))
* incorrect active serial nos (backport [#39389](#39389)) ([#39589](#39589)) ([7def475](7def475))
* incorrect amount in the material request item (backport [#39567](#39567)) ([#39569](#39569)) ([e0c35d6](e0c35d6))
* Item Tax template is not working for e-commerce ([2905db1](2905db1))
* make SO item code reqd ([171586d](171586d))
* not able to edit address through portal ([1f5dbeb](1f5dbeb))
* not able to save BOM (duplicate key error) (backport [#39620](#39620)) ([#39623](#39623)) ([53c7055](53c7055))
* not able to save subcontracting purchase receipt (old flow) (backport [#39590](#39590)) ([#39592](#39592)) ([63eef68](63eef68))
* not able to submit subcontracting pr (old flow) (backport [#39622](#39622)) ([#39625](#39625)) ([960443d](960443d))
* Payment Terms Status for Sales Order report should show all payment terms from order not only this comming from template ([b2e0d24](b2e0d24))
* perf issue while submitting stock entry (backport [#39634](#39634)) ([#39642](#39642)) ([d785c6c](d785c6c))
* prevent extra transfer against inter transfer transaction (backport [#39213](#39213)) ([#39596](#39596)) ([6d4ca6a](6d4ca6a))
* qtn tests using delivery date ([6b20a7e](6b20a7e))
* return doc obj after submit ([da33079](da33079))
* Serial No Ledger permission issue ([f9d1995](f9d1995))
* skip liability account for internal transfer ([e2d85c5](e2d85c5))
* type error on company doc ([a7d1368](a7d1368))

### Features

* In words in payment entry ([5df2f5d](5df2f5d))
* New financial views - Growth and margin views for P&L and balance sheet ([#39588](#39588)) ([a83f310](a83f310))
* Partly billed status in Purchase Receipt ([#39543](#39543)) ([e4230cf](e4230cf))
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 13, 2024
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