Skip to content

Spec: document params.locale on lpp/check and lpp/compile #42

Closed

Description

@e54-bot

opy-provider (wrightkit/opy-provider#2) and wright's LPP client (wright/crates/wright-lpp/src/provider.rs ~line 613) both use a params.locale field on lpp/check / lpp/compile to select the provider's source/output language (e.g. "en-US", "zh-CN"). Wright's --locale flag already depends on it.

The field is protocol-visible but absent from docs/spec/*: §6 (params) and §8 (check/compile) never mention locale. Any provider-visible field needs normative spec coverage (§19 rule 1), so this is a spec ownership decision:

  • Add locale?: string to the check/compile params with defined semantics (BCP-47 tag; absent = provider default; unknown values → provider-defined fallback vs. invalidParams), or
  • Decide that language selection is out of LPP scope and remove the field from both sides.

Either way, providers and clients should converge on the spec, not silently diverge.

Activity

  1. e54-bot commented on Oct 20, 2026

    @e54-bot
    ContributorAuthor

    Reopened: #96 was merged with a squash message that kept the first commit's Fixes #42, which closed this issue by mistake. #96 documents params.locale as implemented, but it intentionally leaves the open question of this issue undecided: provider-defined fallback versus invalidParams for a locale the provider does not serve. That decision is still needed. Also noted from review: locale is the Workshop client locale, not the source language.

  2. e54-bot commented on Oct 20, 2026

    @e54-bot
    ContributorAuthor

    Closing. #96 documents params.locale as implemented, and the spec now says that behavior for a locale the provider does not serve is provider-defined. The remaining question (provider-defined fallback versus invalidParams) is deferred: only the opy provider serves locales today, and its locale-unsupported diagnostic is implemented in opy-rs's opy-provider crate. Open a new issue if a protocol-wide rule becomes necessary.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions