← Back to team overview

openerp-community-reviewer team mailing list archive

[Merge] lp:~camptocamp/account-financial-tools/6.1-fix-1276998 into lp:account-financial-tools/6.1

 

Yannick Vaucher @ Camptocamp has proposed merging lp:~camptocamp/account-financial-tools/6.1-fix-1276998 into lp:account-financial-tools/6.1.

Requested reviews:
  Account Core Editors (account-core-editors)
Related bugs:
  Bug #1276998 in Account - Financial Tools 6.1: "commit 107 in account-financial-tools/6.1 broke currency_rate_update: missing "import logging" in currency_rate_update.py"
  https://bugs.launchpad.net/account-financial-tools/6.1/+bug/1276998

For more details, see:
https://code.launchpad.net/~camptocamp/account-financial-tools/6.1-fix-1276998/+merge/205121
-- 
https://code.launchpad.net/~camptocamp/account-financial-tools/6.1-fix-1276998/+merge/205121
Your team Account Core Editors is requested to review the proposed merge of lp:~camptocamp/account-financial-tools/6.1-fix-1276998 into lp:account-financial-tools/6.1.
=== modified file 'currency_rate_update/currency_rate_update.py'
--- currency_rate_update/currency_rate_update.py	2013-09-17 18:12:30 +0000
+++ currency_rate_update/currency_rate_update.py	2014-02-06 10:58:58 +0000
@@ -46,6 +46,7 @@
 import time
 from datetime import datetime, timedelta
 import netsvc
+import logging
 from tools.translate import _
 
 class Currency_rate_update_service(osv.osv):
@@ -189,13 +190,13 @@
             # we fetch the main currency. The main rate should be set at  1.00
             main_curr = comp.currency_id.name
             for service in comp.services_to_use :
-                logger.debug("comp.services_to_use = %s" % (comp.services_to_use))
+                self.logger.debug("comp.services_to_use = %s" % (comp.services_to_use))
                 note = service.note or ''
                 try :
                     # # we initalize the class that will handle the request
                     # # and return a dict of rate
                     getter = factory.register(service.service)
-                    logger.debug("getter = %s" % (type(getter)))
+                    self.logger.debug("getter = %s" % (type(getter)))
                     curr_to_fetch = map(lambda x : x.name, service.currency_to_update)
                     res, log_info = getter.get_updated_currency(curr_to_fetch, main_curr, service.max_delta_days)
                     rate_name = time.strftime('%Y-%m-%d')


Follow ups