Skip to content

v0.6.3

@DevGiuDev DevGiuDev tagged this 04 Aug 17:20
The json plugin's local name is "json" but its npm package is
"@saltcorn/json". The lock file dropped the `location` field, so
Plugin.loadAndSaveNewPlugin received location="json" and could not
npm-install the package on a remote tenant — the plugin never registered,
the JSON field type stayed unavailable, and Field.create threw
"Unable to get the sql_type: JSON".

Three fixes:

- export-writer / pullPluginToLock: persist `location` (the npm package
  name / install target) alongside name/version/source. Defaults to name
  when the live export omits it, for backward compatibility.

- tenant-adapters (installOrUpdatePlugin): already reads
  desiredPlugin.location || name; now the lock actually carries it, so
  loadAndSaveNewPlugin receives the correct npm package name.

- tenant-adapters (Phase 3 create_field/update_field/alter_field_type):
  wrap the Field.create / field.update call in try/catch so a missing
  plugin-provided type is reported as skipped (like Phase 2) instead of
  aborting the entire deploy with a 500.

Adds 4 tests covering location persistence, npm-name propagation, and
field-creation error containment.
Assets 2
Loading