Skip to content

fix(plugin-i18next): restore T/FT/resolveKey/resolveUserKey shims and release the v5 peer range - #116

Merged
kodiakhq[bot] merged 1 commit into
mainfrom
claude/serene-newton-dl8o9k
Sep 26, 2026
Merged

kodiakhq[bot] merged 1 commit into
mainfrom
claude/serene-newton-dl8o9k

Conversation

@RedStar071

@RedStar071 RedStar071 commented Sep 26, 2026 •

Copy link
Copy Markdown
Member

🔗 Linked issue

Resolves #114
Resolves #115

🧭 Context

📚 Description

  • plugin-i18next: T, FT, resolveKey and resolveUserKey are not exported, contrary to the migration guide #114: the new src/lib/compat.ts restores T, FT, resolveKey and resolveUserKey, plus the TypedT and TypedFT types. Their signatures match @wolfstar/[email protected], the last release that still shipped these helpers, and they are all re-exported from the package index.

    • Every export is marked @deprecated, and its doc comment points to the replacement.
    • At runtime, T and FT return the key unchanged. resolveKey and resolveUserKey delegate to getSupportedLanguageT and getSupportedUserLanguageT.
    • They accept any Target, not only an Interaction, so all old call sites still type-check.

    The branded-key API stays deprecated in favour of typed plain keys. The shims only make the migration a module-specifier rename again, as the guide promises. The README migration section now says this.

  • plugin-i18next: latest release does not accept @wolfstar/http-framework v5 as a peer #115: adds a patch changeset for the peer range, so the next release carries it with a changelog entry. It reaches npm latest once the chore: update changelog and release PR opened by changesets/action is merged.

Key changes

Before After
import { T } from '@wolfstar/plugin-i18next' SyntaxError at load time works, marked @deprecated
resolveKey(target, key, options) missing delegates to getSupportedLanguageT(target, key, options)
resolveUserKey(target, key, options) missing delegates to getSupportedUserLanguageT(target, key, options)
@wolfstar/http-framework peer on npm latest ^3.1.0 ^3.1.0 || ^5.0.0 in the next release

Tests: the new packages/plugin-i18next/tests/compat.test.ts checks that the four helpers are exported. It also checks that T/FT return the key unchanged, that resolveKey/resolveUserKey resolve the guild's and the user's language (including interpolation), and that the positional defaultValue works.

Changesets:

  • @wolfstar/plugin-i18next, minor: the restored exports.
  • @wolfstar/plugin-i18next, patch: the v5 peer range.

Type of Change

  • New feature (non-breaking change which adds functionality)
  • Bug fix (non-breaking change which fixes an issue)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation change
  • Workflow / CI change

Pre-flight Checklist

  • I have read the Contributing Guidelines (if applicable)
  • My code follows the code style of this project
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes (pnpm lint, pnpm build, pnpm typecheck and pnpm test pass: 427 tests)
  • I have updated the documentation accordingly (packages/plugin-i18next/README.md migration sections)
  • I added a changeset with pnpm changeset (or pnpm changeset add --empty if no release is needed). See .changeset/README.md.

Note

@wolfstar/plugin-api, @wolfstar/plugin-logger and @wolfstar/plugin-subcommands-advanced have the same release gap as #115: their v5 peer range is on main but has no pending changeset. They are left out of this PR to keep it scoped to plugin-i18next.

🤖 Generated with Claude Code

https://claude.ai/code/session_01DE7qshA3oa1qYHFEhago9F

… release v5 peer range

- export `T`, `FT`, `resolveKey`, `resolveUserKey`, `TypedT` and `TypedFT` again as
  deprecated shims with http-framework-i18n's signatures, so migrated projects no
  longer fail at load time (#114)
- add a changeset for the `@wolfstar/http-framework` `^3.1.0 || ^5.0.0` peer range,
  so the next stable release carries it (#115)

Closes #114
Closes #115

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01DE7qshA3oa1qYHFEhago9F
@coldtea-pr-lens

coldtea-pr-lens Bot commented Sep 26, 2026 •

Copy link
Copy Markdown

◈ PR Lens

🟢 +1 new · 🟠 ~0 changed · 🔴 -0 removed · 1 flow · 2 files · commit 2eaaefd


Architecture

Architecture diagram for wolfstar-project/plugins at 2eaaefd

1 component touched across 3 lanes.

Play the interactive walkthrough


Data flow

Data flow diagram for wolfstar-project/plugins at 2eaaefd

Resolving a key through compatibility shim

Follow each request, response and payload


View

  • Architecture lens
  • Data flow lens
  • Expand every detail

Tip

Add .github/workflows/pr-lens.yml with coldteadotai/pr-lens/packages/action@v0 and your model provider's key as its api-key to run PR Lens from your own CI. Any /chat/completions endpoint works

🪧 More tips
  • Run npx skills add coldteadotai/pr-lens, then tell your coding agent: "Diagram the change you just made with PR Lens and attach it to the pull request."
  • Run npx @coldtea/pr-lens-cli analyze --base origin/main on a branch, then npx @coldtea/pr-lens-cli render .pr-lens/graph.json. Same lenses, your own model key, before the pull request exists
  • Untick Architecture lens or Data flow lens under View to hide a diagram, or tick Expand every detail to open every section. The comment redraws in a few seconds
  • Click the link under each diagram to open it on a canvas you can zoom, pan and step through
  • The diagrams are links. Click one to open it on the canvas, then press W or click play to walk through the change
  • Open a diagram on the canvas, then press W or click play to walk through the change one step at a time
  • The CLI's render reads .github/pr-lens.yml and applies your renames, exclusions and lane pins at draw time
  • Set github.comment.collapsed: true in .github/pr-lens.yml to fold the comment behind one View architecture and data flow row. Drawing still runs as before
  • Set github.draw: on-demand in .github/pr-lens.yml and PR Lens stops drawing pull requests on its own. Comment @pr-lens draw on a pull request when you want that one drawn
  • Push a commit and the drawing stays, with a note that it is out of date. Tick Redraw in the note to draw the new head
  • Switch GitHub to dark mode and the diagrams follow. The moving dots are this pull request's data in motion

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

❤️ Share

@RedStar071 RedStar071 changed the title fix(plugin-i18next): restore T/FT/resolveKey/resolveUserKey shims and… fix(plugin-i18next): restore T/FT/resolveKey/resolveUserKey shims and release the v5 peer range Sep 26, 2026

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

✅ No new issues found.

Reviewed changes

Restores previously removed exports for backwards compatibility during migration and documents an already-shipped peer-dependency widening.

  • packages/plugin-i18next/src/lib/compat.ts (new): re-exports T, FT, TypedT, TypedFT, resolveKey, resolveUserKey as deprecated shims, delegating to getSupportedLanguageT/getSupportedUserLanguageT.
  • src/index.ts: wires the new module into the package barrel via export * from "./lib/compat".
  • tests/compat.test.ts (new): 5 tests covering the barrel export surface, key branding, and resolveKey/resolveUserKey resolution (including a missing-key default-value case) against fixture locale files.
  • README.md: updates the migration guide to describe these helpers as deprecated-but-present rather than fully removed.
  • Two changesets: a minor bump for the restored exports (#114) and a patch documenting the @wolfstar/http-framework": "^3.1.0 || ^5.0.0" peer range (#115).

I ran the new test suite (npx vitest run packages/plugin-i18next/tests/compat.test.ts, 5/5 pass) and tsc --noEmit on the package (clean). I also traced git history: the shim signatures and JSDoc in compat.ts are a byte-for-byte restoration of the implementation removed in 33d1278 (#57), not a blind reimplementation, so migrated callers written against the pre-#57 API will actually work unchanged. There's no export-name collision with ./lib/functions/./lib/types. The peer-dependency changeset documents a range that was already present in package.json since the package's creation and isn't duplicated by any existing changeset, so it's a legitimate retroactive addition rather than redundant.

Pullfrog  | View workflow run | Using Claude Sonnet | 𝕏

@kodiakhq
kodiakhq Bot merged commit 56ead81 into main Sep 26, 2026
24 of 28 checks passed
@kodiakhq
kodiakhq Bot deleted the claude/serene-newton-dl8o9k branch September 26, 2026 14:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

2 participants