Skip to content

finding(create-plugin): every scaffolded source file carries an "ObjectStack Inc." copyright header for the author's own code #8778

Description

@os-zhuang

Found while implementing objectui#8041 (the licence-text card), in the same file and a line away from the line that card moves. Deliberately not changed there: objectui#8041's dispatch holds every emitted file, prompt and manifest field outside the licence question constant, and the right value for this line is a product decision rather than a mechanical substitution.

What the generator emits. packages/create-plugin/src/templates.tsbuildIndexFile, buildImplFile, buildTypesFile and buildTestFile each open the file they write with this block (the year interpolated from new Date().getFullYear()):

/**
 * ObjectUI
 * Copyright (c) 2026-present ObjectStack Inc.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */

Measured on c03d03bb2 by running the real scaffolder (built dist/index.js, driven through a pty with default answers) into a scratch directory: all four emitted src/* files carry it verbatim. Unchanged on a04441f, the objectui#8041 branch head, apart from the licence NAME on the fifth line.

Why this is a defect and not a style nit. Those four files are the author's own plugin code — the component implementation, its schema types, the package entry and its example test. The notice names a third party (this project) as the copyright holder of code the author has not written yet, in a package the author will publish under their own name. It is a stronger claim than the one objectui#8041 was about: that card's manifest asserted a licence choice on the author's behalf; this line asserts ownership.

The rest of that header block is now true. After objectui#8041 the LICENSE file it points at really is emitted, and the licence it names follows what the author chose. The copyright line is the one statement in the block that is still false, and it is now the only one.

Needs triage, not a guess — the candidates point in different directions.

  1. Drop the block from the four emitted sources entirely. Simplest, and a scaffolded file needs no header.
  2. Keep it and name the author (vars.author). But the author prompt is optional with an empty initial, so this needs an answer for the blank case — the same question objectui#8041 had to answer for the LICENSE copyright line.
  3. Replace the copyright claim with a provenance line that is not one — e.g. a "generated by @object-ui/create-plugin" comment. It is the only candidate that says something true without adding a prompt, but whether a generated file should carry provenance at all is a product call.

Related and deliberately separate: objectui#8041 (same file, licence half, ruled and shipping), objectui#3647 (the in-repo instance of the licence-text shape).

Filed by the objectui#8041 development seat under the out-of-scope-finding rule; no assignee, no labels — triage owns both.

Activity

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

    domain:uiobjectui ui stream: fix lands on the published library or apps — objectui execution seatpriority:p2

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions