commission icon indicating copy to clipboard operation
commission copied to clipboard

[17.0][MIG] sale_commission: Migration to 17.0

Open ambientWave opened this issue 1 year ago • 5 comments

I upgraded the 'sale_commission' module to be installed on Odoo 17.0. More focus was given to upgrading xml files.

The demo files weren't upgraded and hence, an error during installation is warning user that demo data wasn't populated. However, the module can be used without demo data.

Python code needs to be tested thoroughly.

All contributions and comments are welcomed.

Depends on

  • https://github.com/OCA/commission/pull/497
  • https://github.com/OCA/commission/pull/499

ambientWave avatar Jan 19 '24 14:01 ambientWave

The following error from Odoo and OCB tests

odoo-addon-sale_commission @ file:///__w/commission/commission/sale_commission
+ pip install -r test-requirements.txt -c test-constraints.txt
WARNING: The directory '/github/home/.cache/pip' or its parent directory is not owned or is not writable by the current user. The cache has been disabled. Check the permissions and owner of that directory. If executing pip with sudo, you should use sudo's -H flag.
Looking in indexes: https://wheelhouse.odoo-community.org/oca-simple-and-pypi
ERROR: Could not find a version that satisfies the requirement odoo-addon-account_commission<17.1dev,>=17.0dev (from versions: 15.0.2.0.0, 15.0.2.0.1, 15.0.2.1.0, 15.0.2.1.0.2, 15.0.2.1.0.3, 15.0.2.1.0.5, 15.0.2.2.0, 15.0.2.3.0, 15.0.2.3.1, 15.0.2.3.2, 15.0.2.3.3, 15.0.2.3.3.1, 15.0.2.3.3.2, 15.0.2.3.3.4, 15.0.3.0.0, 15.0.3.0.1, 15.0.3.1.0, 15.0.3.2.0, 16.0.1.0.0.2, 16.0.1.0.0.3, 16.0.1.0.0.4, 16.0.1.1.0, 16.0.1.1.1, 16.0.1.1.1.2, 16.0.1.1.1.4, 16.0.1.2.0, 16.0.1.2.0.1, 16.0.1.3.0, 16.0.1.4.0, 16.0.1.4.1, 16.0.1.4.1.1, 16.0.1.4.1.3, 16.0.1.4.1.4, 16.0.1.4.2, 16.0.1.4.2.3, 16.0.1.4.2.5, 16.0.2.0.0, 16.0.2.0.1, 16.0.2.1.0, 16.0.2.2.0)
ERROR: No matching distribution found for odoo-addon-account_commission<17.1dev,>=17.0dev
Error: Process completed with exit code 1.

@pedrobaeza @sbidoul Seems to be a dependency issue. How one can resolve this?

ambientWave avatar Jan 21 '24 07:01 ambientWave

That is because the commission module is not merged yet. See https://github.com/OCA/maintainer-tools/wiki/Use-temporary-reference%28s%29-to-another-pull-request%28s%29

sbidoul avatar Jan 21 '24 11:01 sbidoul

@pedrobaeza Currently, there's a method named 'action_switch_invoice_into_refund_credit_note' that is called from 'account.move' model which seems to exist no more. What you would propose for a resolution? I ported the method from odoo 16.0 and pasted it inside the inherited account.move

ambientWave avatar Jan 21 '24 13:01 ambientWave

Hi @ambientWave

Can you update this PR and fix the commit history?

There should be only 3 commits:

[IMP] sale_commission: pre-commit auto fixes [MIG] sale_commission: Migration to 17.0 [DON'T MERGE] test-requirements.txt

Thank you!

Tisho99 avatar Apr 29 '24 16:04 Tisho99

@Tisho99

Commit history has been cleaned up!

ambientWave avatar May 05 '24 15:05 ambientWave

Hi @ambientWave

account_commission has been merged,

can you remove the dependencies commit to merge this PR?

Tisho99 avatar May 16 '24 16:05 Tisho99

@pedrobaeza @sbidoul @Tisho99 @luis-ron @jimhuds @Jaimermaccione

I want to thank you for your efforts and allowing people around the globe to contribute.

It was an honor.

ambientWave avatar May 17 '24 11:05 ambientWave

Thanks to you for doing the contribution. I hope it won't be the last!

/ocabot migration sale_commission /ocabot merge nobump

pedrobaeza avatar May 17 '24 11:05 pedrobaeza

What a great day to merge this nice PR. Let's do it! Prepared branch 17.0-ocabot-merge-pr-498-by-pedrobaeza-bump-nobump, awaiting test results.

OCA-git-bot avatar May 17 '24 11:05 OCA-git-bot

This PR has the approved label and has been created more than 5 days ago. It should therefore be ready to merge by a maintainer (or a PSC member if the concerned addon has no declared maintainer). 🤖

OCA-git-bot avatar May 17 '24 11:05 OCA-git-bot

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

OCA-git-bot avatar May 17 '24 11:05 OCA-git-bot