Re: [Openerp-community-reviewer] [Merge] lp:~akretion-team/server-env-tools/server-env-tools into lp:server-env-tools
Hi Sébastien, could you be a bit more specific in the branch description, what's the intended scope/purpose, that kind of thing ? Maybe as a short, committed doc file ? Am I right to believe that you did a new field parly to avoid the base64 roundtrips ? Maybe I overlooked it, but the controllers need serious work too (current OpenERP 7 impl is feeble to say the least. BTW, I'm interested because of the Postgres Large Object support we published on Bitbucket (https://bitbucket.org/anybox/advanced_attachment/src/37ba6c51432bb106b30c500a00b89ff91c9e5ccc/attachment_large_object/?at=default) Thanks ! -- https://code.launchpad.net/~akretion-team/server-env-tools/server-env-tools/+merge/91 Your team Server Environment And Tools Core Editors is subscribed to branch lp:server-env-tools. -- Mailing list: https://launchpad.net/~openerp-community-reviewer Post to : openerp-community-reviewer@lists.launchpad.net Unsubscribe : https://launchpad.net/~openerp-community-reviewer More help : https://help.launchpad.net/ListHelp
Re: [Openerp-community-reviewer] [Merge] lp:~camptocamp/ocb-addons/ocb-7.0-fix_broken_purchase_requisition_tests_1278078-afe into lp:ocb-addons
Review: Approve Test passes for me and I also got a wholly green build for all modules (excluding l10n_lu and document_ftp) I like the simplicity of creating a new requisition to test cancellation. As a side note, shouldn't we take this opportunity to fix the error message for the non-cancellable one (obviously copy-pasted from purchase_order) ? I guess that'd create a new l10n msgid, hence that should maybe be handled separately -- https://code.launchpad.net/~camptocamp/ocb-addons/ocb-7.0-fix_broken_purchase_requisition_tests_1278078-afe/+merge/209925 Your team OpenERP Community Backports Team is requested to review the proposed merge of lp:~camptocamp/ocb-addons/ocb-7.0-fix_broken_purchase_requisition_tests_1278078-afe into lp:ocb-addons. -- Mailing list: https://launchpad.net/~openerp-community-reviewer Post to : openerp-community-reviewer@lists.launchpad.net Unsubscribe : https://launchpad.net/~openerp-community-reviewer More help : https://help.launchpad.net/ListHelp
Re: [Openerp-community-reviewer] [Merge] lp:~anybox/ocb-server/7.0-test-report into lp:ocb-server
Leonardo: actually what --tests-enable (or oe initialize --tests) do is not so generic, since it does interleaving of modules initialisation and tests, so that each module's test suite is run with exactly the same demo data set no matter what dependent modules could later add. Of course that's a consequence of the whole design of these tests. Other frameworks I used to work with solved the same kind of problems in other ways. Rvalyi: thanks for the welcome ! You must have missed it, but right after Stefan's comment, I complied and created a bug, then linked the two branches to it. -- https://code.launchpad.net/~anybox/ocb-server/7.0-test-report/+merge/207978 Your team OpenERP Community Backports Team is subscribed to branch lp:ocb-server. -- Mailing list: https://launchpad.net/~openerp-community-reviewer Post to : openerp-community-reviewer@lists.launchpad.net Unsubscribe : https://launchpad.net/~openerp-community-reviewer More help : https://help.launchpad.net/ListHelp
Re: [Openerp-community-reviewer] [Merge] lp:~anybox/ocb-server/7.0-test-report into lp:ocb-server
For the record, the branch against mainline openobject-addons has been updated, too -- https://code.launchpad.net/~anybox/ocb-server/7.0-test-report/+merge/207978 Your team OpenERP Community Backports Team is subscribed to branch lp:ocb-server. -- Mailing list: https://launchpad.net/~openerp-community-reviewer Post to : openerp-community-reviewer@lists.launchpad.net Unsubscribe : https://launchpad.net/~openerp-community-reviewer More help : https://help.launchpad.net/ListHelp
Re: [Openerp-community-reviewer] [Merge] lp:~anybox/ocb-server/7.0-test-report into lp:ocb-server
Just pushed a new revision that addresses Holger's concern and Leonardo's remark by requesting the module's base path from openerp.module.module API. misc.file_open does not proceed itself this way, but in case of discrepancy, I guess OpenERP would be in far more trouble than getting a yml test file path wrong in a test report... I checked quickly that it's consistent, though. -- https://code.launchpad.net/~anybox/ocb-server/7.0-test-report/+merge/207978 Your team OpenERP Community Backports Team is subscribed to branch lp:ocb-server. -- Mailing list: https://launchpad.net/~openerp-community-reviewer Post to : openerp-community-reviewer@lists.launchpad.net Unsubscribe : https://launchpad.net/~openerp-community-reviewer More help : https://help.launchpad.net/ListHelp
Re: [Openerp-community-reviewer] [Merge] lp:~anybox/ocb-server/7.0-test-report into lp:ocb-server
Hi Holger, thanks for the review. Yes you're right: I thought that tools.file_open did some normalization on '/' (similar to an URL) to do its magic lookup in the wanted addons directory, but after re-reading its code, I see it does not, and indeed expects the incoming ``name`` argument to be built with os.sep, as in: if name.replace(os.sep, '/').startswith('addons/'): subdir = 'addons' name2 = name[7:] That's probably because it also accepts absolute paths. btw, I don't know of any platform where os.sep is more than 1 char, but the above extract would be wrong on it. -- https://code.launchpad.net/~anybox/ocb-server/7.0-test-report/+merge/207978 Your team OpenERP Community Backports Team is subscribed to branch lp:ocb-server. -- Mailing list: https://launchpad.net/~openerp-community-reviewer Post to : openerp-community-reviewer@lists.launchpad.net Unsubscribe : https://launchpad.net/~openerp-community-reviewer More help : https://help.launchpad.net/ListHelp
Re: [Openerp-community-reviewer] [Merge] lp:~anybox/ocb-server/7.0-test-report into lp:ocb-server
but I believe even in runbot, that could prove useful (don't know what's in current trunk, though) -- https://code.launchpad.net/~anybox/ocb-server/7.0-test-report/+merge/207978 Your team OpenERP Community Backports Team is requested to review the proposed merge of lp:~anybox/ocb-server/7.0-test-report into lp:ocb-server. -- Mailing list: https://launchpad.net/~openerp-community-reviewer Post to : openerp-community-reviewer@lists.launchpad.net Unsubscribe : https://launchpad.net/~openerp-community-reviewer More help : https://help.launchpad.net/ListHelp
Re: [Openerp-community-reviewer] [Merge] lp:~anybox/ocb-server/7.0-test-report into lp:ocb-server
Hi Stefan, thanks for kindly explaining policy ! I started indeed developing the change in OCB context (where it is useful now). -- https://code.launchpad.net/~anybox/ocb-server/7.0-test-report/+merge/207978 Your team OpenERP Community Backports Team is requested to review the proposed merge of lp:~anybox/ocb-server/7.0-test-report into lp:ocb-server. -- Mailing list: https://launchpad.net/~openerp-community-reviewer Post to : openerp-community-reviewer@lists.launchpad.net Unsubscribe : https://launchpad.net/~openerp-community-reviewer More help : https://help.launchpad.net/ListHelp
[Openerp-community-reviewer] [Merge] lp:~anybox/ocb-server/7.0-test-report into lp:ocb-server
Georges Racinet has proposed merging lp:~anybox/ocb-server/7.0-test-report into lp:ocb-server. Requested reviews: OpenERP Community Backports Team (ocb) For more details, see: https://code.launchpad.net/~anybox/ocb-server/7.0-test-report/+merge/207978 The core of OpenERP already has a system to report test failures (data loading, YML tests, true unit tests). This non too-intrusive change enhances it to record more detail, allowing the launcher process to end with a useful summary. There is a matching branch of openerp-command/7.0 that simply prints the data at the end of the test of all modules. It is I believe already enough to help maintainers quickly get an idea of the errors and dispatch them accordingly. Here's a sample output for the current broken tests in OCB: FAIL : 2 failure(s) or error(s) have been recorded Module account_payment, in test file u'test/payment_order_process.yml': AssertionError in Python code : Due date is not correct. Module purchase_requisition: Exception during load of legacy data-based tests (yml...) See http://buildbot.anybox.fr/builders/ocb-7.0-postgresql-9.3/builds/273/steps/testing/logs/stdio for the full log. -- https://code.launchpad.net/~anybox/ocb-server/7.0-test-report/+merge/207978 Your team OpenERP Community Backports Team is requested to review the proposed merge of lp:~anybox/ocb-server/7.0-test-report into lp:ocb-server. === modified file 'openerp/modules/loading.py' --- openerp/modules/loading.py 2013-11-25 10:38:42 + +++ openerp/modules/loading.py 2014-02-24 17:07:10 + @@ -197,13 +197,21 @@ # 'data' section, but should probably not alter the data, # as there is no rollback. if tools.config.options['test_enable']: -report.record_result(load_test(module_name, idref, mode)) - +report.record_result(load_test(module_name, idref, mode), + details=(dict(module=module_name, + msg="Exception during load of legacy " + "data-based tests (yml...)"))) # Run the `fast_suite` and `checks` tests given by the module. if module_name == 'base': # Also run the core tests after the database is created. -report.record_result(openerp.modules.module.run_unit_tests('openerp')) -report.record_result(openerp.modules.module.run_unit_tests(module_name)) +report.record_result(openerp.modules.module.run_unit_tests('openerp'), + details=dict(module='openerp', + msg="Failure or error in server core " + "unit tests")) +report.record_result(openerp.modules.module.run_unit_tests(module_name), + details=dict(module=module_name, + msg="Failure or error in unit tests, " + "check logs for more details")) processed_modules.append(package.name) === modified file 'openerp/tools/assertion_report.py' --- openerp/tools/assertion_report.py 2012-03-02 11:02:27 + +++ openerp/tools/assertion_report.py 2014-02-24 17:07:10 + @@ -8,20 +8,28 @@ def __init__(self): self.successes = 0 self.failures = 0 +self.failures_details = [] def record_success(self): self.successes += 1 -def record_failure(self): +def record_failure(self, details=None): self.failures += 1 - -def record_result(self, result): +if details is not None: +self.failures_details.append(details) + +def record_result(self, result, details=None): +"""Record either success or failure, with the provided details in the latter case. + +:param result: a boolean +:param details: a dict with keys ``'module'``, ``'testfile'``, ``'msg'``, ``'msg_args'`` +""" if result is None: pass elif result is True: self.record_success() elif result is False: -self.record_failure() +self.record_failure(details=details) def __str__(self): res = 'Assertions report: %s successes, %s failures' % (self.successes, self.failures) === modified file 'openerp/tools/convert.py' --- openerp/tools/convert.py 2013-12-03 09:24:33 + +++ openerp/tools/convert.py 2014-02-24 17:07:10 + @@
[Openerp-community-reviewer] [Bug 1278080] [NEW] Broken yml test in account_payment
Public bug reported: The error : openerp.tools.yaml_import: AssertionError in Python code : Due date is not correct. The YML test file : test/payment_order_process.yml Extract : !python {model: payment.order}: | invoice = self.pool.get('account.invoice').browse(cr, uid, ref("account.demo _invoice_0")) payment = self.browse(cr, uid, ref("payment_order_1")) payment_line = payment.line_ids[0] assert payment_line.move_line_id, "move line is not created in payment line." assert invoice.move_id.name == payment_line.ml_inv_ref.number, "invoice reference number is not same created." assert invoice.partner_id == payment_line.partner_id, "Partner is not correct." assert invoice.date_due == payment_line.ml_maturity_date, "Due date is not correct." According to the summary pad http://pad.openerp.com/p/ocb-status, the first suspect would be https://code.launchpad.net/~camptocamp/ocb- addons/7.0-fix-bug-1102078 ** Affects: ocb-addons Importance: Undecided Status: New -- You received this bug notification because you are a member of OpenERP Community Backports Team, which is subscribed to OpenERP Community Backports (Addons). https://bugs.launchpad.net/bugs/1278080 Title: Broken yml test in account_payment Status in OpenERP Community Backports (Addons): New Bug description: The error : openerp.tools.yaml_import: AssertionError in Python code : Due date is not correct. The YML test file : test/payment_order_process.yml Extract : !python {model: payment.order}: | invoice = self.pool.get('account.invoice').browse(cr, uid, ref("account.demo _invoice_0")) payment = self.browse(cr, uid, ref("payment_order_1")) payment_line = payment.line_ids[0] assert payment_line.move_line_id, "move line is not created in payment line." assert invoice.move_id.name == payment_line.ml_inv_ref.number, "invoice reference number is not same created." assert invoice.partner_id == payment_line.partner_id, "Partner is not correct." assert invoice.date_due == payment_line.ml_maturity_date, "Due date is not correct." According to the summary pad http://pad.openerp.com/p/ocb-status, the first suspect would be https://code.launchpad.net/~camptocamp/ocb- addons/7.0-fix-bug-1102078 To manage notifications about this bug go to: https://bugs.launchpad.net/ocb-addons/+bug/1278080/+subscriptions -- Mailing list: https://launchpad.net/~openerp-community-reviewer Post to : openerp-community-reviewer@lists.launchpad.net Unsubscribe : https://launchpad.net/~openerp-community-reviewer More help : https://help.launchpad.net/ListHelp
[Openerp-community-reviewer] [Bug 1278078] [NEW] Broken yml test for purchase requisition
Public bug reported: Since that merge : https://code.launchpad.net/~therp-nl/ocb-addons/lp1220716/+merge/184072, the yml tests for purchase requisition are broken. As reported by sbi on the merge request: File "~/addons/purchase_requisition/test/cancel_purchase_requisition.yml", line 1, in - File "~/addons/purchase_requisition/purchase_requisition.py", line 105, in tender_cancel purchase_order_obj.action_cancel(cr, uid, purchase_ids, context=context) File "~/addons/purchase/purchase.py", line 584, in action_cancel _('First cancel all receptions related to this purchase order.')) except_osv: (u'Unable to cancel this purchase order.', u'First cancel all receptions related to this purchase order.') Since that was a backport of an OPW support branch, chances are that one of the current openobject-addons 7.0 or saas branches does not exhibit similar problem. That'll be the first focus of investigation. ** Affects: ocb-addons Importance: Undecided Status: New ** Description changed: Since that merge : https://code.launchpad.net/~therp-nl/ocb-addons/lp1220716/+merge/184072, the yml tests for purchase requisition are broken. As reported by sbi on the merge request: - File "~/addons/purchase_requisition/test/cancel_purchase_requisition.yml", line 1, in - - - File "~/addons/purchase_requisition/purchase_requisition.py", line 105, in tender_cancel - purchase_order_obj.action_cancel(cr, uid, purchase_ids, context=context) - File "~/addons/purchase/purchase.py", line 584, in action_cancel - _('First cancel all receptions related to this purchase order.')) + File "~/addons/purchase_requisition/test/cancel_purchase_requisition.yml", line 1, in + - + File "~/addons/purchase_requisition/purchase_requisition.py", line 105, in tender_cancel + purchase_order_obj.action_cancel(cr, uid, purchase_ids, context=context) + File "~/addons/purchase/purchase.py", line 584, in action_cancel + _('First cancel all receptions related to this purchase order.')) except_osv: (u'Unable to cancel this purchase order.', u'First cancel all receptions related to this purchase order.') - Since that was a backport of an OPW support branch, chances are that on + Since that was a backport of an OPW support branch, chances are that one of the current openobject-addons 7.0 or saas branches does not exhibit similar problem. That'll be the first focus of investigation. -- You received this bug notification because you are a member of OpenERP Community Backports Team, which is subscribed to OpenERP Community Backports (Addons). https://bugs.launchpad.net/bugs/1278078 Title: Broken yml test for purchase requisition Status in OpenERP Community Backports (Addons): New Bug description: Since that merge : https://code.launchpad.net/~therp-nl/ocb-addons/lp1220716/+merge/184072, the yml tests for purchase requisition are broken. As reported by sbi on the merge request: File "~/addons/purchase_requisition/test/cancel_purchase_requisition.yml", line 1, in - File "~/addons/purchase_requisition/purchase_requisition.py", line 105, in tender_cancel purchase_order_obj.action_cancel(cr, uid, purchase_ids, context=context) File "~/addons/purchase/purchase.py", line 584, in action_cancel _('First cancel all receptions related to this purchase order.')) except_osv: (u'Unable to cancel this purchase order.', u'First cancel all receptions related to this purchase order.') Since that was a backport of an OPW support branch, chances are that one of the current openobject-addons 7.0 or saas branches does not exhibit similar problem. That'll be the first focus of investigation. To manage notifications about this bug go to: https://bugs.launchpad.net/ocb-addons/+bug/1278078/+subscriptions -- Mailing list: https://launchpad.net/~openerp-community-reviewer Post to : openerp-community-reviewer@lists.launchpad.net Unsubscribe : https://launchpad.net/~openerp-community-reviewer More help : https://help.launchpad.net/ListHelp