accounting regression: future aged partner balance is broken

Bug #421907 reported by Raphaël Valyi - http://www.akretion.com
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
Fix Released
Undecided
Jay Vora (Serpent Consulting Services)

Bug Description

Hello

in 5.0 head revision or v5.0.4:
install a new DB with mrp profile + demo data + French chart of account.
Now go in Financial Management > Reporting > Partner Accounts > Aged Partner Balance
Let the default values in the wizard except the "analysis direction": choose "future"
Try to print the balance, it will crash with the following stack trace:

2009-08-31 09:36:18,135] ERROR:web-services:[01]:
[2009-08-31 09:36:18,135] ERROR:web-services:[02]: Environment Information :
[2009-08-31 09:36:18,135] ERROR:web-services:[03]: System : Linux-2.6.28-15-generic-x86_64-with-Ubuntu-9.04-jaunty
[2009-08-31 09:36:18,136] ERROR:web-services:[04]: OS Name : posix
[2009-08-31 09:36:18,136] ERROR:web-services:[05]: Distributor ID: Ubuntu
[2009-08-31 09:36:18,136] ERROR:web-services:[06]: Description: Ubuntu 9.04
[2009-08-31 09:36:18,136] ERROR:web-services:[07]: Release: 9.04
[2009-08-31 09:36:18,136] ERROR:web-services:[08]: Codename: jaunty
[2009-08-31 09:36:18,136] ERROR:web-services:[09]: Operating System Release : 2.6.28-15-generic
[2009-08-31 09:36:18,136] ERROR:web-services:[10]: Operating System Version : #49-Ubuntu SMP Tue Aug 18 19:25:34 UTC 2009
[2009-08-31 09:36:18,137] ERROR:web-services:[11]: Operating System Architecture : 64bit
[2009-08-31 09:36:18,137] ERROR:web-services:[12]: Operating System Locale : en_US.UTF8
[2009-08-31 09:36:18,137] ERROR:web-services:[13]: Python Version : 2.6.2
[2009-08-31 09:36:18,137] ERROR:web-services:[14]: OpenERP-Server Version : 5.0.5-bzr
[2009-08-31 09:36:18,137] ERROR:web-services:[15]: Last revision No. & ID : 1851 <email address hidden>
[2009-08-31 09:36:18,137] ERROR:web-services:[16]: Exception: current transaction is aborted, commands ignored until end of transaction block
[2009-08-31 09:36:18,137] ERROR:web-services:[17]:
[2009-08-31 09:36:18,138] ERROR:web-services:[18]: Traceback (most recent call last):
[2009-08-31 09:36:18,138] ERROR:web-services:[19]: File "/home/rvalyi/DEV/openerp5.0/server/bin/service/web_services.py", line 687, in go
[2009-08-31 09:36:18,138] ERROR:web-services:[20]: (result, format) = obj.create(cr, uid, ids, datas, context)
[2009-08-31 09:36:18,138] ERROR:web-services:[21]: File "/home/rvalyi/DEV/openerp5.0/server/bin/report/report_sxw.py", line 364, in create
[2009-08-31 09:36:18,138] ERROR:web-services:[22]: return fnct(cr, uid, ids, data, report_xml, context)
[2009-08-31 09:36:18,138] ERROR:web-services:[23]: File "/home/rvalyi/DEV/openerp5.0/server/bin/report/report_sxw.py", line 421, in create_source_pdf
[2009-08-31 09:36:18,138] ERROR:web-services:[24]: return self.create_single_pdf(cr, uid, ids, data, report_xml, context)
[2009-08-31 09:36:18,139] ERROR:web-services:[25]: File "/home/rvalyi/DEV/openerp5.0/server/bin/report/report_sxw.py", line 439, in create_single_pdf
[2009-08-31 09:36:18,139] ERROR:web-services:[26]: pdf = create_doc(etree.tostring(processed_rml),rml_parser.localcontext,logo,title.encode('utf8'))
[2009-08-31 09:36:18,139] ERROR:web-services:[27]: File "/home/rvalyi/DEV/openerp5.0/server/bin/report/interface.py", line 199, in create_pdf
[2009-08-31 09:36:18,139] ERROR:web-services:[28]: obj.render()
[2009-08-31 09:36:18,139] ERROR:web-services:[29]: File "/home/rvalyi/DEV/openerp5.0/server/bin/report/render/render.py", line 50, in render
[2009-08-31 09:36:18,139] ERROR:web-services:[30]: result = self._render()
[2009-08-31 09:36:18,139] ERROR:web-services:[31]: File "/home/rvalyi/DEV/openerp5.0/server/bin/report/render/rml.py", line 41, in _render
[2009-08-31 09:36:18,139] ERROR:web-services:[32]: return rml2pdf.parseNode(self.rml, self.localcontext, images=self.bin_datas, path=self.path,title=self.title)
[2009-08-31 09:36:18,140] ERROR:web-services:[33]: File "/home/rvalyi/DEV/openerp5.0/server/bin/report/render/rml2pdf/trml2pdf.py", line 780, in parseNode
[2009-08-31 09:36:18,140] ERROR:web-services:[34]: r.render(fp)
[2009-08-31 09:36:18,140] ERROR:web-services:[35]: File "/home/rvalyi/DEV/openerp5.0/server/bin/report/render/rml2pdf/trml2pdf.py", line 195, in render
[2009-08-31 09:36:18,140] ERROR:web-services:[36]: pt_obj.render(el)
[2009-08-31 09:36:18,140] ERROR:web-services:[37]: File "/home/rvalyi/DEV/openerp5.0/server/bin/report/render/rml2pdf/trml2pdf.py", line 770, in render
[2009-08-31 09:36:18,140] ERROR:web-services:[38]: fis += r.render(node_story)
[2009-08-31 09:36:18,140] ERROR:web-services:[39]: File "/home/rvalyi/DEV/openerp5.0/server/bin/report/render/rml2pdf/trml2pdf.py", line 700, in render
[2009-08-31 09:36:18,140] ERROR:web-services:[40]: return process_story(node_story)
[2009-08-31 09:36:18,141] ERROR:web-services:[41]: File "/home/rvalyi/DEV/openerp5.0/server/bin/report/render/rml2pdf/trml2pdf.py", line 693, in process_story
[2009-08-31 09:36:18,141] ERROR:web-services:[42]: flow = self._flowable(node)
[2009-08-31 09:36:18,141] ERROR:web-services:[43]: File "/home/rvalyi/DEV/openerp5.0/server/bin/report/render/rml2pdf/trml2pdf.py", line 607, in _flowable
[2009-08-31 09:36:18,141] ERROR:web-services:[44]: return self._table(node)
[2009-08-31 09:36:18,141] ERROR:web-services:[45]: File "/home/rvalyi/DEV/openerp5.0/server/bin/report/render/rml2pdf/trml2pdf.py", line 474, in _table
[2009-08-31 09:36:18,141] ERROR:web-services:[46]: for tr in childs:
[2009-08-31 09:36:18,141] ERROR:web-services:[47]: File "/home/rvalyi/DEV/openerp5.0/server/bin/report/render/rml2pdf/utils.py", line 59, in _child_get
[2009-08-31 09:36:18,141] ERROR:web-services:[48]: for ctx in eval(n.get('rml_loop'),{}, self.localcontext):
[2009-08-31 09:36:18,142] ERROR:web-services:[49]: File "<string>", line 1, in <module>
[2009-08-31 09:36:18,142] ERROR:web-services:[50]: File "/home/rvalyi/DEV/openerp5.0/addons/account/report/aged_trial_balance.py", line 70, in _get_lines
[2009-08-31 09:36:18,142] ERROR:web-services:[51]: "ORDER BY res_partner.name", (form['date1'],form['company_id']))
[2009-08-31 09:36:18,142] ERROR:web-services:[52]: File "/home/rvalyi/DEV/openerp5.0/server/bin/sql_db.py", line 76, in wrapper
[2009-08-31 09:36:18,142] ERROR:web-services:[53]: return f(self, *args, **kwargs)
[2009-08-31 09:36:18,142] ERROR:web-services:[54]: File "/home/rvalyi/DEV/openerp5.0/server/bin/sql_db.py", line 120, in execute
[2009-08-31 09:36:18,142] ERROR:web-services:[55]: res = self._obj.execute(query, params)
[2009-08-31 09:36:18,142] ERROR:web-services:[56]: InternalError: current transaction is aborted, commands ignored until end of transaction block
/home/rvalyi/DEV/openerp5.0/server/bin/service/web_services.py:655: DeprecationWarning: BaseException.message has been deprecated as of Python 2.6

This is a regression. In 5.0.1 for instance this was working.

I think you could test all reports for all demo data in automatically in the base_module_quality module. This would have told when doing such a regression. Hope this helps.

Related branches

Changed in openobject-addons:
status: New → Confirmed
Revision history for this message
Jay Vora (Serpent Consulting Services) (jayvora) wrote :

Would you please apply this patch and revert back to us quickly?

Thanks.

Revision history for this message
Jay Vora (Serpent Consulting Services) (jayvora) wrote :
Changed in openobject-addons:
assignee: nobody → Jay (Open ERP) (jvo-openerp)
status: Confirmed → In Progress
Revision history for this message
Raphaël Valyi - http://www.akretion.com (rvalyi) wrote :

Hello Jay, from my tests this is fixed indeed. So far the future balance looks correct; you rocks!
BTW, I'm making payments to Tiny that Tuesday so that Akretion becomes the first Brazilian Tiny partner; hopefully Tiny tireless efforts will finally pay at large scale...

Revision history for this message
Jay Vora (Serpent Consulting Services) (jayvora) wrote :

Hello Raphael,
Honored to have you here.
Fixed by revision 2369 <email address hidden>

Thank you.

Changed in openobject-addons:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.