Skip to content

fix(license): drop unused OFL-1.1 font from the published package#1357

Merged
Martin Torp (mtorp) merged 1 commit into
v1.xfrom
license/drop-ofl-font
Jun 8, 2026
Merged

fix(license): drop unused OFL-1.1 font from the published package#1357
Martin Torp (mtorp) merged 1 commit into
v1.xfrom
license/drop-ofl-font

Conversation

@mtorp

@mtorp Martin Torp (mtorp) commented Jun 8, 2026

Copy link
Copy Markdown
Contributor

Why

npm reports socket as MIT AND OFL-1.1 even though the project's own code is MIT. The OFL-1.1 comes from the Terminus bitmap font (external/blessed/usr/fonts/ter-u14{n,b}.json), which lands in the tarball as a byproduct of vendoring the entire blessed library wholesale.

The font is dead weight: it's read only by blessed's BigText widget, and the CLI never instantiates BigText (it uses screen/box/table/grid/bar/line, and requires those widget files directly — it never imports blessed's index, so bigtext.js isn't even loaded).

What

  • .config/rollup.dist.config.mjs — scope the blessed vendoring keep-list from usr/**/** to usr/*. This keeps the flat terminfo files (usr/xterm, usr/linux, …) that blessed actually needs, but drops usr/fonts/** (the OFL font + its AUTHORS/README/LICENSE). Added a comment documenting the scoping and a reminder to re-verify usr/ on a blessed upgrade.
  • package.jsonlicense MIT AND OFL-1.1MIT; version 1.1.1161.1.117.
  • CHANGELOG.md1.1.117 entry.

external/ is a gitignored build artifact, so no vendored files are committed — the change is the build config that regenerates it.

Verification

  • pnpm build:dist:src → exit 0; socket --version1.1.117
  • external/blessed/usr/fonts/ gone; terminfo retained
  • npm pack --dry-run publish set: no usr/fonts/ter-u14/OFL entries
  • Every remaining LICENSE file in the publish set is MIT (root, blessed, blessed-contrib, @socketsecurity/registry) — so the MIT field now agrees with file-content scanning, not just the manifest.

Notes / follow-ups

  • After publish, re-scan socket@1.1.117 with whatever originally flagged OFL to confirm it's cleared end-to-end.
  • external/blessed/lib/widgets/bigtext.js is left in place (MIT, harmless dead code; ENOENT only on an explicit new BigText(), which never happens). Optional future cleanup.
  • Publish is the manual provenance.yml workflow_dispatch, which reads version from package.json and tags v1.1.117.

Base branch is v1.x (the 1.x release line) — retarget if a patch should go elsewhere.


Note

Low Risk
Packaging-only change with no CLI behavior change; the only caveat is a future blessed usr/ layout change could drop needed terminfo if not re-verified.

Overview
The published socket npm package no longer ships the unused Terminus bitmap font from vendored blessed (usr/fonts/**, OFL-1.1). .config/rollup.dist.config.mjs tightens the blessed keep-list from usr/**/** to usr/*, so flat terminfo files (e.g. usr/xterm) still land in the tarball while nested font assets are stripped at build time; comments call out re-checking usr/ on blessed upgrades.

package.json declares MIT only (was MIT AND OFL-1.1) and bumps to 1.1.117; CHANGELOG.md documents the licensing/packaging change.

Reviewed by Cursor Bugbot for commit 72a7d42. Configure here.

The vendored copy of `blessed` pulls in the Terminus bitmap font (external/blessed/usr/fonts/ter-u14*.json), which is licensed OFL-1.1 and is only read by blessed's BigText widget — a widget the CLI never instantiates. Shipping it forced the package's declared license to be `MIT AND OFL-1.1`.

Scope the blessed vendoring keep-list to `usr/*` so the terminfo files are retained while usr/fonts/** is dropped, and declare the license as plain `MIT`. Bump to 1.1.117.
@mtorp Martin Torp (mtorp) marked this pull request as ready for review June 8, 2026 08:47

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.

LGTM 👍

@mtorp Martin Torp (mtorp) merged commit 1b5289d into v1.x Jun 8, 2026
17 of 26 checks passed
@mtorp Martin Torp (mtorp) deleted the license/drop-ofl-font branch June 8, 2026 08:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants