The same problem that was fixed for the `base` addon in #948 happened with random addons that do not depend on `module_auto_update` (a.k.a. any addon) that Odoo decided to load before that one in the graph.
Now we always check for all addons if their state has changed, and make sure to trigger the udpate mechanism that stores the right value in `installed_checksum_dir` field.
If you installed and uninstalled the addon right away, you'd get a ProgrammingError saying that some columns exist no more. Checks are done now using `search_read`, which lets us limit the fields being fetched, and the environment is cleared to make sure nothing fails.
Also we now guess if this own addon has been uninstalled and skip further logic if so, given it would hit broken triggers otherwise as it did before.
* [FIX] auth_from_http_remote_user - Lint
* [FIX] server_environment - Lint
* [FIX] base_module_doc_rst - Lint
* [FIX] fetchmail_notify_error_to_sender - Fix XML view, it was the 'active' field from 'fetchmail_attach_from_folder' module which was targeted by mistake (belonging to another data model)
* `button_uninstall` calls `get_module_list`, which subsequently forces module upgrades. Add a context validation to prevent that
* Add test for button_immediate_uninstall
* Mock commit for immediate uninstall
* Fix immediate uninstall test
* Switch nesting
* Bump module version
* Fix Firefox MFA login error by adding logic that checks for the Firefox edge
case where redirect_with_hash returns a Response object rather than a string
* Add test case for this scenario
Includes:
- Normal migration steps.
- Usage of brand new `_inherit = "base"` in Odoo 10, which implies
removing a lot of monkey-patching code.
- Log a warning when multiple matches are found.
* Fix wrong README format.
* [FIX][base_import_match] Avoid UnicodeEncodeError.
When the model or field you chose was translated and had some non-ascii
character, you got an error like this: `UnicodeEncodeError: 'ascii' codec can't
encode character u'\xed' in position 15: ordinal not in range(128)`.
Now, using unicode strings, that won't happen again.
* Do not require a hidden field.
* Further unicode protection, add ondelete clause.
By default, when importing data (like CSV import) with the ``base_import``
module, Odoo follows this rule:
1. If you import the XMLID of a record, make an **update**.
2. If you do not, **create** a new record.
This module allows you to set additional rules to match if a given import is an
update or a new record.
This is useful when you need to sync heterogeneous databases, and the field you
use to match records in those databases with Odoo's is not the XMLID but the
name, VAT, email, etc.
After installing this module, the import logic will be changed to:
1. If you import the XMLID of a record, make an **update**.
2. If you do not:
1. If there are import match rules for the model you are importing:
1. Discard the rules that require fields you are not importing.
2. Traverse the remaining rules one by one in order to find a match in
the database.
1. If one match is found:
1. Stop traversing the rest of valid rules.
2. **Update** that record.
2. If zero or multiple matches are found:
1. Continue with the next rule.
3. If all rules are exhausted and no single match is found:
1. **Create** a new record.
2. If there are no match rules for your model:
1. **Create** a new record.