refactor: remove legacy Snyk Code TypeScript client#6944
Draft
fsargent wants to merge 1 commit into
Draft
Conversation
|
|
|
| Status | Scan Engine | Total (0) | ||||
|---|---|---|---|---|---|---|
| Open Source Security | 0 | 0 | 0 | 0 | See details | |
| Licenses | 0 | 0 | 0 | 0 | See details | |
| ✅ | Code Security | 0 | 0 | 0 | 0 | 0 issues |
💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse.
4b9682c to
9735db7
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Pull Request Submission Checklist
What does this PR do?
Removes the legacy TypeScript Snyk Code implementation backed by
@snyk/code-clientnow that Snyk Code runs through the native Go workflow.This PR:
github.com/snyk/code-client-gotov1.28.0in both public and private Go modules@snyk/code-clientfrompackage.jsonandpackage-lock.jsoncodeecosystem plugin registration from the TypeScript CLI path--codeuse in legacy TS commands fails clearly instead of silently falling back to the removed clientWhere should the reviewer start?
Start with:
src/lib/ecosystems/plugins.tsfor removal from the TypeScript ecosystem registrysrc/cli/commands/test/index.tsfor the explicit legacy TypeScript guardtest/jest/acceptance/snyk-code/snyk-code-integration.spec.tsfor native workflow coveragecliv2/go.modandcliv2-private/go.modfor the native code client upgradeHow should this be manually tested?
Validated locally with:
make formatmake lintmake build BUILD_MODE=privatecd cliv2 && make testnpx jest --runInBand test/jest/unit/ecosystems.spec.ts test/jest/unit/validate-fix-command-is-supported.spec.tsTEST_SNYK_COMMAND=./binary-releases/snyk-macos-arm64 npx jest --runInBand test/jest/acceptance/snyk-code/snyk-code-integration.spec.tscd cliv2 && go test github.com/snyk/code-client-go/pkg/code github.com/snyk/code-client-go/internal/commands/code_workflowWhat's the product update that needs to be communicated to CLI users?
Snyk Code in the packaged CLI now uses the native Go implementation only. There is no intended user-facing command change.
Risk assessment (Low | Medium | High)?
Medium. The intended Snyk Code runtime path is native Go, but this removes a legacy TypeScript implementation and related dependency surface. The PR includes guards and native acceptance coverage to catch accidental fallback into the removed path.