Skip to content

Fix interceptor auth injection on Windows#3499

Open
Netzhangheng wants to merge 2 commits intocode-yeongyu:devfrom
Netzhangheng:fix/windows-auth-interceptor-binding
Open

Fix interceptor auth injection on Windows#3499
Netzhangheng wants to merge 2 commits intocode-yeongyu:devfrom
Netzhangheng:fix/windows-auth-interceptor-binding

Conversation

@Netzhangheng
Copy link
Copy Markdown

@Netzhangheng Netzhangheng commented Apr 18, 2026

Summary

  • fix server auth interceptor injection to preserve the interceptor instance binding
  • avoid calling the interceptor use method without its receiver
  • unblock plugin initialization on Windows when auth injection reaches the interceptor path

Validation

  • reproduced the his._fns failure from the packaged plugin on Windows
  • applied the equivalent source fix in src/shared/opencode-server-auth.ts
  • ran bun run typecheck
  • ran bun run build
  • verified locally that the packaged plugin no longer throws the interceptor binding error during initialization

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Apr 18, 2026

All contributors have signed the CLA. Thank you! ✅
Posted by the CLA Assistant Lite bot.

Copy link
Copy Markdown

@cubic-dev-ai cubic-dev-ai Bot left a comment

Choose a reason for hiding this comment

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

No issues found across 1 file

Confidence score: 5/5

  • Automated review surfaced no issues in the provided summaries.
  • No files require special attention.

Auto-approved: Fixes a standard JS context binding bug by ensuring the 'use' method is called with its receiver. This is a low-risk, 1-line fix for a reported runtime error.

@Netzhangheng
Copy link
Copy Markdown
Author

I have read the CLA Document and I hereby sign the CLA

github-actions Bot added a commit that referenced this pull request Apr 18, 2026
Copy link
Copy Markdown

@cubic-dev-ai cubic-dev-ai Bot left a comment

Choose a reason for hiding this comment

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

0 issues found across 1 file (changes from recent commits).

Auto-approved: Fixes a binding error by correctly setting the 'this' context for the interceptor's 'use' method, resolving a reported runtime failure on Windows with minimal risk.

This was referenced Apr 24, 2026
This was referenced Apr 26, 2026
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.

1 participant