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

Implement OpenScanHub prototype #2472

Merged
merged 2 commits into from
Jul 25, 2024

Conversation

lbarcziova
Copy link
Member

@lbarcziova lbarcziova commented Jul 19, 2024

Fixes #2454
Fixes #2463

TODO:

  • docs
  • better error handling
  • better marketing - adding to news footer,.. - this can be done as a followup after running in prod for a week to see if everything works as expected

RELEASE NOTES BEGIN

We have added the initial version of functionality for running scans in OpenScanHub. You can read more about this functionality
here.

RELEASE NOTES END

This comment was marked as outdated.

This comment was marked as outdated.

This comment was marked as outdated.

@lbarcziova lbarcziova changed the title Add initial functionality for OpenScanHub prototype Implement OpenScanHub prototype Jul 23, 2024
@lbarcziova lbarcziova force-pushed the osh-initial branch 2 times, most recently from e6c6ab7 to 1d4d3b6 Compare July 23, 2024 12:14

This comment was marked as outdated.

This comment was marked as outdated.

This comment was marked as outdated.

Copy link
Contributor

Copy link
Contributor

os.getenv("PACKIT_USER_AGENT")
or f"packit-service/{ps_version} ([email protected])"
)
try:
Copy link
Contributor

Choose a reason for hiding this comment

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

May be you can retry on timeouts. This can go as a TODO note.

@lbarcziova
Copy link
Member Author

we have discussed with @siteshwar that we will see whether getting this on staging will uncover some potential problems with OpenScanHub (same as getting it on prod that will cause higher load on OpenScanHub than usual) and could disable the config option depending on that if there will be any issues.

@nforro
Copy link
Member

nforro commented Jul 24, 2024

Wouldn't it be better to move the new methods from CoprBuildEndHandler to a separate helper class?

This comment was marked as outdated.

This comment was marked as outdated.

@lbarcziova
Copy link
Member Author

Wouldn't it be better to move the new methods from CoprBuildEndHandler to a separate helper class?

I assumed this will eventually be moved to a separate handler class once the config is refined later, but as you say, it makes sense to do it already, will change it.

packit_service/worker/handlers/copr.py Outdated Show resolved Hide resolved
packit_service/worker/handlers/copr.py Outdated Show resolved Hide resolved
packit_service/worker/handlers/copr.py Show resolved Hide resolved
packit_service/worker/handlers/copr.py Outdated Show resolved Hide resolved
packit_service/worker/handlers/copr.py Outdated Show resolved Hide resolved
packit_service/worker/handlers/copr.py Outdated Show resolved Hide resolved
@@ -174,6 +174,35 @@ def job_project(self) -> Optional[str]:

return self.default_project_name

def job_project_for_commit_job_config(self, job_config) -> Optional[str]:
Copy link
Member

Choose a reason for hiding this comment

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

Don't we do this somewhere else already? 👀

This comment was marked as outdated.

@packit packit deleted a comment from softwarefactory-project-zuul bot Jul 24, 2024
@lbarcziova
Copy link
Member Author

thanks for the feedback! I went through the suggestions, PTAL @mfocko @nforro

Copy link
Contributor

Copy link
Member

@nforro nforro left a comment

Choose a reason for hiding this comment

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

LGTM. All suggestions are just nitpicks, feel free to ignore them.

packit_service/worker/handlers/copr.py Outdated Show resolved Hide resolved
packit_service/worker/handlers/copr.py Outdated Show resolved Hide resolved
packit_service/worker/handlers/copr.py Outdated Show resolved Hide resolved
packit_service/worker/handlers/copr.py Outdated Show resolved Hide resolved
packit_service/worker/handlers/copr.py Outdated Show resolved Hide resolved
packit_service/worker/handlers/copr.py Outdated Show resolved Hide resolved
Copy link
Contributor

Copy link
Contributor

@lbarcziova lbarcziova added the mergeit When set, zuul wil gate and merge the PR. label Jul 25, 2024
Copy link
Contributor

Build succeeded (gate pipeline).
https://softwarefactory-project.io/zuul/t/packit-service/buildset/078fe6f5eb1d41778d99417141090a45

✔️ pre-commit SUCCESS in 2m 15s

@softwarefactory-project-zuul softwarefactory-project-zuul bot merged commit 8de1710 into packit:main Jul 25, 2024
4 checks passed
@lbarcziova lbarcziova deleted the osh-initial branch July 25, 2024 12:48
softwarefactory-project-zuul bot added a commit to packit/packit.dev that referenced this pull request Jul 29, 2024
Openscanhub prototype docs

Related to #899
Related to packit/packit-service#2472

Reviewed-by: Nikola Forró
softwarefactory-project-zuul bot added a commit that referenced this pull request Aug 5, 2024
Remove trailing dot from OSH task comments

... to make it easier to copy dashboard links.

TODO:

 Write new tests or update the old ones to cover new functionality.
 Update doc-strings where appropriate.
 Update or write new documentation in packit/packit.dev.
 ‹fill in›



Fixes
Related to
#2472
Merge before/after

RELEASE NOTES BEGIN
RELEASE NOTES END

Reviewed-by: Laura Barcziová
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
mergeit When set, zuul wil gate and merge the PR.
Projects
None yet
5 participants