Expense / Difference account (Temporary Liabilities must be a 'Profit or Loss' account

making an opening stocks with serials the difference account should be temporary liabilities but this error shows up
Expense / Difference account (Temporary Liabilities - WEB) must be a ‘Profit or Loss’ account

Allowed non-profit-and-loss account in stock entry

pardon me sir. but how do i do that? can you please clarify?

I mean, I have change the code, now if you update your instance, system will allow ‘temporary liability’ account in stock entry.

sir the issue still exists.

i have updated my server, reboot, cleared my cache, tried different browser. still the error shows up when making an opening stocks on material receipt and choosing temporary liabilities as difference account

“Expense / Difference account (Temporary Liabilities - WEB) must be a ‘Profit or Loss’ account”

Share the error traceback from browser’s console, when you are getting the error message.

this one?

Timestamp: 1/4/2015 7:19:45 PM
Warning: SyntaxError: test for equality (==) mistyped as assignment (=)?
Source File: http://128.199.129.206/assets/frappe/js/lib/jquery/jquery.min.js
Line: 2, Column: 6088
Source Code:
ll(b))}:function(a,b){var c=a.length,d=0;while(a[c++]=b[d++]);a.length=c-1}}}function db(a,b,d,e){var f,g,h,i,j,m,p,q,u,

This is not correct traceback. Check following link:

hi sir,

here

“Cleared Cache - New Metadata” frappe.min.js:344
"Traceback (innermost last):
File “/home/frappe/frappe-bench/apps/frappe/frappe/widgets/form/save.py”, line 18, in savedocs
doc.save()
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 216, in save
self.run_post_save_methods()
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 445, in run_post_save_methods
self.run_method(“on_submit”)
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 412, in run_method
return Document.hook(fn)(self, *args, **kwargs)
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 493, in composer
return composed(self, method, *args, **kwargs)
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 476, in runner
add_to_return_value(self, fn(self, *args, **kwargs))
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 406, in
fn = lambda self, *args, **kwargs: getattr(self, method)(*args, **kwargs)
File “/home/frappe/frappe-bench/apps/erpnext/erpnext/stock/doctype/stock_entry/stock_entry.py”, line 64, in on_submit
self.make_gl_entries()
File “/home/frappe/frappe-bench/apps/erpnext/erpnext/controllers/stock_controller.py”, line 22, in make_gl_entries
gl_entries = self.get_gl_entries(warehouse_account)
File “/home/frappe/frappe-bench/apps/erpnext/erpnext/controllers/stock_controller.py”, line 48, in get_gl_entries
self.check_expense_account(detail)
File “/home/frappe/frappe-bench/apps/erpnext/erpnext/controllers/stock_controller.py”, line 172, in check_expense_account
.format(item.get(“expense_account”)))
File “/home/frappe/frappe-bench/apps/frappe/frappe/init.py”, line 202, in throw
msgprint(msg, raise_exception=exc)
File “/home/frappe/frappe-bench/apps/frappe/frappe/init.py”, line 199, in msgprint
_raise_exception()
File “/home/frappe/frappe-bench/apps/frappe/frappe/init.py”, line 183, in _raise_exception
raise raise_exception, msg
ValidationError: Expense / Difference account (Temporary Liabilities Web QC - WEB) must be a ‘Profit or Loss’ account
" frappe.min.js:310
"Traceback (innermost last):
File “/home/frappe/frappe-bench/apps/frappe/frappe/app.py”, line 49, in application
response = frappe.handler.handle()
File “/home/frappe/frappe-bench/apps/frappe/frappe/handler.py”, line 66, in handle
execute_cmd(cmd)
File “/home/frappe/frappe-bench/apps/frappe/frappe/handler.py”, line 89, in execute_cmd
ret = frappe.call(method, **frappe.form_dict)
File “/home/frappe/frappe-bench/apps/frappe/frappe/init.py”, line 531, in call
return fn(*args, **newargs)
File “/home/frappe/frappe-bench/apps/frappe/frappe/widgets/form/save.py”, line 18, in savedocs
doc.save()
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 216, in save
self.run_post_save_methods()
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 445, in run_post_save_methods
self.run_method(“on_submit”)
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 412, in run_method
return Document.hook(fn)(self, *args, **kwargs)
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 493, in composer
return composed(self, method, *args, **kwargs)
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 476, in runner
add_to_return_value(self, fn(self, *args, **kwargs))
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 406, in
fn = lambda self, *args, **kwargs: getattr(self, method)(*args, **kwargs)
File “/home/frappe/frappe-bench/apps/erpnext/erpnext/stock/doctype/stock_entry/stock_entry.py”, line 64, in on_submit
self.make_gl_entries()
File “/home/frappe/frappe-bench/apps/erpnext/erpnext/controllers/stock_controller.py”, line 22, in make_gl_entries
gl_entries = self.get_gl_entries(warehouse_account)
File “/home/frappe/frappe-bench/apps/erpnext/erpnext/controllers/stock_controller.py”, line 48, in get_gl_entries
self.check_expense_account(detail)
File “/home/frappe/frappe-bench/apps/erpnext/erpnext/controllers/stock_controller.py”, line 172, in check_expense_account
.format(item.get(“expense_account”)))
File “/home/frappe/frappe-bench/apps/frappe/frappe/init.py”, line 202, in throw
msgprint(msg, raise_exception=exc)
File “/home/frappe/frappe-bench/apps/frappe/frappe/init.py”, line 199, in msgprint
_raise_exception()
File “/home/frappe/frappe-bench/apps/frappe/frappe/init.py”, line 183, in _raise_exception
raise raise_exception, msg
ValidationError: Expense / Difference account (Temporary Liabilities Web QC - WEB) must be a ‘Profit or Loss’ account
" frappe.min.js:310
"Traceback (innermost last):
File “/home/frappe/frappe-bench/apps/frappe/frappe/widgets/form/save.py”, line 18, in savedocs
doc.save()
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 216, in save
self.run_post_save_methods()
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 445, in run_post_save_methods
self.run_method(“on_submit”)
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 412, in run_method
return Document.hook(fn)(self, *args, **kwargs)
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 493, in composer
return composed(self, method, *args, **kwargs)
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 476, in runner
add_to_return_value(self, fn(self, *args, **kwargs))
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 406, in
fn = lambda self, *args, **kwargs: getattr(self, method)(*args, **kwargs)
File “/home/frappe/frappe-bench/apps/erpnext/erpnext/stock/doctype/stock_entry/stock_entry.py”, line 64, in on_submit
self.make_gl_entries()
File “/home/frappe/frappe-bench/apps/erpnext/erpnext/controllers/stock_controller.py”, line 22, in make_gl_entries
gl_entries = self.get_gl_entries(warehouse_account)
File “/home/frappe/frappe-bench/apps/erpnext/erpnext/controllers/stock_controller.py”, line 48, in get_gl_entries
self.check_expense_account(detail)
File “/home/frappe/frappe-bench/apps/erpnext/erpnext/controllers/stock_controller.py”, line 172, in check_expense_account
.format(item.get(“expense_account”)))
File “/home/frappe/frappe-bench/apps/frappe/frappe/init.py”, line 202, in throw
msgprint(msg, raise_exception=exc)
File “/home/frappe/frappe-bench/apps/frappe/frappe/init.py”, line 199, in msgprint
_raise_exception()
File “/home/frappe/frappe-bench/apps/frappe/frappe/init.py”, line 183, in _raise_exception
raise raise_exception, msg
ValidationError: Expense / Difference account (Temporary Liabilities Web QC - WEB) must be a ‘Profit or Loss’ account
" frappe.min.js:310
"Traceback (innermost last):
File “/home/frappe/frappe-bench/apps/frappe/frappe/app.py”, line 49, in application
response = frappe.handler.handle()
File “/home/frappe/frappe-bench/apps/frappe/frappe/handler.py”, line 66, in handle
execute_cmd(cmd)
File “/home/frappe/frappe-bench/apps/frappe/frappe/handler.py”, line 89, in execute_cmd
ret = frappe.call(method, **frappe.form_dict)
File “/home/frappe/frappe-bench/apps/frappe/frappe/init.py”, line 531, in call
return fn(*args, **newargs)
File “/home/frappe/frappe-bench/apps/frappe/frappe/widgets/form/save.py”, line 18, in savedocs
doc.save()
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 216, in save
self.run_post_save_methods()
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 445, in run_post_save_methods
self.run_method(“on_submit”)
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 412, in run_method
return Document.hook(fn)(self, *args, **kwargs)
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 493, in composer
return composed(self, method, *args, **kwargs)
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 476, in runner
add_to_return_value(self, fn(self, *args, **kwargs))
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py”, line 406, in
fn = lambda self, *args, **kwargs: getattr(self, method)(*args, **kwargs)
File “/home/frappe/frappe-bench/apps/erpnext/erpnext/stock/doctype/stock_entry/stock_entry.py”, line 64, in on_submit
self.make_gl_entries()
File “/home/frappe/frappe-bench/apps/erpnext/erpnext/controllers/stock_controller.py”, line 22, in make_gl_entries
gl_entries = self.get_gl_entries(warehouse_account)
File “/home/frappe/frappe-bench/apps/erpnext/erpnext/controllers/stock_controller.py”, line 48, in get_gl_entries
self.check_expense_account(detail)
File “/home/frappe/frappe-bench/apps/erpnext/erpnext/controllers/stock_controller.py”, line 172, in check_expense_account
.format(item.get(“expense_account”)))
File “/home/frappe/frappe-bench/apps/frappe/frappe/init.py”, line 202, in throw
msgprint(msg, raise_exception=exc)
File “/home/frappe/frappe-bench/apps/frappe/frappe/init.py”, line 199, in msgprint
_raise_exception()
File “/home/frappe/frappe-bench/apps/frappe/frappe/init.py”, line 183, in _raise_exception
raise raise_exception, msg
ValidationError: Expense / Difference account (Temporary Liabilities Web QC - WEB) must be a ‘Profit or Loss’ account
" frappe.min.js:310
ReferenceError: reference to undefined property jQuery.hotkeys.shiftNums[character] frappe.min.js:38

Are you in master branch? I have fixed the issue in develop branch, it will be merged in master today/tomorrow.

im in master branch. the production.

by the way. thank you sir.

Hello,
Would like to point some light on this error in Delivery Note.

When Items are delivered then It can be put in Temporary Asset Account until the whole project is completely and manually moved from Temporary Asset account to COGS account by the Account user.

So might have to allow Non-P&L accounts for Delivery Notes, Item Expense account. There is also a lock in Item Master form Expense Accounts only. In some big projects they cannot consider it an expense until the whole project is completed.

I hope someone must have faced something similar??
Looking forward for some advice on this.
Thanks.