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

postBuildStep's should probably be scheduled regardless of build skips #295

Open
antifuchs opened this issue Sep 24, 2024 · 8 comments
Open

Comments

@antifuchs
Copy link
Contributor

I have an "effect" (not a hercules-ci-effect! no idea how to use those tbh) via a postBuildStep that I would like to run only on the default branch of my repo. If I make a pull request that affects that attribute, it properly gets run on the PR branch and decides it has nothing to do; but if I merge the PR, the build is skipped and the postBuildStep isn't executed - it isn't even scheduled.

This is what a build on a PR branch looks like:
image

And this is on the merge commit:
image

I believe what happens here is that the evaluation counts as "cached" coming out of nix-eval-jobs, which prompts buildbot-nix to not build & then not schedule the following postBuildSteps either.

What I think would be neat is if we could:

  • schedule postBuildSteps, either by default or via a configurable attribute
  • maybe expose the doStepIf buildbot attribute, so steps can decide for themselves based on the properties of the build whether they are supposed to run or not.
@Mic92
Copy link
Member

Mic92 commented Sep 25, 2024

I think these postBuildSteps should be just used for custom binary cache upload logic rather than continuous delivery and I rather not want to make building individual packages more expensive by adding more steps since it's already quite slow (We see this on flakes building thousands of packages). This would be than only available when we merged: #68

@Mic92
Copy link
Member

Mic92 commented Sep 25, 2024

If you want to make Hercules Ci happen faster, you can probably help us implementing it.

@antifuchs
Copy link
Contributor Author

Yeah, I can see how abusing the "build" metaphor isn't something you would want to do. That said, I can't wrap my head around how hercules-ci effects works, and how it's supposed to fit into buildbot-nix. Is there a design doc I can look at?

@Mic92
Copy link
Member

Mic92 commented Sep 25, 2024

We will probably write documentation/examples and use it our self once it is in. Otherwise I can just refer to hercules-ci own documentation.

@antifuchs
Copy link
Contributor Author

I get that - but how will hci effects integrate into buildbot? Will a worker act as the equivalent of the hercules-ci agent, or will that still require the agent to be in place? Probably should take that discussion to #68 (:

@Mic92
Copy link
Member

Mic92 commented Sep 25, 2024

I already implemented the runner interface of hercules-ci effects, so it will run in a buildbot worker as in a bubblewrap container.

@Mic92
Copy link
Member

Mic92 commented Sep 25, 2024

def run_effects(

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

2 participants