Skip to content

Fixed "OpenAI-compatible API" connection type being reset to "Claude-compatible API" on the Default profile - #194

Merged
oleg68 merged 3 commits into
nbplugins:mainfrom
oleg68:bugfix/issue-191-default-profile-connection-type
Oct 16, 2026
Merged

oleg68 merged 3 commits into
nbplugins:mainfrom
oleg68:bugfix/issue-191-default-profile-connection-type

Conversation

@oleg68

@oleg68 oleg68 commented Oct 16, 2026

Copy link
Copy Markdown
Collaborator

Resolves #191

Summary

  • The Default profile was rebuilt from stored settings field by field and openaiProxy was not copied, so the type was re-derived as "Claude-compatible API". Named profiles were unaffected.
  • The connection type is now persisted explicitly (connectionType enum); the Default profile is deserialised as a whole, so no field can be forgotten.
  • Settings written by older versions (legacy openaiProxy / openaiSubscription flags, no connectionType) are still read; settings are always written in the new format.

Test plan

  • Regression test written first and confirmed failing on old code (expected OPENAI_PROXY but was OTHER_API)
  • ClaudeProfileStoreConnectionTypeTest: Default/Custom × old/new settings × all connection types, edge cases, lossless write
  • mvn package — 1125 tests, 0 failures
  • Manual: old Default with OpenAI-compatible API shows the right type after upgrade; all types survive reopen/restart

🤖 Generated with Claude Code

…compatible API" on the Default profile (nbplugins#191)

Resolves: nbplugins#191

The Default profile was rebuilt from stored settings by copying fields one
by one, and the openaiProxy flag was not copied, so the connection type was
re-derived as OTHER_API. The connection type is now stored explicitly as
connectionType; the Default profile is deserialised as a whole like named
profiles. Settings written by older versions (legacy openaiProxy /
openaiSubscription flags, no connectionType) are still read and the type is
derived from them; settings are always written in the new format.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@oleg68

oleg68 commented Oct 16, 2026

Copy link
Copy Markdown
Collaborator Author

@codex review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 16, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-16T19:49:56.016509Z 6267a5c Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector 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.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 17386a36eb

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Copy Profile copied only token, apiKey and baseUrl, so with the connection
type now stored explicitly a copy of a profile whose type is not inferable
from its credentials (e.g. Other API before a key is entered, or OpenAI
profiles) opened as Claude-managed. Extracted ClaudeProfilesPanel.copyOf()
and made it copy the connection type.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

@chatgpt-codex-connector chatgpt-codex-connector 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.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 8a205c18ed

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

…on profile

copyOf() preserved the connection type but not the chatgpt* OAuth fields, so
a copy of a signed-in ChatGPT Subscription profile was reported as not
signed in and could not start a session.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, you can upgrade your account or add credits to your account and enable them for code reviews in your settings.

@oleg68

oleg68 commented Oct 16, 2026

Copy link
Copy Markdown
Collaborator Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Swish!

Reviewed commit: 6267a5c775

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@oleg68
oleg68 merged commit 3cf9436 into nbplugins:main Oct 16, 2026
3 checks passed
@oleg68
oleg68 deleted the bugfix/issue-191-default-profile-connection-type branch October 16, 2026 19:57
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.

Activate OpenAI-compatible API

1 participant