Skip to content
This repository was archived by the owner on May 26, 2023. It is now read-only.

New buildstep_inspect plugin#2

Open
twaugh wants to merge 1 commit intocsomh:masterfrom
twaugh:buildstep
Open

New buildstep_inspect plugin#2
twaugh wants to merge 1 commit intocsomh:masterfrom
twaugh:buildstep

Conversation

@twaugh
Copy link
Copy Markdown
Collaborator

@twaugh twaugh commented Feb 22, 2017

See what you think of this. I was thinking about how to test containerbuildsystem/atomic-reactor#647.

"""

key = 'buildstep_inspect'
is_allowed_to_fail = True
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this will be overwritten in buildsteppluginsrunner to False

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can it happen that users might want to configure multiple build-step plugins?

If yes, then I think it makes sense to allow some of them to fail.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, we should probably have an arg to tell it to skip this plugin and try the next one.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

arg to skip plugin?
well plugin can always raise inappropriatebuiltstep exception and it will be treated as nothing bad happened

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

so if you got plugin just for testing just raise that at the end, and it works

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've added arg 'inappropriate': set it to True and the plugin will raise InappropriateBuildStepError.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ahhh ok you meant arg for the plugin

Signed-off-by: Tim Waugh <twaugh@redhat.com>

For inspecting the workflow state at the build-step phase, the
`build_inspect.py` plugin is provided. This can be told whether to
succeed or fail by passing arguments as appropriate when it is
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this useful?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants