Skip to content

fix(deploy): accept CLI-captured Daytona credentials - #240

Merged
khaliqgant merged 2 commits into
mainfrom
codex/issue-2199-daytona-config-key
Jun 16, 2026
Merged

fix(deploy): accept CLI-captured Daytona credentials#240
khaliqgant merged 2 commits into
mainfrom
codex/issue-2199-daytona-config-key

Conversation

@khaliqgant

@khaliqgant khaliqgant commented Jun 16, 2026

Copy link
Copy Markdown
Member

Summary

  • skip catalog config-key matching for CLI-captured deploy providers such as daytona
  • reuse that rule for runtime credential eligibility checks
  • add regressions for daytona catalog daytona-relay vs credential status daytona

Fixes AgentWorkforce/cloud#2199.

Test Plan

  • pnpm --filter @agentworkforce/persona-kit build
  • pnpm --filter @agentworkforce/deploy test (205 passed)

Merge Plan

I will monitor CI and review comments, address actionable feedback, re-run focused tests after changes, and merge only after the latest PR head is green.

Review in cubic

@coderabbitai

coderabbitai Bot commented Jun 16, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

@khaliqgant, we couldn't start this review because you've reached your PR review rate limit.

More reviews will be available in 48 minutes and 6 seconds. Learn how PR review limits work.

Your organization has used up its prepaid credits, and credit purchases are no longer available. Enable the review add-on in the billing tab to keep reviews running — you're only billed for reviews past your plan's rate limits ($0.25/file).

⌛ How to resolve this issue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available.

Please see our Fair Usage Limits Policy for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: ae0235d1-bba3-4e68-bcec-e3f4c247ae72

📥 Commits

Reviewing files that changed from the base of the PR and between 41f1575 and 06d8d6d.

📒 Files selected for processing (4)
  • packages/deploy/src/connect.test.ts
  • packages/deploy/src/connect.ts
  • packages/deploy/src/deploy.test.ts
  • packages/deploy/src/deploy.ts
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/issue-2199-daytona-config-key

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@gemini-code-assist gemini-code-assist Bot 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.

Code Review

This pull request introduces a helper function resolveExpectedProviderConfigKey to centralize and handle the resolution of expected provider configuration keys, specifically ignoring catalog config keys for CLI-captured providers like Daytona. This helper is integrated into both connectIntegrations and resolveRuntimeCredentialEnv, and corresponding unit tests have been added to verify this behavior. Feedback on the changes suggests refactoring the helper function to use a standard try/catch block with await instead of .catch() to safely handle both synchronous and asynchronous errors.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment on lines +610 to +618
export async function resolveExpectedProviderConfigKey(
provider: string,
providerConfigKeys?: ProviderConfigKeyResolver
): Promise<string | undefined> {
if (!providerConfigKeys || isCliCapturedProvider(provider)) {
return undefined;
}
return providerConfigKeys.resolve(provider).catch(() => undefined);
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

If providerConfigKeys.resolve(provider) throws an error synchronously, the .catch() block will not be evaluated because the error is thrown before the promise is returned and the catch handler is attached. Since this is an async function, the synchronous throw will be caught by the async wrapper and result in a rejected promise, which will propagate to the caller and potentially crash the deployment process.\n\nUsing a standard try/catch block with await is safer and more idiomatic in TypeScript/JavaScript, as it gracefully handles both synchronous throws and asynchronous promise rejections.

export async function resolveExpectedProviderConfigKey(
  provider: string,
  providerConfigKeys?: ProviderConfigKeyResolver
): Promise<string | undefined> {
  if (!providerConfigKeys || isCliCapturedProvider(provider)) {
    return undefined;
  }
  try {
    return await providerConfigKeys.resolve(provider);
  } catch {
    return undefined;
  }
}

@agent-relay-code

Copy link
Copy Markdown
Contributor

pr-reviewer could not complete review for #240 in AgentWorkforce/workforce.
The review harness exited with code 1.
No review was posted; this needs operator attention.

@agent-relay-code

Copy link
Copy Markdown
Contributor

ℹ️ pr-reviewer: review only — no file changes were applied to the PR (nothing to commit after review). The notes below are advisory and were not pushed.

pr-reviewer could not complete review for #240 in AgentWorkforce/workforce.
The review harness exited with code 1.
No review was posted; this needs operator attention.

@agent-relay-code

Copy link
Copy Markdown
Contributor

pr-reviewer could not complete review for #240 in AgentWorkforce/workforce.
The review harness exited with code 1.
No review was posted; this needs operator attention.

@khaliqgant
khaliqgant merged commit 3995aec into main Jun 16, 2026
3 checks passed
@khaliqgant
khaliqgant deleted the codex/issue-2199-daytona-config-key branch June 16, 2026 12:01
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