Skip to content

Stop deployment log polling after cancellation, Update configuration in rollback command and Update snyk vulnerabilities - #222

Open
chhavi-mandowara-cstk wants to merge 10 commits into
mainfrom
staging
Open

Stop deployment log polling after cancellation, Update configuration in rollback command and Update snyk vulnerabilities#222
chhavi-mandowara-cstk wants to merge 10 commits into
mainfrom
staging

Conversation

@chhavi-mandowara-cstk

Copy link
Copy Markdown
Contributor

fix: stop deployment log polling after cancellation
fix: ensure Apollo client is rebuilt after configuration update in rollback command (csdx launch:rollback)
chore: pin brace-expansion and fast-uri via npm overrides to resolve Snyk vulnerabilities
chore: pin js-yaml via npm override to resolve Snyk high-severity finding

AryanBansal-launchand others added 10 commits July 24, 2026 16:19
deploymentStatus terminal-state list was missing CANCELLED, so
csdx launch:logs kept polling the deployment-status and
deployment-logs queries indefinitely after a deployment was
cancelled.
Co-Authored-By: Rohan Agrawal <rohan.agrawal@contentstack.com>
…llback command (csdx launch:rollback)
- Added a call to prepareApiClients() after getConfig() to ensure the Apollo client has the correct project and organization headers based on the latest configuration.
…og-polling
fix: stop deployment log polling after cancellation
…Snyk vulnerabilities
Adds scoped npm overrides to patch two High-severity Snyk findings without
bumping @oclif/core or @contentstack/cli-utilities to a new major version:
- brace-expansion: patched in place per minimatch parent (5.0.7 -> 5.0.9 under
minimatch@10.2.5, 2.1.2 -> 2.1.4 under minimatch@9.0.9/5.1.9) since the tree
carries three brace-expansion major lines at once and a flat override would
force one version onto all of them.
- fast-uri: 3.1.3 -> 3.1.5 (single instance, via cli-utilities > conf > ajv).
Verified with npm install, npm run build, npm test, and a clean re-scan
(snyk test: 0 vulnerable paths, was 4 issues / 23 paths).
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
…ding
js-yaml@4.3.0 (pulled in transitively via @contentstack/cli-utilities,
eslint-config-oclif, and mocha) is affected by SNYK-JS-JSYAML-18593780
(Inefficient Algorithmic Complexity, High severity), fixed in 4.3.1.
All declared ranges (^4.1.0 etc.) already permit the patch bump, so a
flat override is enough — no code changes required.
Updates the .talismanrc checksum for package-lock.json to match the
new lockfile hash (Talisman's secret scanner flags dependency hash
changes for review).
Verified with npm ci, npm run build, npm test, and a clean re-scan
(snyk test: 0 vulnerable paths, was 1 issue / 2 vulnerable paths).
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
chore:upgrade launch-cli package version
Stop deployment log polling after cancellation, Update configuration in rollback command and Update snyk vulnerabilities
CopilotAI lite review requested due to automatic review settings August 14, 2026 17:13
@snyk-io

snyk-ioBot commented Aug 14, 2026

Copy link
Copy Markdown

Snyk checks have passed. No issues have been found so far.

StatusScan Engine Critical High Medium LowTotal (0)
Open Source Security0000 0 issues
Licenses0000 0 issues
Code Security0000 0 issues

💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse.

@github-actions

Copy link
Copy Markdown

🔒 Security Scan Results

ℹ️ Note: Only vulnerabilities with available fixes (upgrades or patches) are counted toward thresholds.

Check TypeCount (with fixes)Without fixesThresholdResult
🔴 Critical Severity0010✅ Passed
🟠 High Severity0025✅ Passed
🟡 Medium Severity00500✅ Passed
🔵 Low Severity001000✅ Passed

⏱️ SLA Breach Summary

✅ No SLA breaches detected. All vulnerabilities are within acceptable time thresholds.

SeverityBreaches (with fixes)Breaches (no fixes)SLA Threshold (with/no fixes)Status
🔴 Critical0015 / 30 days✅ Passed
🟠 High0030 / 120 days✅ Passed
🟡 Medium0090 / 365 days✅ Passed
🔵 Low00180 / 365 days✅ Passed

✅ BUILD PASSED - All security checks passed

CopilotAI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull request overview

This PR updates deployment lifecycle handling so polling and command flows react correctly to cancelled deployments, refreshes API clients after rollback config changes, and applies npm overrides intended to address reported Snyk vulnerabilities.

Changes:

  • Treat CANCELLED as a terminal deployment status and ensure log polling stops accordingly.
  • Exit with failure for cancelled deployments in adapters, with added Jest coverage.
  • Update rollback command to rebuild Apollo clients after config updates; bump package version and add security-related npm overrides.

Reviewed changes

Copilot reviewed 9 out of 10 changed files in this pull request and generated 4 comments.

Show a summary per file
FileDescription
src/util/logs-polling-utilities.test.tsAdds regression tests ensuring polling stops when deployment status becomes CANCELLED.
src/config/index.tsAdds CANCELLED to the default list of terminal deployment statuses.
src/commands/launch/rollback.tsRebuilds API clients after getConfig() in rollback flow.
src/adapters/github.tsTreats CANCELLED like FAILED (exit code 1 after log viewing).
src/adapters/github.test.tsAdds test coverage for CANCELLED deployment handling (new-project path).
src/adapters/file-upload.tsTreats CANCELLED like FAILED (exit code 1 after log viewing).
src/adapters/file-upload.test.tsAdds test coverage for CANCELLED deployment handling (new-project path).
package.jsonBumps version and adds npm overrides to address vulnerabilities.
.talismanrcUpdates checksum for package-lock.json ignore entry.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment threadsrc/commands/launch/rollback.ts
Comment threadpackage.json
Comment threadsrc/adapters/github.test.ts
Comment threadsrc/adapters/file-upload.test.ts
Sign up for freeto 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.

7 participants

@chhavi-mandowara-cstk@Harshi-Shah-CS@SakshiKoli-CS@AryanBansal-launch@tejas-contentstack@rohan-agrawal-cs