Overslaan naar inhoud
Menu
Je moet geregistreerd zijn om te kunnen communiceren met de community.
Deze vraag is gerapporteerd
1 Beantwoorden
845 Weergaven

Hi,
i wanted to change the name of the folder for a custom module which has been already installed and has been referenced many times inside the code. when i change the folder name and all other referenced places accordingly, i get KeyError and the system cannot find my custom app. Any tips on how to do it effeciently? Thanks in Advance.

 

Avatar
Annuleer
Beste antwoord

Hello Guhan 

First try 2 things 

  1. Updating your server without the name of the folder with only db and the folder path to your folder
  2. update app list from the apps page 

it this doesnt work then try to copy paste the error or show a photo if youre eligible to put screenshots in the forum.

Thanks

Avatar
Annuleer
Auteur

i did what you have mentioned. in the apps it shows now 2 apps one with the old name that is already been installed and the other with the new name which is not yet installed. because of the name change the system thinks it is a new app and also in python it shows all the files under this folder are completely new and asks for a git commit.

and this was my error
Traceback (most recent call last):

File "/home/guhan/odoo/odoo/odoo/registry.py", line 213, in __getitem__

return self.models[model_name]

KeyError: 'asset'

Try doing with a new db if still this happens then i believe there's a mistake youre overseeing as you have created the app with the different name and copied it in you folder structure thus it shows 2 different apps on the odoo apps list you have to delete the old one then only it will stop showing you that if you have 2 different apps with old one and the new one name and then youre error will be solved,
there can be one more possibility that you have used something which shows you error then you need to get me the whole error that is been shown in the terminal/your server app in which your server runs.
also if anything different than the conveyed happens then also tell me in this response i will try my best to solve your problem.
Thanks

Gerelateerde posts Antwoorden Weergaven Activiteit
0
nov. 23
1383
2
apr. 25
7481
6
sep. 21
23507
4
apr. 19
4596
1
mrt. 15
17679