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

Resolve conflicts in generated files. #41

Open
serhiy-storchaka opened this issue Oct 26, 2017 · 9 comments
Open

Resolve conflicts in generated files. #41

serhiy-storchaka opened this issue Oct 26, 2017 · 9 comments

Comments

@serhiy-storchaka
Copy link
Member

For now the automated cherry-pick failed if generated files are changed. These conflicts can be resolved automatically — just regenerate files by running make regen-all (or with more specific targets, depending on affected files).

@Mariatta
Copy link
Member

@serhiy-storchaka Do you have an example of such PR?

I usually look at documentation changes, so I'm not familiar with make regen-all.

  1. Is there a way to detect when make regen-all should be run? For example, what are the affected paths?

  2. Will it hurt if we run make regen-all for each backport?

Thanks :)

@Mariatta
Copy link
Member

and should this be done even when using cherry-picker.py command line?

@serhiy-storchaka
Copy link
Member Author

The recent example: python/cpython#4118.

For running make regen-all you need more than just git. First, you need to run ./configure. For regenerating the grammar parser you need to build and run a special binary. All this takes a time. It is more efficient to run different commands depending on the files containing conflicts.

@Mariatta
Copy link
Member

We're running the webservice in heroku, and I don't think we can run ./configure from within heroku, it doesn't have the necessary software/libraries installed.
So I don't think we can do this.

@merwok
Copy link
Member

merwok commented Nov 12, 2018

I think https://github.com/heroku/heroku-buildpack-apt could work here.
Someone would need to run apt build-dep python3.7 on a system similar to Heroku to generate the list of required packages and write it to a file named «Aptfile».

Then the issue may be limitations (time) on background jobs or one-off dynos or whatever is used to run configure.

@Mariatta
Copy link
Member

Time shouldn't be an issue. Backport jobs are all done in the worker dyno.

@Mariatta
Copy link
Member

But I don't know a thing about the buildpack in Heroku..

@merwok
Copy link
Member

merwok commented Nov 13, 2018

I’ve used that buildpack (in addition to the base Python buildpack), would be happy to discuss setting it up!

@asottile
Copy link

perhaps even a custom merge driver could be written for this? (at least, specifically for the argument clinic files which is what I hit in python/cherry-picker#18)

and then the various cherry-picking / etc. tooling can use that merge driver?

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

No branches or pull requests

4 participants