Files
FredApps f7502233f8 RFC-0027: align the licence allowlist with shipping dependencies (#41)
Adopt the shared compatible-dependency allowlist and unmodified MPL-2.0 terms. The owner decision and promised strict-core/community/shared-library follow-up are recorded in the PR discussion.

Original RFC by @FredApps.
2026-11-15 09:06:20 -06:00

2.9 KiB

Rust Craft repositories

These apply to native Craft apps and to shared Rust libraries. Select them by repository type. A repository that merely contains some Rust does not take this block. Rules later in a repository's file may be stricter, but not weaker. The source is standards/house-rules-rust.md in storytold/craft-contrib.

  1. Never crash. Non-test code does not panic and has no unsafe, except where the repository file names an exception. Return errors, treat input as hostile, and bound recursion and allocations. New production crate roots copy the deny attribute from an existing crate: clippy::unwrap_used, clippy::expect_used, clippy::panic, clippy::unimplemented, clippy::todo, clippy::unreachable. Every crash fix comes with a test that panicked before the fix.
  2. Clean room. Learn from observed behaviour and public specifications. Do not copy another product's code, assets, strings or artwork. Check a dependency's licence before adding it.
  3. Assets and fonts. Every asset is original or suitably licensed, and is recorded in ATTRIBUTION.md in the same change. Font files live in storytold/craft-fonts, not in the app repository.
  4. Rust only for native Craft apps. No handwritten JavaScript or TypeScript, and no Tauri, Electron or webview shell, in those apps. Shared tooling follows its documented technical scope and maintainer-approved exceptions. Craft PR Review's existing Tauri and TypeScript UI is one such exception. It does not relax this rule for native apps. Preserve any existing web build.
  5. Time goes through chrono. Do not hand-roll calendar conversion. For dates beyond what chrono can represent, follow standards/time.md.
  6. Contributor credits. Add or edit only your own person's entry in contributors/people.toml, and only after asking them. Never guess a name or hand-edit contributors.json.

Licence allowlist

Dependencies and assets use SPDX identifiers. An expression is allowed when every identifier is in this list. A repository may name a shorter list. It may not add an identifier here by editing its own copy of these rules.

  • ISC
  • MIT
  • BSD-2-Clause
  • BSD-3-Clause
  • Apache-2.0
  • Unicode-3.0
  • OFL-1.1
  • Ubuntu-font-1.0
  • Bitstream-Vera
  • CC0-1.0
  • CC-BY-4.0
  • CC-BY-SA-4.0
  • Zlib
  • BSL-1.0
  • 0BSD
  • Unlicense
  • IJG
  • NCSA
  • CDLA-Permissive-2.0
  • Apache-2.0 WITH LLVM-exception
  • LicenseRef-Public-Domain

MPL-2.0 is allowed for third-party dependencies used unmodified; vendoring, patching or copying its code needs a maintainer's approval. MPL-2.0+ counts as MPL-2.0.

LicenseRef-Storyteller-Trademark is not in this list. It covers Storyteller brand marks only, where a repository already says so.