AttributeError: 'NoneType' object has no attribute 'strftime'

Bug #498442 reported by jc.considine
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenERP Thailand
Invalid
Undecided
Unassigned

Bug Description

Hi,
I've been trying to install the ac_account_thai module after downloading from launchpad, and get an AttributeError with the following backtrace:

Environment Information :
System : Linux-2.6.27.39-0.2-pae-i686-with-SuSE-11.1-i586
OS Name : posix
LSB Version: core-2.0-noarch:core-3.2-noarch:core-2.0-ia32:core-3.2-ia32:desktop-3.2-ia32:desktop-3.2-noarch:graphics-2.0-ia32:graphics-2.0-noarch:graphics-3.2-ia32:graphics-3.2-noarch
Distributor ID: SUSE LINUX
Description: openSUSE 11.1 (i586)
Release: 11.1
Codename: n/a
Operating System Release : 2.6.27.39-0.2-pae
Operating System Version : #1 SMP 2009-11-23 12:57:38 +0100
Operating System Architecture : 32bit
Operating System Locale : en_AU.UTF8
Python Version : 2.6.0
OpenERP-Client Version : 5.0.6
Last revision No. & ID :1015 <email address hidden>
Traceback (most recent call last):
  File "/usr/local/lib/python2.6/site-packages/openerp/server/bin/netsvc.py", line 244, in dispatch
    result = LocalService(service_name)(method, *params)
  File "/usr/local/lib/python2.6/site-packages/openerp/server/bin/netsvc.py", line 73, in __call__
    return getattr(self, method)(*params)
  File "/usr/local/lib/python2.6/site-packages/openerp/server/bin/service/web_services.py", line 635, in execute
    return self._execute(db, uid, wiz_id, datas, action, context)
  File "/usr/local/lib/python2.6/site-packages/openerp/server/bin/service/web_services.py", line 615, in _execute
    return wiz.execute(db, uid, self.wiz_datas[wiz_id], action, context)
  File "/usr/local/lib/python2.6/site-packages/openerp/server/bin/wizard/__init__.py", line 177, in execute
    res = self.execute_cr(cr, uid, data, state, context)
  File "/usr/local/lib/python2.6/site-packages/openerp/server/bin/wizard/__init__.py", line 73, in execute_cr
    action_res = action(self, cr, uid, data, context)
  File "/usr/local/lib/python2.6/site-packages/openerp/addons/base/module/wizard/wizard_module_upgrade.py", line 92, in _upgrade_module
    db, pool = pooler.restart_pool(cr.dbname, update_module=True)
  File "/usr/local/lib/python2.6/site-packages/openerp/server/bin/pooler.py", line 62, in restart_pool
    return get_db_and_pool(db_name, force_demo, status, update_module=update_module)
  File "/usr/local/lib/python2.6/site-packages/openerp/server/bin/pooler.py", line 40, in get_db_and_pool
    addons.load_modules(db, force_demo, status, update_module)
  File "/usr/local/lib/python2.6/site-packages/openerp/server/bin/addons/__init__.py", line 728, in load_modules
    r = load_module_graph(cr, graph, status, report=report)
  File "/usr/local/lib/python2.6/site-packages/openerp/server/bin/addons/__init__.py", line 581, in load_module_graph
    init_module_objects(cr, package.name, modules)
  File "/usr/local/lib/python2.6/site-packages/openerp/server/bin/addons/__init__.py", line 366, in init_module_objects
    result = obj._auto_init(cr, {'module': module_name})
  File "/usr/local/lib/python2.6/site-packages/openerp/server/bin/osv/orm.py", line 1889, in _auto_init
    default = self._defaults[k](self, cr, 1, {})
  File "/usr/local/lib/python2.6/site-packages/openerp/addons/ac_account_thai/account_thai.py", line 530, in <lambda>
    "date": lambda *a: time.strftime("%Y-%m-%d"),
AttributeError: 'NoneType' object has no attribute 'strftime'

Revision history for this message
Kanit (kk-idin9) wrote :

Dear all,
    I also get same error and I try to find the solution then I found
that it may because of the "DEMO DATA" that you check during creating
the new Database
I don't know why maybe because of default value and parameter is not
suit for the structure, so you can try to uncheck that box and try to
install it again
For me it work !!
Hope that if other issues occur to me, it will be somebody who give me a
hand.
Cheers,
Kanit - IDIN9

Changed in openerp-thai:
status: New → Invalid
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.