Skip to content

Send X-CS-CLI header and Enhance prompt for Response mode - #169

Merged
chhavi-mandowara-cstk merged 4 commits into
stagingfrom
development
Jun 2, 2026
Merged

chhavi-mandowara-cstk merged 4 commits into
stagingfrom
development

Conversation

@chhavi-mandowara-cstk

Copy link
Copy Markdown
Contributor

fix: send populated X-CS-CLI header from launch commands at runtime
feat: prompt for streaming/buffered response mode via text input

@chhavi-mandowara-cstk
chhavi-mandowara-cstk requested review from a team as code owners June 2, 2026 13:04
@github-actions

github-actions Bot commented Jun 2, 2026

Copy link
Copy Markdown

🔒 Security Scan Results

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

Check Type Count (with fixes) Without fixes Threshold Result
🔴 Critical Severity 0 0 10 ✅ Passed
🟠 High Severity 0 0 25 ✅ Passed
🟡 Medium Severity 0 0 500 ✅ Passed
🔵 Low Severity 0 0 1000 ✅ Passed

⏱️ SLA Breach Summary

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

Severity Breaches (with fixes) Breaches (no fixes) SLA Threshold (with/no fixes) Status
🔴 Critical 0 0 15 / 30 days ✅ Passed
🟠 High 0 0 30 / 120 days ✅ Passed
🟡 Medium 0 0 90 / 365 days ✅ Passed
🔵 Low 0 0 180 / 365 days ✅ Passed

✅ BUILD PASSED - All security checks passed

Copilot AI 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 ensures the X-CS-CLI header is reliably populated at runtime (even when context.analyticsInfo isn’t available) and improves the interactive UX for choosing buffered vs streaming response mode.

Changes:

  • Added getAnalyticsInfo() helper to reconstruct analytics info from oclif config + persisted config store values, and used it to populate X-CS-CLI headers and adapter inputs.
  • Updated GitHub and FileUpload adapters to prompt for response mode via a validated text input (s/b or streaming/buffered) instead of a confirm prompt.
  • Added/updated unit tests for analytics reconstruction and response-mode prompting behavior; bumped package version to 1.10.1 and refreshed lockfile.

Reviewed changes

Copilot reviewed 10 out of 11 changed files in this pull request and generated no comments.

Show a summary per file
File Description
test/unit/util/common-utility.test.ts Adds unit coverage for getAnalyticsInfo() reconstruction and fallbacks.
src/util/common-utility.ts Introduces getAnalyticsInfo() and exports it for use by commands/base command.
src/commands/launch/index.ts Passes reconstructed analytics info into adapters and precheck inputs.
src/base-command.ts Ensures GraphQL headers and CMA SDK init use reconstructed X-CS-CLI value.
src/adapters/github.ts Replaces confirm prompt with validated input prompt for response mode selection.
src/adapters/github.test.ts Updates tests to match new response mode prompt + adds mapping/validation tests.
src/adapters/file-upload.ts Replaces confirm prompt with validated input prompt for response mode selection.
src/adapters/file-upload.test.ts Updates tests to match new response mode prompt + adds mapping/validation tests.
package.json Bumps package version to 1.10.1.
package-lock.json Updates lockfile for version bump and dependency refresh.
.talismanrc Updates checksum to reflect the new package-lock.json.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@chhavi-mandowara-cstk
chhavi-mandowara-cstk merged commit 864fd64 into staging Jun 2, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

5 participants