Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

8.0 Add module partner_relation #83

Closed
wants to merge 7 commits into from

Conversation

alexis-via
Copy link
Contributor

Please refer to the README.rst for a full description of the module.


_columns = {
'name': fields.char(
'Relation Name', size=32, required=True, translate=True),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a special reason to put a max size here?

@guewen
Copy link
Member

guewen commented Jan 29, 2015

The installation of the module fails on Travis:

Traceback (most recent call last):

File "/home/travis/odoo-8.0/openerp/service/server.py", line 909, in preload_registries

registry = RegistryManager.new(dbname, update_module=update_module)

File "/home/travis/odoo-8.0/openerp/modules/registry.py", line 366, in new

openerp.modules.load_modules(registry._db, force_demo, status, update_module)

File "/home/travis/odoo-8.0/openerp/modules/loading.py", line 351, in load_modules

force, status, report, loaded_modules, update_module)

File "/home/travis/odoo-8.0/openerp/modules/loading.py", line 255, in load_marked_modules

loaded, processed = load_module_graph(cr, graph, progressdict, report=report, skip_modules=loaded_modules, perform_checks=perform_checks)

File "/home/travis/odoo-8.0/openerp/modules/loading.py", line 179, in load_module_graph

_load_data(cr, module_name, idref, mode, kind='demo')

File "/home/travis/odoo-8.0/openerp/modules/loading.py", line 118, in _load_data

tools.convert_file(cr, module_name, filename, idref, mode, noupdate, kind, report)

File "/home/travis/odoo-8.0/openerp/tools/convert.py", line 901, in convert_file

convert_xml_import(cr, module, fp, idref, mode, noupdate, report)

File "/home/travis/odoo-8.0/openerp/tools/convert.py", line 987, in convert_xml_import

obj.parse(doc.getroot(), mode=mode)

File "/home/travis/odoo-8.0/openerp/tools/convert.py", line 853, in parse

self._tags[rec.tag](self.cr, rec, n, mode=mode)

File "/home/travis/odoo-8.0/openerp/tools/convert.py", line 763, in _tag_record

id = self.pool['ir.model.data']._update(cr, self.uid, rec_model, self.module, res, rec_id or False, not self.isnoupdate(data_node), noupdate=self.isnoupdate(data_node), mode=self.mode, context=rec_context )

File "/home/travis/odoo-8.0/openerp/api.py", line 241, in wrapper

return old_api(self, *args, **kwargs)

File "/home/travis/odoo-8.0/openerp/addons/base/ir/ir_model.py", line 1042, in _update

model_obj.write(cr, uid, [res_id], values, context=context)

File "/home/travis/odoo-8.0/openerp/api.py", line 241, in wrapper

return old_api(self, *args, **kwargs)

File "/home/travis/build/OCA/partner-contact/partner_relation/partner_relation.py", line 92, in write

_('It is not possible to modify the reverse of a relation '

ParseError: "Error:

It is not possible to modify the reverse of a relation type. You should desactivate or delete this relation type and create a new one." while parsing /home/travis/build/OCA/partner-contact/partner_relation/partner_relation_demo.xml:16, near

<record id="is_integrator_of" model="res.partner.relation.type">

<field name="name">is an integrator of</field>

<field name="reverse_id" ref="is_editor_of"/>

</record>

@guewen
Copy link
Member

guewen commented Jan 29, 2015

(some tests would help to keep up)

@alexis-via
Copy link
Contributor Author

When I install the module here on my odoo v8, it works very well. I don't understand why Travis would fail when installing the module.

@guewen
Copy link
Member

guewen commented Jan 29, 2015

Do you work with the HEAD of 8.0? Could it be a recent revision on the server that broke something?

It could also be incompatibility with another module :-(

@pedrobaeza
Copy link
Member

The fail is with demo data. Have you tried that?

@alexis-via
Copy link
Contributor Author

@guewen @pedrobaeza
I updated my code of odoo/8.0 to have the latest version from github, and I still can install the module partner_relation with demo data without any issue.

@alexis-via
Copy link
Contributor Author

This time, the Travis errors are NOT related to my module partner_relation: they are caused by failures in the YAML tests of partner_firstname, and these failures happen with up-to-date code of partner-contact and without the module partner_relation.

@alexis-via
Copy link
Contributor Author

Travis fails when "loading partner_firstname/res_user_view.xml", so it's not related to the module in this PR

@pedrobaeza
Copy link
Member

Is this anyway related with https://github.com/OCA/partner-contact/tree/7.0/partner_relations?

@hbrunn
Copy link
Member

hbrunn commented Mar 10, 2015

@pedrobaeza
Copy link
Member

But we shouldn't provide 2 similar alternatives (and with similar name) on OCA. If we continue with this on v8, there must be a migration script from v7 version.

@hbrunn
Copy link
Member

hbrunn commented Mar 10, 2015

I'm not so sure if the concepts used in both modules match 1:1. Sooner or later, we'll provide a 8.0 version of partner_relations anyways. As long as both are well maintained, why would it be a problem to have both? It might even make sense to include a hint to the other module in each module's description with some kind of comparison matrix to avoid confusion (that is necessary when we have both in the same version)

@pedrobaeza
Copy link
Member

Well, let's see what others think.

@eLBati
Copy link
Member

eLBati commented Mar 15, 2015

If the 2 modules do the same things (functionally speaking), I think we should chose one.
As the one from Therp is already in official branch, it should be the starting point and migrated to 8.0.
If @alexis-via proposes a totally new approach to the problem (I did not investigate the differences), I agree there should be a migration script from 7.0 version

@alexis-via
Copy link
Contributor Author

OK, let's forget this :-(

@alexis-via
Copy link
Contributor Author

I moved the module partner_relation here https://github.com/akretion/odoo-partner-relation
Enjoy !

@antespi
Copy link
Contributor

antespi commented Mar 25, 2015

Hi @hbrunn, we need this addon for a customer in v8 and we like more partner_relations (v7, therp) approach, but it is also more complex and we wonder know if you are already migrating it to v8 or we can start this work.
If you are already migrating it, just tell me where and we'll try to help, thanks.

@hbrunn
Copy link
Member

hbrunn commented Mar 25, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants