Skip to content

2024-11-13

Latest
Compare
Choose a tag to compare
@kriskowal kriskowal released this 13 Nov 21:54
· 14 commits to master since this release

ses v1.10.0

  • Permit Promise.try, since it has reached Stage 4.

  • Adds a reporting option to lockdown and repairIntrinsics.

    The default behavior is "platform" which will detect the platform and report warnings according to whether a web console, Node.js console, or print are available. The web platform is distinguished by the existence of window or importScripts (WebWorker). The Node.js behavior is to report all warnings to stderr visually consistent with use of a console group. SES will use print in the absence of a console. Captures the platform console at the time lockdown or repairIntrinsics are called, not at the time ses initializes.

    The "console" option forces the web platform behavior. On Node.js, this results in group labels being reported to stdout.

    The "none" option mutes warnings.

@endo/bundle-source v3.5.0

  • Adds support for TypeScript type erasure using ts-blank-space applied to TypeScript modules with .ts, .mts, and .cts extensions, for any package that is not under a node_modules directory, immitating node --experimental-strip-types. As with .js extensions, the behavior of .ts is either consistent with .mts or .cts depending on the type in package.json.

@endo/compartment-mapper v1.4.0

  • Adds options languageForExtension, moduleLanguageForExtension, commonjsLanguageForExtension, and languages to mapNodeModules and compartmentMapForNodeModules allowing for certain mappings from extension (e.g., ts) to language (e.g., mts or cts) to depend on the each package’s type in the way we already vary js between cjs and mjs. These options enter through the high level functions including makeArchive and importLocation.
  • The new options workspaceLanguageForExtension, workspaceModuleLanguageForExtension, and workspaceCommonjsLanguageForExtension apply like the above except more specifically and for packages that are not physically located under a node_modules directory, indicating that JavaScript has not yet been generated from any non-JavaScript source files.
  • Omits unused module descriptors from compartment-map.json in archived applications, potentially reducing file sizes.
  • Fixes an issue where errors thrown from exit module hooks (importHook) would be thrown at parse-time when the parser uses heuristic import analysis instead of at runtime. Such errors will now be thrown at runtime, as originally intended. To those who expected the previous behavior: if you exist, please exercise caution when upgrading.