Skip to content

Conversation

@aw-was-here
Copy link
Contributor

No description provided.

@aw-was-here aw-was-here requested a review from aajisaka April 26, 2022 19:02
@aw-was-here
Copy link
Contributor Author

Asking @aajisaka to review since this feature request essentially came from him during some other PRs.

Copy link
Member

@ndimiduk ndimiduk left a comment

Choose a reason for hiding this comment

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

Some small questions, looks alright to me otherwise. Should be a nice enhancement!


## HTML Details LInk

By default, if Apache Yetus is under conditions when it would normally write a Github Status (e.g., Jenkins processing
Copy link
Member

Choose a reason for hiding this comment

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

Can you show an example of the current behavior and (if possible) the htmlreport that will be the new default after this patch? I'm looking at an HBase PR (Yetus running in the context of an Jenkins Multi-branch plugin) and I don't see a "Details" link anywhere in the comment left by the Jenkins build worker. Perhaps my example context doesn't apply to this change?

Copy link
Member

Choose a reason for hiding this comment

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

Or perhaps my sample PR doesn't apply at all because HBase isn't yet using the GitHub Checks API...

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Correct. That PR isn't using the checks API. You can see in pretty much any Apache Hadoop PR that down at the bottom there is a 'Details' link for 'Apache Yetus'. That should now point to the HTML report instead of the Jenkins console post this PR.

Copy link
Contributor Author

@aw-was-here aw-was-here Apr 28, 2022

Choose a reason for hiding this comment

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

Apache Yetus 0.12.0

That PR isn't even checks API capable...

# - failure w/log
# - success w/warning log

url=$(get_artifact_url)
Copy link
Member

Choose a reason for hiding this comment

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

Minor nit: why move population of the url value? Does the artifact_url change from the beginning of this function call to down here?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It doesn't and this change was a result of some of the development work that happened previously.

{
declare result=$1

rm "${commentfile}" 2>/dev/null
Copy link
Member

Choose a reason for hiding this comment

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

Why rm with error output ignored instead of something like rm -f ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It might not exist due to a previous failure elsewhere. That's ok and we don't want the error to go to console.

{
declare result=$1

rm "${commentfile}" 2>/dev/null
Copy link
Member

Choose a reason for hiding this comment

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

Should you check the exist code of rm and handle failure?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Failure here is OK to ignore.

@aw-was-here
Copy link
Contributor Author

I'm going to go ahead and merge this one. Thanks for the review @ndimiduk !

@aw-was-here aw-was-here merged commit 03fdf8c into apache:main Apr 29, 2022
@aw-was-here aw-was-here deleted the yetus1060 branch April 29, 2022 16:23
@aajisaka
Copy link
Member

aajisaka commented May 2, 2022

Sorry for being late. I'll test this in Apache Hadoop.

@aajisaka
Copy link
Member

aajisaka commented May 7, 2022

Tested and it looks good to me. Thanks.

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.

3 participants