Re: [Openerp-community-reviewer] [Merge] lp:~cedric-lebrouster/ocb-server/ocb-7.0-bug-1322191-db_maxconn into lp:ocb-server
Review: Approve code review, sometest without being able to exercise that code LGTM : the connection must be closed. But I cannot find by reading the code a case where this branch is executed (i.e. a logical path in which we get len(self._connections) = self._maxconn so I'm wondering if we are not improving dead code here. Do you have a scenario at hand? -- https://code.launchpad.net/~cedric-lebrouster/ocb-server/ocb-7.0-bug-1322191-db_maxconn/+merge/220666 Your team OpenERP Community Backports 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:~akretion-team/account-financial-tools/7-account-journal-sale-refund-link-cde into lp:account-financial-tools
Review: Needs Fixing code review Hi, Chaffique. Thanks for your contribution. I think it's the first you make. Let's hope this one is the first of a lot. In the MP, you put two modules, the one you refer in the MP description, and account_tax_update. Please remove this second one from the MP. About account_journal_sale_refund_link, you have to follow some conventions set to assure quality. Here is a link to the document used to build theses conventions: https://pad.odoo.com/p/community-review Regards. -- https://code.launchpad.net/~akretion-team/account-financial-tools/7-account-journal-sale-refund-link-cde/+merge/223022 Your team OpenERP Community Reviewer/Maintainer is subscribed to branch lp:account-financial-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:~akretion-team/account-financial-tools/7-account-journal-sale-refund-link-cde into lp:account-financial-tools
Hi, Pedro. I'm sorry, I did not pay attention, actually I had a second module that was not merged. That's why I cancel my MP to correct and propose again. Regards. -- https://code.launchpad.net/~akretion-team/account-financial-tools/7-account-journal-sale-refund-link-cde/+merge/223022 Your team OpenERP Community Reviewer/Maintainer is subscribed to branch lp:account-financial-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
[Openerp-community-reviewer] [Merge] lp:~akretion-team/account-financial-tools/7-account-journal-sale-refund-link-cde into lp:account-financial-tools
Chafique DELLI has proposed merging lp:~akretion-team/account-financial-tools/7-account-journal-sale-refund-link-cde into lp:account-financial-tools. Commit message: add module 'account_journal_sale_refund_link' Requested reviews: Akretion Team (akretion-team) For more details, see: https://code.launchpad.net/~akretion-team/account-financial-tools/7-account-journal-sale-refund-link-cde/+merge/223037 add module 'account_journal_sale_refund_link' who was in the branch 'lp:account-extra-addons' in the version 6.1 and i ported in the version 7.0 -- https://code.launchpad.net/~akretion-team/account-financial-tools/7-account-journal-sale-refund-link-cde/+merge/223037 Your team OpenERP Community Reviewer/Maintainer is subscribed to branch lp:account-financial-tools. === added directory 'account_journal_sale_refund_link' === added file 'account_journal_sale_refund_link/__init__.py' --- account_journal_sale_refund_link/__init__.py 1970-01-01 00:00:00 + +++ account_journal_sale_refund_link/__init__.py 2014-06-13 08:50:24 + @@ -0,0 +1,25 @@ +# -*- encoding: utf-8 -*- +# +# +#account_journal_sale_refund_link for OpenERP +#Copyright (C) 2011 Akretion Sébastien BEAU sebastien.b...@akretion.com +# 2014 Akretion Chafique DELLI chafique.de...@akretion.com +# +#This program is free software: you can redistribute it and/or modify +#it under the terms of the GNU Affero General Public License as +#published by the Free Software Foundation, either version 3 of the +#License, or (at your option) any later version. +# +#This program is distributed in the hope that it will be useful, +#but WITHOUT ANY WARRANTY; without even the implied warranty of +#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +#GNU Affero General Public License for more details. +# +#You should have received a copy of the GNU Affero General Public License +#along with this program. If not, see http://www.gnu.org/licenses/. +# +# + + +import account +import account_invoice_refund === added file 'account_journal_sale_refund_link/__openerp__.py' --- account_journal_sale_refund_link/__openerp__.py 1970-01-01 00:00:00 + +++ account_journal_sale_refund_link/__openerp__.py 2014-06-13 08:50:24 + @@ -0,0 +1,39 @@ +# -*- encoding: utf-8 -*- +# +# +#account_journal_sale_refund_link for OpenERP +#Copyright (C) 2011 Akretion Sébastien BEAU sebastien.b...@akretion.com +# 2014 Akretion Chafique DELLI chafique.de...@akretion.com +# +#This program is free software: you can redistribute it and/or modify +#it under the terms of the GNU Affero General Public License as +#published by the Free Software Foundation, either version 3 of the +#License, or (at your option) any later version. +# +#This program is distributed in the hope that it will be useful, +#but WITHOUT ANY WARRANTY; without even the implied warranty of +#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +#GNU Affero General Public License for more details. +# +#You should have received a copy of the GNU Affero General Public License +#along with this program. If not, see http://www.gnu.org/licenses/. +# +# + + +{ +'name': 'account_journal_sale_refund_link', +'version': '0.1', +'category': 'Generic Modules/Others', +'license': 'AGPL-3', +'description': empty, +'author': 'Akretion', +'website': 'http://www.akretion.com/', +'depends': ['account'], +'data': [ + 'account_view.xml', +], +'demo': [], +'installable': True, +'active': False, +} === added file 'account_journal_sale_refund_link/account.py' --- account_journal_sale_refund_link/account.py 1970-01-01 00:00:00 + +++ account_journal_sale_refund_link/account.py 2014-06-13 08:50:24 + @@ -0,0 +1,34 @@ +# -*- encoding: utf-8 -*- +# +# +#account_journal_sale_refund_link for OpenERP +#Copyright (C) 2011 Akretion Sébastien BEAU sebastien.b...@akretion.com +# 2014 Akretion Chafique DELLI chafique.de...@akretion.com +# +#This program is free software: you can redistribute it and/or modify +#it under the terms of the GNU Affero General Public License as +#published by the Free Software Foundation, either version 3 of the +#License, or (at your option) any later version. +# +#This program is distributed in the hope that it will be useful, +#but WITHOUT ANY WARRANTY; without even the implied warranty of +#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +#GNU
Re: [Openerp-community-reviewer] [Merge] lp:~akretion-team/account-financial-tools/7-account-journal-sale-refund-link-cde into lp:account-financial-tools
Review: Approve code review LGTM. Thanks. Regards. -- https://code.launchpad.net/~akretion-team/account-financial-tools/7-account-journal-sale-refund-link-cde/+merge/223037 Your team OpenERP Community Reviewer/Maintainer is subscribed to branch lp:account-financial-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:~cedric-lebrouster/ocb-server/ocb-7.0-bug-1322191-db_maxconn into lp:ocb-server
Thanks for review. What I understand by reading the code is that this function has 4 parts. First it removes closed or leaked connections - none of our business here Then it tries to re-use an iddle connection previously opened for the same database If no iddle connection is found for this database, and if db_maxconn is reached, it will free any other iddle connection, and here was the bug Finally, it will open a new connection So the bug needs to have several databases opened to occur. How to test : I check number of postgres connections on linux with the psql command: psql -c SELECT datid,datname,procpid,usesysid,usename,current_query FROM pg_stat_activity WHERE application_name!='psql'; postgres Set in config file db_maxconn = 4 (must be higher than max_cron_threads if I remember correct) Run openerp Login to a database You should see 3 or 4 postgres connections for your database. Now, without loging out, login to another database (loging out would free connections) You should now see more than 4 used databases. If not, click on a menu on the 2 databases with a low time interval. For whatever reason connections are correctly freed or their database switched sometimes, but I don't know why or where in the code. -- https://code.launchpad.net/~cedric-lebrouster/ocb-server/ocb-7.0-bug-1322191-db_maxconn/+merge/220666 Your team OpenERP Community Backports 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:~camptocamp/sale-wkfl/product_procurement_type into lp:sale-wkfl
Review: Needs Fixing code review Hello Romain and Alexandre, diff comments + some PEP8 remarks product_procurement_type/product.py:27:1: E302 expected 2 blank lines, found 1 product_procurement_type/product.py:34:1: E302 expected 2 blank lines, found 1 product_procurement_type/product.py:99:13: E123 closing bracket does not match indentation of opening bracket's line product_procurement_type/product.py:42:80: E501 line too long (95 79 characters) product_procurement_type_dropshipping/product.py:28:1: E302 expected 2 blank lines, found 0 product_procurement_type_dropshipping/product.py:33:1: E302 expected 2 blank lines, found 1 product_procurement_type_dropshipping/product.py:52:5: E303 too many blank lines (2) product_procurement_type_dropshipping/product.py:111:17: E123 closing bracket does not match indentation of opening bracket's line product_procurement_type_dropshipping/product.py:115:1: W391 blank line at end of file product_procurement_type_dropshipping/product.py:25:80: E501 line too long (90 79 characters) product_procurement_type_dropshipping/product.py:46:80: E501 line too long (116 79 characters) product_procurement_type_dropshipping/product.py:64:80: E501 line too long (80 79 characters) Diff comments: === added directory 'product_procurement_type' === added file 'product_procurement_type/__init__.py' --- product_procurement_type/__init__.py 1970-01-01 00:00:00 + +++ product_procurement_type/__init__.py 2014-06-10 15:36:28 + @@ -0,0 +1,22 @@ +# -*- coding: utf-8 -*- +## +# +#Author: Romain Deheele +#Copyright 2014 Camptocamp SA +# +#This program is free software: you can redistribute it and/or modify +#it under the terms of the GNU Affero General Public License as +#published by the Free Software Foundation, either version 3 of the +#License, or (at your option) any later version. +# +#This program is distributed in the hope that it will be useful, +#but WITHOUT ANY WARRANTY; without even the implied warranty of +#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +#GNU Affero General Public License for more details. +# +#You should have received a copy of the GNU Affero General Public License +#along with this program. If not, see http://www.gnu.org/licenses/. +# +## + +from . import product === added file 'product_procurement_type/__openerp__.py' --- product_procurement_type/__openerp__.py 1970-01-01 00:00:00 + +++ product_procurement_type/__openerp__.py 2014-06-10 15:36:28 + @@ -0,0 +1,52 @@ +# -*- coding: utf-8 -*- +## +# +#Author: Romain Deheele +#Copyright 2014 Camptocamp SA +# +#This program is free software: you can redistribute it and/or modify +#it under the terms of the GNU Affero General Public License as +#published by the Free Software Foundation, either version 3 of the +#License, or (at your option) any later version. +# +#This program is distributed in the hope that it will be useful, +#but WITHOUT ANY WARRANTY; without even the implied warranty of +#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +#GNU Affero General Public License for more details. +# +#You should have received a copy of the GNU Affero General Public License +#along with this program. If not, see http://www.gnu.org/licenses/. +# +## + +{ +name: Product Procurement Types, +version: 0.1, +author: Camptocamp, +license: AGPL-3, +category: Sales, +description: + +Add a procurement type selection on products. +Let create products as : + - On stock, buy + - On stock, produce + - On order, buy + - On order, produce + +Choose On stock, buy changes automatically +procurement method as make to stock and supply method as buy. +Choose On demand, produce changes automatically +procurement method as make to order and supply method as produce. + +, +website: http://camptocamp.com;, +depends: ['sale', +'procurement', +'mrp'], +data: ['product_view.xml'], +demo: [], +test: ['test/test_onchange_procurement_type.yml'], +active: False, +installable: True, +} === added file 'product_procurement_type/product.py' --- product_procurement_type/product.py 1970-01-01 00:00:00 + +++ product_procurement_type/product.py 2014-06-10 15:36:28 + @@ -0,0 +1,139 @@ +# -*- coding: utf-8 -*- +## +# +#Author: Romain Deheele +#Copyright 2014
Re: [Openerp-community-reviewer] [Merge] lp:~camptocamp/stock-logistic-flows/7.0-picking_dispatch_wave-according-defined-number-of-sales_rde into lp:stock-logistic-flows
Review: Needs Fixing Need fixing. Set has a better performance than list and it should avoid duplicate. Please see inline comment Diff comments: === added directory 'picking_dispatch_wave' === added file 'picking_dispatch_wave/__init__.py' --- picking_dispatch_wave/__init__.py 1970-01-01 00:00:00 + +++ picking_dispatch_wave/__init__.py 2014-05-12 15:35:14 + @@ -0,0 +1,22 @@ +# -*- coding: utf-8 -*- +## +# +#Author: Alexandre Fayolle, Romain Deheele +#Copyright 2014 Camptocamp SA +# +#This program is free software: you can redistribute it and/or modify +#it under the terms of the GNU Affero General Public License as +#published by the Free Software Foundation, either version 3 of the +#License, or (at your option) any later version. +# +#This program is distributed in the hope that it will be useful, +#but WITHOUT ANY WARRANTY; without even the implied warranty of +#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +#GNU Affero General Public License for more details. +# +#You should have received a copy of the GNU Affero General Public License +#along with this program. If not, see http://www.gnu.org/licenses/. +# +## + +from . import dispatch_wave # noqa === added file 'picking_dispatch_wave/__openerp__.py' --- picking_dispatch_wave/__openerp__.py 1970-01-01 00:00:00 + +++ picking_dispatch_wave/__openerp__.py 2014-05-12 15:35:14 + @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +## +# +#Author: Alexandre Fayolle, Romain Deheele +#Copyright 2014 Camptocamp SA +# +#This program is free software: you can redistribute it and/or modify +#it under the terms of the GNU Affero General Public License as +#published by the Free Software Foundation, either version 3 of the +#License, or (at your option) any later version. +# +#This program is distributed in the hope that it will be useful, +#but WITHOUT ANY WARRANTY; without even the implied warranty of +#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +#GNU Affero General Public License for more details. +# +#You should have received a copy of the GNU Affero General Public License +#along with this program. If not, see http://www.gnu.org/licenses/. +# +## + + +{ +name: Picking Dispatch Wave, +version: 0.1, +depends: ['picking_dispatch', 'sale_stock'], +author: Camptocamp, +'license': 'AGPL-3', +description: Allows to set a picking dispatch +including the number of pickings that you want to pick: + +* The picker sets a number n of pickings to do. + +* The wizard will select moves from n pickings with oldest min_date. + +* A picking dispatch is created with found moves + +It's sort of basic wave picking. +, +website: http://www.camptocamp.com;, +category: Warehouse Management, +demo: [], +data: ['dispatch_wave_view.xml'], +test: ['test/test_dispatch_wave.yml'], +installable: True, +} === added file 'picking_dispatch_wave/dispatch_wave.py' --- picking_dispatch_wave/dispatch_wave.py1970-01-01 00:00:00 + +++ picking_dispatch_wave/dispatch_wave.py2014-05-12 15:35:14 + @@ -0,0 +1,115 @@ +# -*- coding: utf-8 -*- +## +# +#Author: Alexandre Fayolle, Romain Deheele +#Copyright 2014 Camptocamp SA +# +#This program is free software: you can redistribute it and/or modify +#it under the terms of the GNU Affero General Public License as +#published by the Free Software Foundation, either version 3 of the +#License, or (at your option) any later version. +# +#This program is distributed in the hope that it will be useful, +#but WITHOUT ANY WARRANTY; without even the implied warranty of +#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +#GNU Affero General Public License for more details. +# +#You should have received a copy of the GNU Affero General Public License +#along with this program. If not, see http://www.gnu.org/licenses/. +# +# +import logging + +from openerp.osv import orm, fields +from openerp.tools.translate import _ +_logger = logging.getLogger(__name__) + + +class StockPickingDispatchWave(orm.TransientModel): +_name = stock.picking.dispatch.wave + +def _get_pickings_to_do(self, cr, uid, nb, context=None): +context = context or {} +move_obj = self.pool['stock.move'] +move_ids = [] +picking_ids
Re: [Openerp-community-reviewer] [Merge] lp:~cedric-lebrouster/ocb-server/ocb-7.0-bug-1322191-db_maxconn into lp:ocb-server
thanks for the precision. -- https://code.launchpad.net/~cedric-lebrouster/ocb-server/ocb-7.0-bug-1322191-db_maxconn/+merge/220666 Your team OpenERP Community Backports 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:~camptocamp/stock-logistic-flows/7.0-picking_dispatch_wave-according-defined-number-of-sales_rde into lp:stock-logistic-flows
https://wiki.python.org/moin/TimeComplexity -- https://code.launchpad.net/~camptocamp/stock-logistic-flows/7.0-picking_dispatch_wave-according-defined-number-of-sales_rde/+merge/214568 Your team Stock and Logistic Core Editors is subscribed to branch lp:stock-logistic-flows. -- 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:~akretion-team/server-env-tools/server-env-tools into lp:server-env-tools
Hi I am asking myself about adding an object storage.configuration and a field storing_configuration_id on the model ir.model.fields. The idea will to use a default storing configuration for every field (on file sytem for exemple) but after we will be able to customise on every field from the backend where where you want to store each binary/image fields (database, S3, ftp, SFTP, Filestore) Do you like the idea? (not so hard to implement) -- 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/sale-financial/7.0-port-sale_line_watcher into lp:sale-financial
Review: Approve I tend to agree with Pedro. But I would say, given that Yannick refactored several modules to use this interface and that it seems working. I would say, let's approve that 1st change and get the stuff working. Next, if somebody finds it useful to kill that module and refactor dependent modules in v8 and if that stays simple I would approve such new change. But meanwhile, I approve this change because it's already an improvement and it's there. -- https://code.launchpad.net/~camptocamp/sale-financial/7.0-port-sale_line_watcher/+merge/214058 Your team Sale Core Editors is subscribed to branch lp:sale-financial. -- 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/sale-financial/7.0-port-sale_floor_price into lp:sale-financial
Review: Approve It's a pragmatic approval for now because it's already a working improvement. See https://code.launchpad.net/~camptocamp/sale-financial/7.0-port-sale_line_watcher/+merge/214058/comments/534749 -- https://code.launchpad.net/~camptocamp/sale-financial/7.0-port-sale_floor_price/+merge/214059 Your team Sale Core Editors is subscribed to branch lp:sale-financial. -- 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:~camptocamp/account-financial-report/7.0-fix-1319109 into lp:account-financial-report
Yannick Vaucher @ Camptocamp has proposed merging lp:~camptocamp/account-financial-report/7.0-fix-1319109 into lp:account-financial-report. Requested reviews: Account Report Core Editors (account-report-core-editor) For more details, see: https://code.launchpad.net/~camptocamp/account-financial-report/7.0-fix-1319109/+merge/223058 Adapt account_financial_report_webkit to fixes in addons https://github.com/odoo/odoo/pull/55 https://github.com/odoo/odoo/pull/56 Plus few improvement following pep8 to remove useless variable and import -- https://code.launchpad.net/~camptocamp/account-financial-report/7.0-fix-1319109/+merge/223058 Your team Account Report Core Editors is requested to review the proposed merge of lp:~camptocamp/account-financial-report/7.0-fix-1319109 into lp:account-financial-report. === modified file 'account_financial_report_webkit/report/webkit_parser_header_fix.py' --- account_financial_report_webkit/report/webkit_parser_header_fix.py 2014-03-18 14:55:32 + +++ account_financial_report_webkit/report/webkit_parser_header_fix.py 2014-06-13 12:07:01 + @@ -30,8 +30,8 @@ import os import subprocess import tempfile -import time import logging +from functools import partial from mako import exceptions @@ -48,11 +48,12 @@ # Class used only as a workaround to bug: # http://code.google.com/p/wkhtmltopdf/issues/detail?id=656 -# html headers and footers do not work on big files (hundreds of pages) so we replace them by -# text headers and footers passed as arguments to wkhtmltopdf +# html headers and footers do not work on big files (hundreds of pages) so we +# replace them by text headers and footers passed as arguments to wkhtmltopdf # this class has to be removed once the bug is fixed -# in your report class, to print headers and footers as text, you have to add them in the localcontext with a key 'additional_args' +# in your report class, to print headers and footers as text, you have to add +# them in the localcontext with a key 'additional_args' # for instance: #header_report_name = _('PARTNER LEDGER') #footer_date_time = self.formatLang(str(datetime.today()), date_time=True) @@ -75,23 +76,25 @@ from mako.template import Template from mako.lookup import TemplateLookup + def mako_template(text): Build a Mako template. This template uses UTF-8 encoding -tmp_lookup = TemplateLookup() #we need it in order to allow inclusion and inheritance +tmp_lookup = TemplateLookup() # we need it in order to allow inclusion and inheritance return Template(text, input_encoding='utf-8', output_encoding='utf-8', lookup=tmp_lookup) class HeaderFooterTextWebKitParser(webkit_report.WebKitParser): -def generate_pdf(self, comm_path, report_xml, header, footer, html_list, webkit_header=False): +def generate_pdf(self, comm_path, report_xml, header, footer, html_list, + webkit_header=False, parser_instance=False): Call webkit in order to generate pdf if not webkit_header: webkit_header = report_xml.webkit_header -tmp_dir = tempfile.gettempdir() -out_filename = tempfile.mktemp(suffix=.pdf, prefix=webkit.tmp.) +fd, out_filename = tempfile.mkstemp(suffix=.pdf, +prefix=webkit.tmp.) file_to_del = [out_filename] if comm_path: command = [comm_path] @@ -115,16 +118,16 @@ if webkit_header.format: command.extend(['--page-size', str(webkit_header.format).replace(',', '.')]) -if self.parser_instance.localcontext.get('additional_args', False): -for arg in self.parser_instance.localcontext['additional_args']: +if parser_instance.localcontext.get('additional_args', False): +for arg in parser_instance.localcontext['additional_args']: command.extend(arg) count = 0 for html in html_list: -html_file = file(os.path.join(tmp_dir, str(time.time()) + str(count) +'.body.html'), 'w') -count += 1 -html_file.write(html) -html_file.close() +with tempfile.NamedTemporaryFile(suffix=%d.body.html % count, + delete=False) as html_file: +count += 1 +html_file.write(self._sanitize_html(html)) file_to_del.append(html_file.name) command.append(html_file.name) command.append(out_filename) @@ -132,8 +135,8 @@ file_to_del.append(stderr_path) try: status = subprocess.call(command, stderr=stderr_fd) -os.close(stderr_fd) # ensure flush before reading -stderr_fd = None # avoid closing again in finally block +os.close(stderr_fd) # ensure flush before reading +stderr_fd = None # avoid closing again in finally block fobj = open(stderr_path, 'r')
Re: [Openerp-community-reviewer] [Merge] lp:~camptocamp/account-financial-tools/add-manual-line-and-fees-nbi into lp:account-financial-tools
Review: Needs Fixing code review Hello, Just little things as: - I see deprecated attribute type on form views (l.869, 906) - l.2221: s/Euro policy level/Usd policy level - l.1310, 1311: '==' instead of '=' Otherwise, few little typos: - l.1709: s/writen/written - l.1709: s/fields/field - l.2199: s/Initialaize/Initialize - I would add commas on l.280, 290, 1392 - I would remove double spaces on l.699, 725 thanks for these new features, Romain -- https://code.launchpad.net/~camptocamp/account-financial-tools/add-manual-line-and-fees-nbi/+merge/218584 Your team OpenERP Community Reviewer/Maintainer is subscribed to branch lp:account-financial-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/carriers-deliveries/7.0-threaded-dispatch-label-generation into lp:carriers-deliveries
fixed except: - except Exception: -- https://code.launchpad.net/~camptocamp/carriers-deliveries/7.0-threaded-dispatch-label-generation/+merge/215184 Your team Stock and Logistic Core Editors is requested to review the proposed merge of lp:~camptocamp/carriers-deliveries/7.0-threaded-dispatch-label-generation into lp:carriers-deliveries. -- 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/stock-logistic-flows/7.0-picking_dispatch_wave-according-defined-number-of-sales_rde into lp:stock-logistic-flows
Thanks Nicolas, I made changes accordingly. I add a condition : only assigned pickings are selected. -- https://code.launchpad.net/~camptocamp/stock-logistic-flows/7.0-picking_dispatch_wave-according-defined-number-of-sales_rde/+merge/214568 Your team Stock and Logistic Core Editors is subscribed to branch lp:stock-logistic-flows. -- 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:~pedro.baeza/ocb-addons/6.1-product-imp-units into lp:ocb-addons/6.1
Pedro Manuel Baeza has proposed merging lp:~pedro.baeza/ocb-addons/6.1-product-imp-units into lp:ocb-addons/6.1. Requested reviews: OpenERP Community Backports (ocb) For more details, see: https://code.launchpad.net/~pedro.baeza/ocb-addons/6.1-product-imp-units/+merge/223111 [IMP] product: Added a unit category (volume) and two units (dozen and liter), like in 7.0. There is no bug report attached and no MP for official because this change is already merged on 7.0 and 6.1 is no supported. -- https://code.launchpad.net/~pedro.baeza/ocb-addons/6.1-product-imp-units/+merge/223111 Your team OpenERP Community Backports is requested to review the proposed merge of lp:~pedro.baeza/ocb-addons/6.1-product-imp-units into lp:ocb-addons/6.1. === modified file 'product/product_data.xml' --- product/product_data.xml 2011-12-30 12:31:00 + +++ product/product_data.xml 2014-06-13 18:14:51 + @@ -20,7 +20,9 @@ record id=uom_categ_length model=product.uom.categ field name=nameLength / Distance/field /record - +record id=product_uom_categ_vol model=product.uom.categ +field name=nameVolume/field +/record !-- Resource: product.uom @@ -31,6 +33,12 @@ field name=factor eval=1.0/ field name=rounding eval=1.0/ /record + record id=product_uom_dozen model=product.uom +field name=category_id ref=product.product_uom_categ_unit/ +field name=nameDozen(s)/field +field name=factor_inv eval=12/ +field name=uom_typebigger/field +/record record id=product_uom_kgm model=product.uom field name=category_id ref=product_uom_categ_kgm/ field name=namekg/field @@ -78,7 +86,11 @@ field name=factor eval=100/ field name=uom_typesmaller/field /record - +record id=product_uom_litre model=product.uom +field name=nameLiter(s)/field +field name=category_id ref=product_uom_categ_vol/ +field name=factor1.0/field +/record !-- ... to here, it should be in product_demo but we cant just move it -- 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:~aristobulo/web-addons/web_fields_masks into lp:web-addons
Review: Approve code and test We have been testing it and is working flawlessly... -- https://code.launchpad.net/~aristobulo/web-addons/web_fields_masks/+merge/219084 Your team Web-Addons Core Editors is subscribed to branch lp:web-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
[Openerp-community-reviewer] [Merge] lp:~dr.clearcorp/partner-contact-management/7.0-review_partner_merge into lp:partner-contact-management
Diana Rodríguez Martínez has proposed merging lp:~dr.clearcorp/partner-contact-management/7.0-review_partner_merge into lp:partner-contact-management. Requested reviews: Partner and Contact Core Editors (partner-contact-core-editors) Related bugs: Bug #1329972 in Partner and Contact Management: Base partner merge doesn't include reference as a criteria for merging https://bugs.launchpad.net/partner-contact-management/+bug/1329972 For more details, see: https://code.launchpad.net/~dr.clearcorp/partner-contact-management/7.0-review_partner_merge/+merge/223137 [FIX] Fix base_partner_merge report. Add reference as a criteria for merge contacts -- https://code.launchpad.net/~dr.clearcorp/partner-contact-management/7.0-review_partner_merge/+merge/223137 Your team Partner and Contact Core Editors is requested to review the proposed merge of lp:~dr.clearcorp/partner-contact-management/7.0-review_partner_merge into lp:partner-contact-management. === modified file 'base_partner_merge/base_partner_merge.py' --- base_partner_merge/base_partner_merge.py 2014-02-06 13:36:20 + +++ base_partner_merge/base_partner_merge.py 2014-06-13 23:01:42 + @@ -90,6 +90,7 @@ # Group by 'group_by_email': fields.boolean('Email'), 'group_by_name': fields.boolean('Name'), +'group_by_ref': fields.boolean('Reference'), 'group_by_is_company': fields.boolean('Is Company'), 'group_by_vat': fields.boolean('VAT'), 'group_by_parent_id': fields.boolean('Parent Company'), @@ -469,7 +470,7 @@ filters = [] for field in fields: -if field in ['email', 'name']: +if field in ['email', 'name', 'ref']: filters.append((field, 'IS NOT', 'NULL')) criteria = ' AND '.join('%s %s %s' % (field, operator, value) === modified file 'base_partner_merge/base_partner_merge_view.xml' --- base_partner_merge/base_partner_merge_view.xml 2014-02-25 14:53:41 + +++ base_partner_merge/base_partner_merge_view.xml 2014-06-13 23:01:42 + @@ -76,6 +76,7 @@ attrs={'invisible': [('state', 'not in', ('option',))]} field name='group_by_email' / field name='group_by_name' / +field name='group_by_ref' / field name='group_by_is_company' / field name='group_by_vat' / field name='group_by_parent_id' / === added directory 'base_partner_merge/i18n' === added file 'base_partner_merge/i18n/base_partner_merge.pot' --- base_partner_merge/i18n/base_partner_merge.pot 1970-01-01 00:00:00 + +++ base_partner_merge/i18n/base_partner_merge.pot 2014-06-13 23:01:42 + @@ -0,0 +1,308 @@ +# Translation of OpenERP Server. +# This file contains the translation of the following modules: +# * base_partner_merge +# +msgid +msgstr +Project-Id-Version: OpenERP Server 7.0\n +Report-Msgid-Bugs-To: \n +POT-Creation-Date: 2014-06-13 22:04+\n +PO-Revision-Date: 2014-06-13 22:04+\n +Last-Translator: \n +Language-Team: \n +MIME-Version: 1.0\n +Content-Type: text/plain; charset=UTF-8\n +Content-Transfer-Encoding: \n +Plural-Forms: \n + +#. module: base_partner_merge +#: code:addons/base_partner_merge/base_partner_merge.py:384 +#, python-format +msgid Only the destination contact may be linked to existing Journal Items. Please ask the Administrator if you need to merge several contacts linked to existing Journal Items. +msgstr + +#. module: base_partner_merge +#: view:base.partner.merge.automatic.wizard:0 +msgid Partners +msgstr + +#. module: base_partner_merge +#: view:base.partner.merge.automatic.wizard:0 +msgid Exclude contacts having +msgstr + +#. module: base_partner_merge +#: view:base.partner.merge.automatic.wizard:0 +msgid Deduplicate the other Contacts +msgstr + +#. module: base_partner_merge +#: field:base.partner.merge.automatic.wizard,partner_ids:0 +msgid Contacts +msgstr + +#. module: base_partner_merge +#: field:base.partner.merge.automatic.wizard,number_group:0 +msgid Group of Contacts +msgstr + +#. module: base_partner_merge +#: field:base.partner.merge.line,wizard_id:0 +msgid Wizard +msgstr + +#. module: base_partner_merge +#: model:ir.model,name:base_partner_merge.model_base_partner_merge_automatic_wizard +msgid base.partner.merge.automatic.wizard +msgstr + +#. module: base_partner_merge +#: code:addons/base_partner_merge/base_partner_merge.py:347 +#, python-format +msgid For safety reasons, you cannot merge more than 3 contacts together. You can re-open the wizard several times if needed. +msgstr + +#. module: base_partner_merge +#: field:base.partner.merge.automatic.wizard,state:0 +msgid State +msgstr + +#. module: base_partner_merge +#: view:base.partner.merge.automatic.wizard:0 +msgid Skip these contacts +msgstr + +#. module: base_partner_merge +#: code:addons/base_partner_merge/base_partner_merge.py:357 +#,