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

WIP: Add merge-prs.sh script to contrib/ #923

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

apoelstra
Copy link
Member

@apoelstra apoelstra commented Nov 3, 2020

TODO

  • check whether we're running from /tmp and don't output the "bail out" warning
  • check for chronic and any other tools we might need
  • use ccache rather than skipping autogen/configure (and configure in multiple ways?)
  • don't require running from the project root
  • check for required remotes, required branches, etc; notice if merged-master is out of date
  • notice if there are uncommitted changes and refuse to run
  • add "dry run" mode
  • add mode to validate others' commits, including noticing skipped PRs

@apoelstra
Copy link
Member Author

Another thing we should deal with is that the functional tests sometimes fail due to resource contention (typically this looks like errors of the form assert self.rpc_connected and self.rpc is not None, self._node_msg("Error: no RPC connection") in the Python backtrace, which fortunately is easy to match on). We should notice this and retry.

@apoelstra
Copy link
Member Author

I realize that the RPC errors only happen when I mess with my network interfaces while the tests are running. Probably I should just not do that.

@apoelstra
Copy link
Member Author

More missing features

  • Give user control over all the -jXX choices
  • Don't sort the PRs; let user decide whether to take Elements PRs or Bitcoin PRs

@apoelstra
Copy link
Member Author

@gwillen do you remember what the point of all this "copy to /tmp" complexity was?

@gwillen
Copy link
Contributor

gwillen commented Sep 5, 2021

@gwillen do you remember what the point of all this "copy to /tmp" complexity was?

Because otherwise, when the script starts checking out branches / merging things / etc., it is liable to check itself out of existence, if you are running it from inside the same repo it's operating on. (Or check itself out to the wrong version, or...)

@apoelstra
Copy link
Member Author

It won't check itself out of existence, because it only checks things out via git merge ... which will only delete files if those files were deleted in whatever we're merging.

It may update itself, yes, but this is probably expected and good. We could add some code that would detect changes (much easier to do than /tmp shenanigans) and to advise the user to restart the script whenever this happens.

But regardless I think this will be very rare.

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

Successfully merging this pull request may close these issues.

2 participants