-
Notifications
You must be signed in to change notification settings - Fork 349
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
Add a way to bypass the toolcache for kotlin and swift #1394
Conversation
I don't think this requires a change note. |
This works by moving the logic to check for toolcache bypass out of creating the codeql instance. The logic now _may_ perform an API request in order to check what languages are in the repository. This check is redundant because the same call is being made later in the action when the actual list of languages is calculated.
476358e
to
f79028a
Compare
I'm going to add a few more tests here since this logic is getting tricky. |
I think I addressed all comments, added more tests, and fixed the bug I found. Hopefully, all tests will pass. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One more suggestion, otherwise looks reasonable. I will let Henry or Angela do a more detailed review however.
b36411b
to
99d2473
Compare
99d2473
to
ad7ca9b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This generally looks great.
Some questions:
- Should we revert this change once the next release is fully rolled out and we no longer need to bypass the toolcache for Kotlin / Swift? It does look like there's some complexity here that we wouldn't want to keep around.
- Do we want to add a PR check that runs some integration tests, or are we happy with the unit tests here? Personally I'd be ok with unit tests here plus some manual testing.
If a user explicitly includes java in their language inputs, always make an api call to check for kotlin in the repo. Also, add some suggestions from code reviews.
fede016
to
102e01d
Compare
This works by moving the logic to check for toolcache bypass out of
creating the codeql instance. The logic now may perform an API request
in order to check what languages are in the repository. This check is
redundant because the same call is being made later in the action when
the actual list of languages is calculated.
Commit-by-commit review is suggested.
Even though it is inefficient to add this extra API call, I am leaning towards leaving it in because refactoring to perform only one API call would make the code messier, I ensure that the extra API call is made only if necessary, and we expect that this workaround will be temporary.
Merge / deployment checklist