It is currently Sun Feb 12, 2012 6:53 pm

All times are UTC + 2 hours




Post new topic Reply to topic  [ 15 posts ] 
Author Message
 Post subject: Cannot Add New Module
PostPosted: Wed Mar 03, 2010 3:21 pm 
Offline

Joined: Tue Sep 29, 2009 7:08 pm
Posts: 23
Hello,

I just made a very simple module, based on another one, which I made too.
Now, the first one installed correctly, the system found it, using the Update Modules' List function.
But now it is not working for the second module, where I might be wrong?

Here's the __TERP__ file I have for the new Module:

Code:
#
# __TERP__.py FILE
#
{
    "name" : "Send SMS",
    "version" : "1.0",
    "author": "Dimitar Vinarov",
    "category": "Partners/",
    "website": "http://www.tsfy.ie",
    "description": "Module for sending SMS Messages",
    "depends": ["res.partner"],
    "init_xml": [],
    "update_xml": ["sms.xml"],
    "active": False,
   "installable": True
}


Top
 Profile  
 
 Post subject:
PostPosted: Wed Mar 03, 2010 3:25 pm 
Offline

Joined: Fri Oct 21, 2005 12:40 pm
Posts: 170
Location: Turin, Italy
afaik, there's no module named "res.partner"

_________________
Davide Corio
http://www.domsense.com - http://www.agilebg.com


Top
 Profile  
 
 Post subject:
PostPosted: Wed Mar 03, 2010 4:50 pm 
Offline

Joined: Fri Nov 21, 2008 9:56 am
Posts: 3061
Location: Lotharingie
res.partner is a path, which is in module base


Top
 Profile  
 
 Post subject:
PostPosted: Wed Mar 03, 2010 4:57 pm 
Offline

Joined: Tue Sep 29, 2009 7:08 pm
Posts: 23
Okay, agreed.

But even if I change it to base.conact / base_contact or base
there's no difference. The system is not recognizing the folder as new module.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Mar 03, 2010 5:14 pm 
Offline

Joined: Fri Nov 21, 2008 9:56 am
Posts: 3061
Location: Lotharingie
see your errors of write in other modules (base, or others).
example :
write 'blabla' and not "blabla"
'category' see in terp base
'depends' ..... 'base'
.......


Top
 Profile  
 
 Post subject:
PostPosted: Wed Mar 03, 2010 5:17 pm 
Offline

Joined: Tue Sep 29, 2009 7:08 pm
Posts: 23
Ok. I've got your point - use Single quotes instead of Double, but still no difference, openerp is not recognizing the folder as a new module.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Mar 03, 2010 5:34 pm 
Offline

Joined: Fri Nov 21, 2008 9:56 am
Posts: 3061
Location: Lotharingie
each time you do a change in file .py or terp or xml ...., restart openerp-sever.
see, alone, examples of other modules, to add good arguments everywhere.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Mar 03, 2010 5:41 pm 
Offline

Joined: Tue Sep 29, 2009 7:08 pm
Posts: 23
Of course. I am doing this as well.

Is there any other restriction/requirement I am missing? -
- The name of the folder
- or, something in __init__.py
- or the name of the class file?

I am following the exact instructions posted on openERP's site in the Docs section. It worked for me last week but today is not working :) - Even though I made a copy of the working module, renamed it and changed some of the functions and fields of course.

According to me the system must recognize it as a new module.

By the way, is it possible because the repository config is set only to openerp.com, and because the system is not finding any new modules, there to not check the addons folder?
If this is the case, then I would say that this might be a bug ;)


Top
 Profile  
 
 Post subject:
PostPosted: Wed Mar 03, 2010 6:31 pm 
Offline

Joined: Fri Nov 21, 2008 9:56 am
Posts: 3061
Location: Lotharingie
try ffirst with minimum argument


Top
 Profile  
 
 Post subject:
PostPosted: Wed Mar 03, 2010 6:37 pm 
Offline

Joined: Tue Sep 29, 2009 7:08 pm
Posts: 23
What do you mean by that?

I tried with:
Code:
#
# __TERP__.py FILE
#
{
    'name' : 'Send SMS',
    'version" : '1.0',
    'author": 'Dimitar Vinarov',
    'category": 'Partners/',
    'website": 'http://www.tsfy.ie',
    'description": 'Module for sending SMS Messages',
    'installable": True
}


And still nothing.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Mar 03, 2010 6:45 pm 
Offline

Joined: Fri Apr 21, 2006 7:28 pm
Posts: 1332
Location: Cambridge, UK
dvinarov wrote:
Code:
...
{
    'name' : 'Send SMS',
    'version" : '1.0', ...

This is mixing single and double quotes. Your previous had inconsistent indentation.

_________________
Regards, Geoff

Seath Solutions Ltd, Cambridge, UK


Top
 Profile  
 
 Post subject:
PostPosted: Wed Mar 03, 2010 7:01 pm 
Offline

Joined: Tue Sep 29, 2009 7:08 pm
Posts: 23
Ok, I fixed the indentation too, using tabs, but still there's no difference :)
As I wrote previously I am beginning to think that the system is not checking the addons folder if, there're no new modules in the repository URL..

My __terp__.py right now is:

Code:
#
# Use the custom module to put your specific code in a separate module.
#
{
        'name' : 'Send SMS',
        'version' : '1.0',
        'author' : 'TSFY Ltd, Dimitar Vinarov',
        'category' : 'Sales Management/',
        'website': 'http://www.tsfy.ie',
        'description': """Module for sending SMS messages to the customers. """,
        'depends' : ['base'],
        'init_xml' : [],
        'update_xml' : ['sms.xml'],
        'installable': True,
        'active': False,
}


I even tried importing the module, the erp reports that the import is ok, but when I check the addons folder, the zip is simply copied there , and of course is not added in the modules' list.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Mar 03, 2010 7:22 pm 
Offline

Joined: Fri Apr 21, 2006 7:28 pm
Posts: 1332
Location: Cambridge, UK
dvinarov wrote:
... I am beginning to think that the system is not checking the addons folder if, there're no new modules in the repository URL....

I assume that you have at some point done this:
Code:
Administration > Modules Management > Update Modules List
to tell Open ERP that you have a new module. You only need to do it once.

_________________
Regards, Geoff

Seath Solutions Ltd, Cambridge, UK


Top
 Profile  
 
 Post subject:
PostPosted: Wed Mar 03, 2010 7:25 pm 
Offline

Joined: Tue Sep 29, 2009 7:08 pm
Posts: 23
Yes,
I did it.
What I have to do now in order to see the new module in the list?


Top
 Profile  
 
 Post subject:
PostPosted: Wed Mar 03, 2010 7:34 pm 
Offline

Joined: Fri Apr 21, 2006 7:28 pm
Posts: 1332
Location: Cambridge, UK
dvinarov wrote:
... What I have to do now in order to see the new module in the list?

If your module is correctly constructed then nothing more, AFAIK. Once you do the update you should see something like '132 modules updated' '1 new module'.

Start off with something trivial like a profile module and work up from there, perhaps.

_________________
Regards, Geoff

Seath Solutions Ltd, Cambridge, UK


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 15 posts ] 

All times are UTC + 2 hours


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:

Protected by Anti-Spam ACP