Commit Graph
20 Commits
Author SHA1 Message Date
Christophe Simonis 51225c9b9f [MERGE] forward port branch saas-15 up to 52e88036f2 2018-08-14 18:24:40 +02:00
Christophe Simonis 71bba5e43d [FIX] anonymization: ignore unreachable code pylint warning 2018-08-14 16:55:36 +02:00
Christophe Simonis 70128a2dfc [MERGE] forward port branch 9.0 up to d2605bccdb 2018-08-14 15:12:47 +02:00
Olivier Laurent 046e4ee29e [FIX] anonymization: P3 encoding issues 2017-11-29 16:19:11 +01:00
Raphael Collet 9bd3240b51 [IMP] anonymization: use JSON instead of pickle for the file format 2017-08-28 09:53:23 +02:00
Xavier Morel a5e21f69e7 [FIX] P3: view arch should be text-'encoded' XML 2017-08-20 23:25:54 +02:00
Christophe Simonis ed2ddeccdf [MERGE] forward port branch saas-16 up to 1b50c829ef 2017-06-15 18:46:47 +02:00
Christophe Simonis 1b50c829ef [MERGE] forward port branch saas-15 up to 9713dc2e1f 2017-06-15 18:44:16 +02:00
Olivier Dony 625c0d5d8e [FIX] anonymization: correct pickle protocol and import 2017-06-15 16:25:25 +02:00
Xavier Morel 01e3514147 [FIX] P3: urllib, urllib2 and urlparse
In Python 3, all of these were "consolidated" under urllib(.request,
.parse, .errors) which is inconvenient.

Since we already have hard dependencies on requests and
werkzeug(.urls, which is a backport of Python 3's unicode-aware
urllib.parse) migrate *everything* to that.

A sticking point is urllib2.URLError, those were (mostly) replaced by
the slightly more general IOError which URLError extends.
2017-05-15 12:26:30 +02:00
xmo-odoo fffaf735f5 [FIX] P3: list -> iterable builtins (#16811)
In Python 3:

* various builtins and dict methods were changed to return
  view/iterable objects rather than lists
* and the separate Python 2 view/iterable builtins and methods were
  removed altogether

This is problematic when using these items as list (which the happens
repeatedly in Odoo), but more viciously when iterating *multiple times*
over them (which also happens, which I've messed up multiple times while
writing this, and which is a pain to debug even when you've just created
the issue).

Convert all code using these to semantics-matching cross-version
helper functions to get the LCD behaviour between P2 and P3, and
forbid the builtins via lint.

issue #8530
2017-05-10 09:39:55 +02:00
xmo-odoo b4429c2a91 [FIX] Various P3-related import changes
* LDAP import: python-ldap is not python3-compatible, pyldap is

  Warning: only supported from debian Stretch (current testing)?
  https://packages.debian.org/search?searchon=names&keywords=pyldap

* implicitly relative imports
* imports of moved or removed stdlib modules

issue #8530
2017-04-28 09:06:53 +02:00
Christophe Simonis 6a7db30508 [MERGE] forward port branch saas-11 up to f23394b83a 2017-01-25 15:01:29 +01:00
Olivier Laurent 84dc7e8d34 [FIX] anonymization: fix port to new API
A big section of code was wrongly indented (1 level too much).
The method was returning after 1 iteration of the loop.

Closes #14764
2016-12-19 16:15:09 +01:00
Christophe Simonis 856476d441 [MERGE] forward port branch saas-12 up to b1b700a 2016-09-22 15:23:45 +02:00
Raphael Collet bf668b64c1 [IMP] all: clean usage of safe_eval
Specifically: do not import `safe_eval` as `eval`, keep it explicit instead.
2016-08-11 15:36:56 +02:00
Ravi Gohil 8b47073b1e [IMP] anonymization: remove method '_raise_after_history_update',
This method is not very useful. Why ? When any exception is raised, odoo will rollback
all the transaction which were not committed, hence the purpose of the method won't be
served, which was, to update the 'history' record which was created before an invalid
action was performed.
2016-08-09 13:18:36 +02:00
Ravi Gohil 946a19d9be [FIX] anonymization: Make anonymization supported for 'monetary' type fields. 2016-08-09 13:18:36 +02:00
Jigar Patel 94ba7cd75e [MIG] anonymization: Migrated to new api. 2016-08-09 11:47:34 +02:00
Ravi Gohil cc57fcba7a [SPLIT] anonymization: Move wizard related code to wizard directory 2016-08-09 11:47:09 +02:00