Skip to content

Commit

Permalink
💚
Browse files Browse the repository at this point in the history
  • Loading branch information
yelizariev committed Dec 12, 2023
1 parent 5e4d11f commit b949536
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions sync/models/sync_project_demo.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,8 @@ def odoo_execute_kw(model, method, *args, **kwargs):
params.DB, secrets.USERNAME, secrets.PASSWORD, {}
)
models = _client.ServerProxy("{}/xmlrpc/2/object".format(params.URL))
except OSError:
raise RetryableJobError("Error on connecting to external Odoo")
except OSError as err:
raise RetryableJobError("Error on connecting to external Odoo") from err
res = models.execute_kw(
params.DB, uid, secrets.PASSWORD, model, method, args, kwargs
)
Expand Down
4 changes: 2 additions & 2 deletions sync/tests/test_links.py
Original file line number Diff line number Diff line change
Expand Up @@ -180,10 +180,10 @@ def test_external_link(self):

# one2many
self.set_link(REL, {"github": 5, "trello": 105})
with self.assertRaises(Exception):
with self.assertRaises(ValidationError):
self.set_link(REL, {"github": 5, "trello": 1005})
self.set_link(REL, {"github": 5, "trello": 1005}, allow_many2many=True)
with self.assertRaises(Exception):
with self.assertRaises(ValidationError):
glink = self.get_link(REL, {"github": 5, "trello": None})
glinks = self.search_links(REL, {"github": 5, "trello": None})
self.assertEqual(2, len(glinks))
Expand Down

0 comments on commit b949536

Please sign in to comment.