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

[13.0] migrate base_external_system #85

Merged
merged 8 commits into from
Jul 4, 2021

Conversation

NL66278
Copy link

@NL66278 NL66278 commented Aug 20, 2020

No description provided.

lasley and others added 4 commits August 20, 2020 13:59
* [ADD] base_external_system: Implement interface/adapter for external systems

* base_external_system: Fix OS model, add inherits, add validate

* base_external_system: Usability and private key pass

* base_external_system: Use contextmanager in adapter client

* base_external_system: Move contextmanager to interface

* base_external_system: Include contextmanager on adapter and system

* base_external_system: Unify client

* Use password widget for password field

* Add tests & security

* Fix lint

* Add plaintext note
* In cases of deep inheritance, it may be required to create an adapter directly. Add an override in the create via the env context to support this.
* Add default system type if creating from an interface
* Fix interface assignment during creation in adapter
* Perform standard v11 migration
@NL66278 NL66278 mentioned this pull request Aug 20, 2020
8 tasks
@NL66278 NL66278 force-pushed the 13.0-mig-base_external_system branch from a44d896 to 0e3ee4c Compare August 21, 2020 09:11
@NL66278 NL66278 force-pushed the 13.0-mig-base_external_system branch from 0e3ee4c to 1815585 Compare August 21, 2020 09:31
Testing fingerprint, with ignore_finger_print set to False, caused an error, because it would first set
ignore_fingerprint to False, then validate, never getting to actually setting the fingerprint, causing the
following stacktrace:
Traceback (most recent call last):

  File "/home/travis/build/OCA/server-backend/base_external_system/tests/test_external_system.py", line 28, in test_check_fingerprint_allowed

    self.record.write({"ignore_fingerprint": False, "fingerprint": "Data"})

  File "/home/travis/odoo-13.0/odoo/models.py", line 3573, in write

    fields[0].determine_inverse(real_recs)

  File "/home/travis/odoo-13.0/odoo/fields.py", line 1122, in determine_inverse

    self.inverse(records)

  File "/home/travis/odoo-13.0/odoo/fields.py", line 594, in _inverse_related

    target[field.name] = record_value[record]

  File "/home/travis/odoo-13.0/odoo/models.py", line 5629, in __setitem__

    return self._fields[key].__set__(self, value)

  File "/home/travis/odoo-13.0/odoo/fields.py", line 1087, in __set__

    records.write({self.name: write_value})

  File "/home/travis/odoo-13.0/odoo/models.py", line 3568, in write

    real_recs._validate_fields(set(vals) - set(inverse_fields))

  File "/home/travis/odoo-13.0/odoo/models.py", line 1176, in _validate_fields

    check(self)
@dreispt
Copy link
Member

dreispt commented Jul 3, 2021

/ocabot merge nobump

@OCA-git-bot
Copy link
Contributor

On my way to merge this fine PR!
Prepared branch 13.0-ocabot-merge-pr-85-by-dreispt-bump-nobump, awaiting test results.

@OCA-git-bot OCA-git-bot merged commit 3972c8f into OCA:13.0 Jul 4, 2021
@OCA-git-bot
Copy link
Contributor

Congratulations, your PR was merged at 67439e5. Thanks a lot for contributing to OCA. ❤️

SiesslPhillip pushed a commit to grueneerde/OCA-server-backend that referenced this pull request Nov 20, 2024
Syncing from upstream OCA/server-backend (12.0)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants