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

[RFC] bot message when migration PR doesn't respect history. #159

Open
legalsylvain opened this issue Nov 2, 2021 · 5 comments
Open

[RFC] bot message when migration PR doesn't respect history. #159

legalsylvain opened this issue Nov 2, 2021 · 5 comments
Labels
enhancement New feature or request

Comments

@legalsylvain
Copy link
Collaborator

Event : On new PR

Check : If PR name contains [MIG] (not sensitive check) AND commit quantity = 1

Message :

Thanks for the contribution.

Please preserve commit history following technical method explained in https://github.com/OCA/maintainer-tools/wiki/#migration

If the jump is between several versions, you have to modify the source branch in the main command to accommodate it to this circumstance.

You can also take a look on the project https://github.com/OCA/odoo-module-migrator/ to make easier migration

Ref : @pedrobaeza in OCA/web#2067 (comment).

Nice to have feature in my opinion to avoid to repeat always the same thing. (even it will not cover all the case, specially if the PR contains more than 1 commit).

@pedrobaeza
Copy link
Member

👍

@sbidoul sbidoul added the enhancement New feature or request label Dec 14, 2021
@rousseldenis
Copy link
Sponsor

Mmmh, your check can be false in some repositories as they maintain branches from preceding ones (and so, len(migration commit) == 1.

I'm in favor of this, but with a check a little bit cleverer (but don't know how yet).

Apart of that, I think we should change OCA main branches behaviour with the one I described above. It will facilitate review in order to have less commit history

@legalsylvain
Copy link
Collaborator Author

What about to change the texte of the message ? Something like "are you sûre you preserved history" ?

@legalsylvain
Copy link
Collaborator Author

@rousseldenis : any pov regarding my proposal ?

@rousseldenis
Copy link
Sponsor

@rousseldenis : any pov regarding my proposal ?

Yes that's sound good.

IMHO, we should add to conditions 'if module directory isn't in repo yet'. So, this will work in all conditions I explained before.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants