Skip to Content
Odoo Menú
  • Registra entrada
  • Prova-ho gratis
  • Aplicacions
    Finances
    • Comptabilitat
    • Facturació
    • Despeses
    • Full de càlcul (IA)
    • Documents
    • Signatura
    Vendes
    • CRM
    • Vendes
    • Punt de venda per a botigues
    • Punt de venda per a restaurants
    • Subscripcions
    • Lloguer
    Imatges de llocs web
    • Creació de llocs web
    • Comerç electrònic
    • Blog
    • Fòrum
    • Xat en directe
    • Aprenentatge en línia
    Cadena de subministrament
    • Inventari
    • Fabricació
    • PLM
    • Compres
    • Manteniment
    • Qualitat
    Recursos humans
    • Empleats
    • Reclutament
    • Absències
    • Avaluacions
    • Recomanacions
    • Flota
    Màrqueting
    • Màrqueting Social
    • Màrqueting per correu electrònic
    • Màrqueting per SMS
    • Esdeveniments
    • Automatització del màrqueting
    • Enquestes
    Serveis
    • Projectes
    • Fulls d'hores
    • Servei de camp
    • Suport
    • Planificació
    • Cites
    Productivitat
    • Converses
    • Validacions
    • IoT
    • VoIP
    • Coneixements
    • WhatsApp
    Aplicacions de tercers Odoo Studio Plataforma d'Odoo al núvol
  • Sectors
    Comerç al detall
    • Llibreria
    • Botiga de roba
    • Botiga de mobles
    • Botiga d'ultramarins
    • Ferreteria
    • Botiga de joguines
    Food & Hospitality
    • Bar i pub
    • Restaurant
    • Menjar ràpid
    • Guest House
    • Distribuïdor de begudes
    • Hotel
    Immobiliari
    • Agència immobiliària
    • Estudi d'arquitectura
    • Construcció
    • Gestió immobiliària
    • Jardineria
    • Associació de propietaris de béns immobles
    Consultoria
    • Empresa comptable
    • Partner d'Odoo
    • Agència de màrqueting
    • Bufet d'advocats
    • Captació de talent
    • Auditoria i certificació
    Fabricació
    • Textile
    • Metal
    • Mobles
    • Menjar
    • Brewery
    • Regals corporatius
    Salut i fitness
    • Club d'esport
    • Òptica
    • Centre de fitness
    • Especialistes en benestar
    • Farmàcia
    • Perruqueria
    Trades
    • Servei de manteniment
    • Hardware i suport informàtic
    • Sistemes d'energia solar
    • Shoe Maker
    • Serveis de neteja
    • Instal·lacions HVAC
    Altres
    • Nonprofit Organization
    • Agència del medi ambient
    • Lloguer de panells publicitaris
    • Fotografia
    • Lloguer de bicicletes
    • Distribuïdors de programari
    Browse all Industries
  • Comunitat
    Aprèn
    • Tutorials
    • Documentació
    • Certificacions
    • Formació
    • Blog
    • Pòdcast
    Potenciar l'educació
    • Programa educatiu
    • Scale-Up! El joc empresarial
    • Visita Odoo
    Obtindre el programari
    • Descarregar
    • Comparar edicions
    • Novetats de les versions
    Col·laborar
    • GitHub
    • Fòrum
    • Esdeveniments
    • Traduccions
    • Converteix-te en partner
    • Services for Partners
    • Registra la teva empresa comptable
    Obtindre els serveis
    • Troba un partner
    • Troba un comptable
    • Contacta amb un expert
    • Serveis d'implementació
    • Referències del client
    • Suport
    • Actualitzacions
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    Programar una demo
  • Preus
  • Ajuda

Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:

  • CRM
  • e-Commerce
  • Comptabilitat
  • Inventari
  • PoS
  • Projectes
  • MRP
All apps
You need to be registered to interact with the community.
All Posts People Badges
Etiquetes (View all)
odoo accounting v14 pos v15
About this forum
You need to be registered to interact with the community.
All Posts People Badges
Etiquetes (View all)
odoo accounting v14 pos v15
About this forum
Ajuda

Deleting COA then install inventory causing error

Subscriure's

Get notified when there's activity on this post

This question has been flagged
InventoryAccountingCOA
2 Respostes
2326 Vistes
Avatar
Aryono

Hello Odooers,


When I tried to install Inventory on sh, it fail and error occurs.

After several trial and error on my local build, I found out the cause of that error: delete unused COA's.

I confirmed that on clean build and new database. here are the steps:

1. create new database (v17)

2. install accounting

3. delete all but required COA (I know its required, by the popup when I try to delete it)

4. install inventory/upgrading account


My questions are: 

1. how to delete unused COA's safely?

2. did COA's should not be deleted at all, even on a new database?

3. how to fix the error without abandoning current build/creating new database?


Thank you in advance



2024-06-23 14:53:20,571 4674 ERROR odoodb odoo.modules.registry: Failed to load registry 
Traceback (most recent call last):
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/tools/cache.py", line 99, in lookup
    r = d[key]
        ~^^^^^
  File "", line 2, in __getitem__
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/tools/func.py", line 87, in locked
    return func(inst, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/tools/lru.py", line 34, in __getitem__
    a = self.d[obj]
        ~~~~~~^^^^^
KeyError: ('ir.model.data', , 'account.1_stock_in')
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/modules/registry.py", line 113, in new
    odoo.modules.load_modules(registry, force_demo, status, update_module)
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/modules/loading.py", line 480, in load_modules
    processed_modules += load_marked_modules(env, graph,
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/modules/loading.py", line 364, in load_marked_modules
    loaded, processed = load_module_graph(
                        ^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/modules/loading.py", line 245, in load_module_graph
    getattr(py_module, post_init)(env)
  File "/Users/aryono/WebProjects/odoo/odoo/addons/stock_account/__init__.py", line 41, in _configure_journals
    ChartTemplate._post_load_data(template_code, company, template_data)
  File "/Users/aryono/WebProjects/odoo/odoo/addons/stock_account/models/account_chart_template.py", line 26, in _post_load_data
    self.env['ir.property']._set_default(fname, 'product.category', self.ref(value).id, company=company)
                                                                    ^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/addons/account/models/chart_template.py", line 1038, in ref
    or self.env.ref(f"account.{self.env.company.parent_ids[0].id}_{xmlid}", raise_if_not_found)
       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/api.py", line 580, in ref
    res_model, res_id = self['ir.model.data']._xmlid_to_res_model_res_id(
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/addons/base/models/ir_model.py", line 2187, in _xmlid_to_res_model_res_id
    return self._xmlid_lookup(xmlid)
           ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "", line 2, in _xmlid_lookup
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/tools/cache.py", line 104, in lookup
    value = d[key] = self.method(*args, **kwargs)
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/addons/base/models/ir_model.py", line 2180, in _xmlid_lookup
    raise ValueError('External ID not found in the system: %s' % xmlid)
ValueError: External ID not found in the system: account.1_stock_in
2024-06-23 14:53:20,578 4674 INFO odoodb odoo.modules.loading: loading 1 modules...
2024-06-23 14:53:20,583 4674 INFO odoodb odoo.modules.loading: 1 modules loaded in 0.00s, 0 queries (+0 extra)
2024-06-23 14:53:20,588 4674 INFO odoodb odoo.modules.loading: loading 74 modules...
2024-06-23 14:53:20,611 4674 INFO odoodb odoo.modules.loading: 74 modules loaded in 0.02s, 0 queries (+0 extra)
2024-06-23 14:53:20,676 4674 INFO odoodb odoo.modules.loading: Modules loaded.
2024-06-23 14:53:20,678 4674 INFO odoodb odoo.modules.registry: Registry loaded in 0.104s
2024-06-23 14:53:20,679 4674 ERROR odoodb odoo.http: Exception during request handling.
Traceback (most recent call last):
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/tools/cache.py", line 99, in lookup
    r = d[key]
        ~^^^^^
  File "", line 2, in __getitem__
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/tools/func.py", line 87, in locked
    return func(inst, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/tools/lru.py", line 34, in __getitem__
    a = self.d[obj]
        ~~~~~~^^^^^
KeyError: ('ir.model.data', , 'account.1_stock_in')
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/http.py", line 2189, in __call__
    response = request._serve_db()
               ^^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/http.py", line 1764, in _serve_db
    return service_model.retrying(self._serve_ir_http, self.env)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/service/model.py", line 133, in retrying
    result = func()
             ^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/http.py", line 1791, in _serve_ir_http
    response = self.dispatcher.dispatch(rule.endpoint, args)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/http.py", line 1995, in dispatch
    result = self.request.registry['ir.http']._dispatch(endpoint)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/addons/base/models/ir_http.py", line 222, in _dispatch
    result = endpoint(**request.params)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/http.py", line 741, in route_wrapper
    result = endpoint(self, *args, **params_ok)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/addons/web/controllers/dataset.py", line 28, in call_button
    action = self._call_kw(model, method, args, kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/addons/web/controllers/dataset.py", line 20, in _call_kw
    return call_kw(request.env[model], method, args, kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/api.py", line 468, in call_kw
    result = _call_kw_multi(method, model, args, kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/api.py", line 453, in _call_kw_multi
    result = method(recs, *args, **kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "", line 2, in button_immediate_install
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/addons/base/models/ir_module.py", line 75, in check_and_log
    return method(self, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/addons/base/models/ir_module.py", line 466, in button_immediate_install
    return self._button_immediate_function(self.env.registry[self._name].button_install)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/addons/base/models/ir_module.py", line 590, in _button_immediate_function
    registry = modules.registry.Registry.new(self._cr.dbname, update_module=True)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "", line 2, in new
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/tools/func.py", line 87, in locked
    return func(inst, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/modules/registry.py", line 113, in new
    odoo.modules.load_modules(registry, force_demo, status, update_module)
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/modules/loading.py", line 480, in load_modules
    processed_modules += load_marked_modules(env, graph,
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/modules/loading.py", line 364, in load_marked_modules
    loaded, processed = load_module_graph(
                        ^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/modules/loading.py", line 245, in load_module_graph
    getattr(py_module, post_init)(env)
  File "/Users/aryono/WebProjects/odoo/odoo/addons/stock_account/__init__.py", line 41, in _configure_journals
    ChartTemplate._post_load_data(template_code, company, template_data)
  File "/Users/aryono/WebProjects/odoo/odoo/addons/stock_account/models/account_chart_template.py", line 26, in _post_load_data
    self.env['ir.property']._set_default(fname, 'product.category', self.ref(value).id, company=company)
                                                                    ^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/addons/account/models/chart_template.py", line 1038, in ref
    or self.env.ref(f"account.{self.env.company.parent_ids[0].id}_{xmlid}", raise_if_not_found)
       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/api.py", line 580, in ref
    res_model, res_id = self['ir.model.data']._xmlid_to_res_model_res_id(
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/addons/base/models/ir_model.py", line 2187, in _xmlid_to_res_model_res_id
    return self._xmlid_lookup(xmlid)
           ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "", line 2, in _xmlid_lookup
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/tools/cache.py", line 104, in lookup
    value = d[key] = self.method(*args, **kwargs)
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/addons/base/models/ir_model.py", line 2180, in _xmlid_lookup
    raise ValueError('External ID not found in the system: %s' % xmlid)
ValueError: External ID not found in the system: account.1_stock_in
2024-06-23 14:53:20,680 4674 INFO odoodb werkzeug: 127.0.0.1 - - [23/Jun/2024 14:53:20] "POST /web/dataset/call_button HTTP/1.1" 200 - 8919 1.876 1.893
2024-06-23 14:53:37,801 4674 INFO odoodb odoo.addons.base.models.ir_cron: Starting job `Procurement: run scheduler`.
2024-06-23 14:53:37,809 4674 ERROR odoodb odoo.addons.base.models.ir_cron: Call from cron Procurement: run scheduler for server action #349 failed in Job #28
Traceback (most recent call last):
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/addons/base/models/ir_cron.py", line 393, in _callback
    self.env['ir.actions.server'].browse(server_action_id).run()
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/addons/base/models/ir_actions.py", line 917, in run
    self.env[model_name].check_access_rights("write")
    ~~~~~~~~^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/api.py", line 534, in __getitem__
    return self.registry[model_name](self, (), ())
           ~~~~~~~~~~~~~^^^^^^^^^^^^
  File "/Users/aryono/WebProjects/odoo/odoo/odoo/modules/registry.py", line 213, in __getitem__
    return self.models[model_name]
           ~~~~~~~~~~~^^^^^^^^^^^^
KeyError: 'procurement.group'
0
Avatar
Descartar
Hemangi Rupareliya(rupareliyahemangi145@gmail.com)

Hello Aryono,

Did you find any solution for this? I am facing same error when installing POS module after installing CRM module.

Lars Aam

Just a guess: When you install Inventory it creates Product categories where there are default accounts for income and expense. The accounts depends on your fiscal localization.
If you deleted these, it might be the reason for the error. Strange that the error message mention key error as 'procurement.group'. There is no direct relation to product categories from that model, but relations to manufacturing and stock moves. That might be the reason behind. Stock moves create accounting entries, and the account come from Product categories.

A safer way to put accounts you do not need out of use, is to flag as 'Deprecated'. It is recommended.

Avatar
Aryono
Autor Best Answer

ok, posted, here is the link

https://github.com/odoo/odoo/issues/170471

0
Avatar
Descartar
Aryono
Autor

Hi Hemangi Rupareliya,
as my project not live yet, I really considering nuking everything and starts over

Hi Lars Aam, thank you for answering.
ok, from now on, I will mark unused COAs to deprecated.
Would be nice if Odoo fix this and give warning for unsafe COA deletion.

Avatar
Niyas Raphy (Walnut Software Solutions)
Best Answer

Hi,
Can you report the same with detailed steps to reproduce in: https://github.com/odoo/odoo/issues  so that odoo can look into it and fix it.

Thanks

0
Avatar
Descartar
Enjoying the discussion? Don't just read, join in!

Create an account today to enjoy exclusive features and engage with our awesome community!

Registrar-se
Related Posts Respostes Vistes Activitat
Switch COA in running company Solved
Accounting COA
Avatar
Avatar
2
de nov. 24
1551
Inventory Adjustments in Loss Account Solved
Inventory Accounting
Avatar
Avatar
Avatar
11
de febr. 23
11125
Automatic expense of inventory items when moved to another internal location Solved
Inventory Accounting Automation COGS
Avatar
Avatar
Avatar
3
d’ag. 24
3354
Quant's editing is restricted, you can't do this operation.
Inventory
Avatar
Avatar
Avatar
2
de nov. 25
692
How to attach specific locations to products
Inventory
Avatar
Avatar
Avatar
2
d’ag. 25
1554
Community
  • Tutorials
  • Documentació
  • Fòrum
Codi obert
  • Descarregar
  • GitHub
  • Runbot
  • Traduccions
Serveis
  • Allotjament a Odoo.sh
  • Suport
  • Actualització
  • Desenvolupaments personalitzats
  • Educació
  • Troba un comptable
  • Troba un partner
  • Converteix-te en partner
Sobre nosaltres
  • La nostra empresa
  • Actius de marca
  • Contacta amb nosaltres
  • Llocs de treball
  • Esdeveniments
  • Pòdcast
  • Blog
  • Clients
  • Informació legal • Privacitat
  • Seguretat
الْعَرَبيّة Català 简体中文 繁體中文 (台灣) Čeština Dansk Nederlands English Suomi Français Deutsch हिंदी Bahasa Indonesia Italiano 日本語 한국어 (KR) Lietuvių kalba Język polski Português (BR) română русский язык Slovenský jazyk slovenščina Español (América Latina) Español ภาษาไทย Türkçe українська Tiếng Việt

Odoo és un conjunt d'aplicacions empresarials de codi obert que cobreix totes les necessitats de la teva empresa: CRM, comerç electrònic, comptabilitat, inventari, punt de venda, gestió de projectes, etc.

La proposta única de valor d'Odoo és ser molt fàcil d'utilitzar i estar totalment integrat, ambdues alhora.

Website made with

Odoo Experience on YouTube

1. Use the live chat to ask your questions.
2. The operator answers within a few minutes.

Live support on Youtube
Watch now