Comments (5)
Hello,
I see that you have replaced some osv.except_osv by orm.except_orm in try except during your pep8 issue. I think it is not a good idea for the compatibility. Because in some case openerp raise osv.except_osv and not orm.except_orm.
Sorry to come too late :(
Stack trace sample:
File "/home/lga/openerp/addons-banking/account_statement_ext/statement.py", line 608, in get_period
periods = period_obj.find(cr, uid, dt=date, context=local_context)
File "/home/lga/openerp/addons/account/account.py", line 1027, in find
raise osv.except_osv(('Error!'), _('There is no period defined for this date: %s.\nPlease create one.')%dt)
except_osv: (u'Error!', u'There is no period defined for this date: 2014-08-20.\nPlease create one.')
from account-reconcile.
Indeed, when catching, you must catch both except_orm and except_osv:
In [3]: try:
raise osv.except_osv('', '')
except orm.except_orm:
print('caught')
...:
---------------------------------------------------------------------------
except_osv Traceback (most recent call last)
python_dev in <module>()
1 try:
----> 2 raise osv.except_osv('', '')
3 except orm.except_orm:
4 print('caught')
5
except_osv: ('', '')
from account-reconcile.
You're right, Laetitia, although improbable, because all launch exceptions in the module are with orm.except_orm, but here it is the fix BTW: #38
from account-reconcile.
The stack trace sample come from a new installation. Maybe it is not the case for all try/except ;).
Thank you for the correction.
from account-reconcile.
PEP8 is clean on 7.0 so I will close this. Consider cleaning 6.1
from account-reconcile.
Related Issues (20)
- [16.0.1.2.2] account_reconcile_oca upgrade fails HOT 6
- [16.0] account_reconcile_oca: error when open transactions menu in runboat DB HOT 3
- [11.0] Incorrect Printing of Details and Summary Totals in Odoo 11 Account Reconciliation Module HOT 1
- [16.0] translation for account_reconcile_oca HOT 3
- [16] An error pops up when i select a transaction to reconcile HOT 1
- [16.0] account_reconcile_oca: Allow to skip reconciliation during statement import HOT 1
- Migration to version 17.0 HOT 2
- [16.0] Reconcile OCA, unable to add Tax with Manual Operation HOT 6
- [16.0] Reconcile Button is Missing HOT 5
- [15.0] account_reconciliation_widget incompatibilty with partner_multi_company HOT 1
- [16] After importing a bank statement, the Journal Items are created and published but still the bank statement can be removed. that's a problem HOT 1
- [16.0] account_reconcile_oca currency exchange valuation handling issues HOT 9
- [16.0] Partial reconciliation HOT 1
- Error when running on V.17: TypeError: Cannot read properties of undefined (reading 'name') HOT 3
- [14.0] Account Reconcile Widget don't works in account dashboard HOT 2
- Wrong amount displayed HOT 5
- Running Balance/Balance in GL in Dashboard Not Match with Actual Balance
- Singleton traceback on account_reconcile_oca
- [16.0] Account_reconcile_oca missing Manual operation and reconciliation model in reconcile entry menu
- [16.0] account_mass_reconcile no view of reconciled display items
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from account-reconcile.