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

Support Kotlin for public beta #1370

Merged
merged 15 commits into from
Nov 17, 2022
Merged

Conversation

angelapwen
Copy link
Contributor

@angelapwen angelapwen commented Nov 15, 2022

Kotlin will enter public beta with the release of 2.11.4. This change:

  • adds it to the list of languages that a user could specify in the init action, aliasing it to Java.
  • checks in Kotlin test code and a Kotlin build command to our test custom build, so that its extraction and autobuild will be tested along with existing Kotlin tests
  • adds support for a feature flag, disable_kotlin_analysis_enabled, that will allow us to mass-enable the CODEQL_EXTRACTOR_JAVA_AGENT_DISABLE_KOTLIN flag (ie. disable Kotlin extraction). The flag is not yet implemented on github.com so the code is a no-op at the moment.

Merge / deployment checklist

  • Confirm this change is backwards compatible with existing workflows.
  • Confirm the readme has been updated if necessary.
  • Confirm the changelog has been updated if necessary.

Copy link
Contributor

@adityasharad adityasharad left a comment

Choose a reason for hiding this comment

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

Nice. Thank you for looking into this!

src/feature-flags.ts Outdated Show resolved Hide resolved
src/languages.ts Show resolved Hide resolved
@angelapwen
Copy link
Contributor Author

I decided to remove the PR check that tests that when the CODEQL_EXTRACTOR_JAVA_AGENT_DISABLE_KOTLIN option is passed to the CLI, analysis will fail — when it's disabled, our Java analysis actually is able to still run off of the Java test code checked in. I think it's probably not necessary to test here as it should be tested in the CLI.

@angelapwen angelapwen marked this pull request as ready for review November 16, 2022 17:57
@angelapwen angelapwen requested a review from a team as a code owner November 16, 2022 17:57
henrymercer
henrymercer previously approved these changes Nov 16, 2022
Copy link
Contributor

@henrymercer henrymercer left a comment

Choose a reason for hiding this comment

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

An optional comment, otherwise LGTM

src/feature-flags.ts Outdated Show resolved Hide resolved
tests/multi-language-repo/main.kt Outdated Show resolved Hide resolved
henrymercer
henrymercer previously approved these changes Nov 16, 2022
@angelapwen
Copy link
Contributor Author

I am updating the feature flag name to include _cli because the code scanning experiences team has another similar-sounding Kotlin feature flag in the monolith repo. Sorry, needs re-review again!

src/feature-flags.ts Outdated Show resolved Hide resolved
@angelapwen angelapwen merged commit 4fddc51 into github:main Nov 17, 2022
@angelapwen angelapwen deleted the kotlin-support branch November 17, 2022 18:48
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