Skip to content

Conversation

@shuv1337
Copy link
Collaborator

@shuv1337 shuv1337 commented Jan 14, 2026

Summary

  • Merge upstream tag v1.1.20 into shuvcode-dev
  • Resolve conflicts in provider dialog, tips, VSCode package metadata, and bun.lock
  • Record sync marker update and add Anthropic prompt branding entry in fork features

Testing

  • Not run (merge-only sync)

Greptile Summary

This PR successfully merges upstream tag v1.1.20 into the shuvcode-dev fork, bringing significant feature updates including provider connection status tracking, enhanced session filtering, improved permissions handling, and new plugin capabilities. The merge involved resolving conflicts in the provider dialog, tips system, VSCode package metadata, and dependency lock files. All conflict resolutions appear correct, with the fork preserving its custom branding (Shuvcode ASCII logo) while integrating upstream improvements.

Key Changes:

- **Provider Dialog Enhancement**: Added visual feedback showing which providers are currently connected via a "Connected" footer indicator - **Session Management**: New `directory` and `roots` query parameters enable filtering sessions by project directory and root-only sessions - **Permissions System**: Updated agent configuration to properly authorize external directory access for plan files - **Plugin API**: Extended tool context with `metadata()` and `ask()` methods for enhanced plugin capabilities - **Database Migrations**: Added `time_subscription_booked` timestamp and `subscription_plan` enum for billing improvements - **Console Branding**: New BlackLayout component for console homepage with GitHub integration - **Skills Configuration**: SDK now supports registries configuration for managing skill sources - **Code Quality**: Documentation improvements to auth info endpoint descriptions and refactored variable naming for clarity

Confidence Score: 5/5

  • This PR is safe to merge with no identified issues
  • This is a straightforward upstream merge with clean conflict resolutions. All changes are well-structured: new features are additive, database migrations are simple schema additions, permission updates properly use path utilities, and generated SDK types are correctly maintained. The fork successfully preserves its custom features (Shuvcode branding) while integrating upstream improvements. No breaking changes, no security vulnerabilities, and no logical errors detected across 68 modified files.
  • No files require special attention

Important Files Changed

Filename Overview
packages/opencode/src/cli/cmd/tui/component/dialog-provider.tsx Dialog provider component updated to track connected provider status via connected memo and display status in footer. Code formatting improved with consistent indentation. No logical issues detected; proper handling of OAuth authorization flow.
packages/opencode/src/server/server.ts Session list endpoint enhanced with directory and roots query parameters for filtering. Auth info endpoint documentation improved. Variable naming refactored (oauthAuthoauth) for consistency. API documentation descriptions enhanced. No logic issues detected.
packages/opencode/src/agent/agent.ts Agent permissions configuration updated to allow external directory access for plan files and improve edit permissions for plan markdown files. Uses proper path resolution with path.join() and path.relative(). No logic issues detected.
packages/sdk/js/src/v2/gen/types.gen.ts Generated TypeScript types updated with new session list query parameters and skills configuration support. New AuthInfoData and related types added for auth information endpoint. All changes are additive with no breaking modifications to existing types.
packages/console/app/src/routes/black.tsx New BlackLayout component created for console branding page featuring header, hero section, SVG graphics, and footer with GitHub stars integration. Properly uses Solid.js utilities (createAsync, createMemo). CSS imports and layout structure properly implemented.
packages/console/core/migrations/0051_jazzy_green_goblin.sql Migration adds time_subscription_booked timestamp column to billing table for tracking subscription booking time. Simple schema alteration with no data implications.
packages/console/core/migrations/0052_aromatic_agent_zero.sql Migration adds subscription_plan enum column to billing table with values ('20','100','200'). Properly structured enum for plan tiers without data safety concerns.

Sequence Diagram

sequenceDiagram
    participant User
    participant TUI as TUI Dialog
    participant SDK as SDK Client
    participant Server
    participant Provider

    User->>TUI: Select provider to connect
    TUI->>TUI: Create dialog with connected status
    User->>TUI: Choose authentication method
    alt OAuth Method
        TUI->>SDK: Call provider.oauth.authorize
        SDK->>Server: POST /provider/oauth/authorize
        Server->>Provider: OAuth authorization request
        Provider-->>Server: Authorization code
        Server-->>SDK: Return code/auto method
        SDK-->>TUI: Display OAuth flow
    else API Key Method
        TUI->>TUI: Show ApiMethod dialog
        User->>TUI: Enter API key
        TUI->>SDK: Store API key
    end
    
    Server->>Server: Filter sessions by directory/roots
    Server->>Server: Return filtered session list
    
    Note over Server,Provider: New session filtering and auth metadata endpoints
Loading

fwang and others added 30 commits January 13, 2026 13:36
actions-user and others added 29 commits January 14, 2026 00:59
- PR created at #298
- Fix includes: write token refresh to openai provider ID, fallback to legacy codex entry
- Tests pass (744 pass, 1 skip, 0 fail)
- Add test confirming minimal OAuth results (without optional email, name,
  plan, orgName fields) persist correctly in auth storage
- All new metadata fields are optional in plugin types and auth schema
- Provider auth handler uses conditional checks before setting optional fields
- Verify 745 pass, 1 skip, 0 fail
The extractUserInfo function is already implemented in codex.ts:92-105.
It parses id_token, extracts email, name, and accountId from claims,
and returns a UserInfo object. All tests pass.
OAuth callback already calls extractUserInfo(tokens) after token exchange and includes email, name, accountId in the success payload.
normalizePlanType function maps plan values to standardized tiers (free, plus, pro, team, enterprise, unknown) and handles case variations.
…adata

- Added endpoint in server.ts that returns auth metadata (authenticated, type, email, plan, accountId)
- Returns 404 with authenticated: false if provider not found
- Generated openapi.json with new endpoint definition
- Regenerated SDK with auth.info method and types (AuthInfoData, AuthInfoResponses)
- Updated prd.json to mark SDK generation tasks as complete
- Tests pass: 745 pass, 1 skip, 0 fail
- Marked "Merge PR before starting Phase 1" as complete (PR #298 already merged)
- Updated verification steps for auth.info endpoint implementation
- Verified migration copies codex to openai, Auth.remove('codex') available for manual cleanup
- Removal is intentionally manual to prevent data loss if migration fails
- Verified fetchChatGPTUserInfo background task at codex.ts:606-632
- Task spawns via 'void updatePlan().catch(() => {})' - non-blocking
- Updates auth metadata via auth.set when plan/orgName retrieved
- OAuth success returns immediately regardless of background task result
- Verified manifest.ts exists with InstalledSkill and SkillManifest interfaces
- Implements loadManifest, saveManifest, getInstalled, addInstalled, removeInstalled
- Used by skill installer to track installed skills and their metadata
- Verified skill/index.ts exists with SkillIndex interface and caching logic
- Implements loadIndex (cache with TTL), buildIndex (fetch and write), search (fuzzysort)
- Verified skill/installer.ts exists with installSkill and uninstallSkill functions
- Copies skill files to SKILLS_DIR and updates manifest with installed metadata
- Verified skill/fetcher/github.ts exists with 200 lines implementing git and tarball fetching
- fetchRegistry() entry point with hasGit() check and tarball fallback
- scanSkills() walks directories matching SKILL.md globs with minimatch
- parseSkillFile() extracts YAML frontmatter for skill metadata
- Verified skill/fetcher/clawdhub.ts exists with stub fetchRegistry returning []
- Verified skill/fetcher/url.ts exists with stub fetchRegistry returning []
- Both are TODO stubs awaiting API contract confirmation and implementation
Resolved conflicts:
- bun.lock (kept fork lockfile)
- packages/opencode/src/cli/cmd/tui/component/dialog-provider.tsx (merged provider status info)
- packages/opencode/src/cli/cmd/tui/component/tips.tsx (kept shuvcode tips)
- sdks/vscode/package.json (kept shuvcode branding, bumped version)
@shuv1337 shuv1337 merged commit 5b136fe into shuvcode-dev Jan 15, 2026
2 checks passed
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.