Skip to content

Allow generator to continue even if any errors encountered in fetch comparison #736

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

Closed

Conversation

carabasdaniel
Copy link

This PR fixes issue: #665

There might be a more elegant solution to catch only StandardError instead of the general Exception but I think this should ensure that the change log is generated in most cases even through various errors encountered by the fetcher.

@ferrarimarco
Copy link
Contributor

Hi @carabasdaniel !

Thanks for this PR.

Can you please also provide test cases?

@carabasdaniel
Copy link
Author

Hi @ferrarimarco, I've added two unit tests and amended the commit.

@hzxuzhonghu
Copy link

Any update

@hzxuzhonghu
Copy link

I met similar error

/usr/local/bundle/gems/octokit-4.14.0/lib/octokit/response/raise_error.rb:16:in `on_complete': GET https://api.github.com/repos/volcano-sh/volcano/compare/d454490cca88891c1ca8b1a85c4506d115574a21...v0.1: 404 - No common ancestor between d454490cca88891c1ca8b1a85c4506d115574a21 and v0.1. // See: https://developer.github.com/v3/repos/commits/#compare-two-commits (Octokit::NotFound)

@genebean
Copy link

@ferrarimarco any update on this PR?

@ferrarimarco
Copy link
Contributor

Hi. I'm thinking about the best strategy here. While this PR let you have a changelog, it may be an issue it silently fails during a CI build where you automatically generate the changelog.

@skywinder
Copy link
Member

Thanks, @carabasdanie.
The points of @ferrarimarco are valid.

In order to not change standard behavior we can implement this behavior with a special flag, like --continue-with-errors

@carabasdaniel
Copy link
Author

Hi @ferrarimarco @skywinder,

Added an option for continue_with_errors and rebased to latest master. Extracted add tag to pull request for rubocop complexity in generator fetcher.

@olleolleolle
Copy link
Collaborator

(This code will have some movement under it, as we're waiting on #784 to land, which makes changes in the same places.)

@ferrarimarco
Copy link
Contributor

@carabasdaniel can you rebase against the latest master?

@carabasdaniel
Copy link
Author

Hi @ferrarimarco,

Rebased but had to remove the initially added unit tests as they were no longer valid.

Copy link
Collaborator

@olleolleolle olleolleolle left a comment

Choose a reason for hiding this comment

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

I made a comment about code that made me curious.

@BogdanIrimie
Copy link

Have the same problem as @hzxuzhonghu would love to see this PR merged!

@daianamezdrea
Copy link

Same problem here...any updates about this PR?

@tillchen
Copy link

👍

@tillchen
Copy link

This will be so helpful. Since the tool breaks because of a parent-less commit.

@ilopmar
Copy link

ilopmar commented Oct 13, 2020

We've also hit this issue. Any updates about when this can be merged? Thanks :)

@olleolleolle
Copy link
Collaborator

The blocker is an unmet note above:

the continue_with_errors setting is mostly "read" at the beginning, then no more is done with it.

And, I can not find any test code which does things with this new setting.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.