Skip to content

Merge master into v1#1739

Open
chrisdp wants to merge 17 commits into
v1from
merge/master_0.73.0
Open

Merge master into v1#1739
chrisdp wants to merge 17 commits into
v1from
merge/master_0.73.0

Conversation

@chrisdp

@chrisdp chrisdp commented Jun 30, 2026

Copy link
Copy Markdown
Contributor

Brings master 0.73.0 into v1: eval/rsg_version firmware-lifecycle validation and production dependency cleanup.

Notable conflict resolutions

  • Adapted master's new availability/rsg_version diagnostics and validators (validateManifest, validateGlobalCallableAvailability, validateMinFirmwareVersionForOptionalChaining) to v1's DiagnosticManager.register API and location model.
  • Converted master's 6 new rsg/global-callable messages to v1's string-code + numeric-legacyCode format (legacyCodes 1149-1154, appended after v1's highest of 1148).
  • Migrated DiagnosticFilterer's matchFileSrcUris/matchFileDestUris from the removed minimatch to micromatch (with the same backslash normalization master introduced), keeping v1's dest-filtering support.
  • Kept master's util helpers (fileUrl/safeJsonStringify/serializeError) since the merged tree uses them; dropped parseXml (removed in v1).
  • Restored the parse-ms direct dependency: master's dep cleanup dropped it, but v1's Sequencer imports it directly (it was only resolving transitively via roku-deploy).

chrisdp and others added 17 commits May 3, 2026 14:07
Adds firmware-aware diagnostics for `eval` calls and the manifest's
`rsg_version` entry, driven by lifecycle metadata in a new
`src/RokuConstants.ts`.

New behavior:
- `eval(...)` is flagged when the effective rsg_version >= 1.2 (where
  Roku sunset eval as a compile error).
- Manifest `rsg_version` is validated against the configured firmware:
  - rsg_version=1.0 → flagged as deprecated/removed depending on the
    user's effective min FW.
  - rsg_version=1.1 → flagged as removed at firmware 14.5 (Roku
    silently treats it as 1.2 from there on).
  - rsg_version=1.2 → flagged as deprecated at firmware 15.1+ in
    favor of 1.3 (cert deadline 2026-10-01).
  - rsg_version=1.3 → flagged as requiring firmware 15.0+.
  - Invalid format (non-semver) → warning.

When the user hasn't configured `minFirmwareVersion`, brighterscript
now assumes a default of 15.0.0 so these diagnostics are useful out
of the box. Users targeting older firmware can opt out by setting
`minFirmwareVersion` explicitly.

Lifecycle data lives in a single `RSG_VERSIONS` map sourced from
Roku's developer release notes and channel-manifest documentation;
adding a new rsg_version is one entry there.
Address PR feedback:
- Add Availability/AvailabilityInfo to Callable. Eval is tagged with
  os.deprecated=9.0.0 and rsg.removed=1.2.0; a single CallExpression
  visitor walks any global callable's availability. Adding a new
  callable's lifecycle is just metadata.
- The validator emits at most one diagnostic per call: rsg axis takes
  precedence; os axis fires only when rsg is silent. Avoids duplicate
  diagnostics on the same line for the common-case modern firmware.
- Replace evalIsDeprecatedAtRsgVersion with two generic diagnostics
  (`globalCallableRemoved`, `globalCallableDeprecated`) parameterized by
  name + axis + threshold + current. Messages match the existing style of
  featureRequiresMinFirmwareVersion (threshold AND current target).
- Diagnostic codes 1147–1152 are renumbered so they appear in numeric
  order in DiagnosticMessages.ts.
- Mark Callable.isDeprecated as @deprecated; availability supersedes it.
- Rename getEffectiveMinFirmwareVersion -> getMinFirmwareVersion. Cache
  it and getRsgVersion. Both return canonical coerced semver strings so
  downstream callers don't re-coerce.
- Drop redundant semver.coerce calls in ProgramValidator.
Co-authored-by: rokucommunity-bot <93661887+rokucommunity-bot@users.noreply.github.com>
Co-authored-by: Bronley Plumb <bronley@gmail.com>
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…e minimatch into micromatch) (#1737)

Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…rsion-validation

# Conflicts:
#	src/DiagnosticMessages.ts
#	src/Program.ts
#	src/bscPlugin/validation/BrsFileValidator.spec.ts
#	src/bscPlugin/validation/BrsFileValidator.ts
Brings master 0.73.0 into v1 (eval/rsg_version firmware-lifecycle
validation, production dependency cleanup).

- Adapted master's new availability/rsg_version diagnostics and validators
  to v1's DiagnosticManager API and string diagnostic codes (legacyCodes
  1149-1154 appended after v1's highest).
- Migrated DiagnosticFilterer from minimatch to micromatch.
- Restored the parse-ms direct dependency used by Sequencer.
@markwpearce markwpearce added this to the v1.0.0 milestone Jun 30, 2026
@markwpearce markwpearce self-requested a review June 30, 2026 12:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants