diff --git a/packages/ERTP/package.json b/packages/ERTP/package.json index 60d7d137ca3b..eb8a06cfe25f 100644 --- a/packages/ERTP/package.json +++ b/packages/ERTP/package.json @@ -36,7 +36,6 @@ "dependencies": { "@agoric/assert": "^0.0.7", "@agoric/eventual-send": "^0.9.2", - "@agoric/harden": "^0.0.8", "@agoric/import-manager": "^0.0.6", "@agoric/layer-cake": "^0.0.1", "@agoric/marshal": "^0.2.2", diff --git a/packages/ERTP/src/amountMath.js b/packages/ERTP/src/amountMath.js index 2e13dbf9c219..4925f8446b36 100644 --- a/packages/ERTP/src/amountMath.js +++ b/packages/ERTP/src/amountMath.js @@ -1,5 +1,6 @@ +/* global harden */ // @ts-check -import harden from '@agoric/harden'; + import { assert, details } from '@agoric/assert'; import { mustBeComparable } from '@agoric/same-structure'; diff --git a/packages/ERTP/src/issuer.js b/packages/ERTP/src/issuer.js index d515d6f81604..d48fb711a259 100644 --- a/packages/ERTP/src/issuer.js +++ b/packages/ERTP/src/issuer.js @@ -1,7 +1,8 @@ // Copyright (C) 2019 Agoric, under Apache License 2.0 + +/* global harden */ // @ts-check -import harden from '@agoric/harden'; import { assert, details } from '@agoric/assert'; import makeStore from '@agoric/weak-store'; import { isPromise } from '@agoric/produce-promise'; diff --git a/packages/ERTP/src/mathHelpers/natMathHelpers.js b/packages/ERTP/src/mathHelpers/natMathHelpers.js index ab623e7fc07c..73c5ce86d743 100644 --- a/packages/ERTP/src/mathHelpers/natMathHelpers.js +++ b/packages/ERTP/src/mathHelpers/natMathHelpers.js @@ -1,5 +1,6 @@ +/* global harden */ + import Nat from '@agoric/nat'; -import harden from '@agoric/harden'; // Fungible digital assets use the natMathHelpers to manage balances - // the operations are merely arithmetic on natural, non-negative diff --git a/packages/ERTP/src/mathHelpers/setMathHelpers.js b/packages/ERTP/src/mathHelpers/setMathHelpers.js index d61232f37ab8..45838c9d8982 100644 --- a/packages/ERTP/src/mathHelpers/setMathHelpers.js +++ b/packages/ERTP/src/mathHelpers/setMathHelpers.js @@ -1,4 +1,5 @@ -import harden from '@agoric/harden'; +/* global harden */ + import { passStyleOf } from '@agoric/marshal'; import { assert, details } from '@agoric/assert'; import { sameStructure } from '@agoric/same-structure'; diff --git a/packages/ERTP/src/mathHelpers/strSetMathHelpers.js b/packages/ERTP/src/mathHelpers/strSetMathHelpers.js index 14456eb15c4c..75bee3ab1d3d 100644 --- a/packages/ERTP/src/mathHelpers/strSetMathHelpers.js +++ b/packages/ERTP/src/mathHelpers/strSetMathHelpers.js @@ -1,4 +1,5 @@ -import harden from '@agoric/harden'; +/* global harden */ + import { passStyleOf } from '@agoric/marshal'; import { assert, details } from '@agoric/assert'; diff --git a/packages/ERTP/test/swingsetTests/splitPayments/bootstrap.js b/packages/ERTP/test/swingsetTests/splitPayments/bootstrap.js index 37cda4f6593a..9785b65b3b5b 100644 --- a/packages/ERTP/test/swingsetTests/splitPayments/bootstrap.js +++ b/packages/ERTP/test/swingsetTests/splitPayments/bootstrap.js @@ -1,4 +1,4 @@ -import harden from '@agoric/harden'; +/* global harden */ import produceIssuer from '../../../src/issuer'; diff --git a/packages/ERTP/test/swingsetTests/splitPayments/vat-alice.js b/packages/ERTP/test/swingsetTests/splitPayments/vat-alice.js index 2484c4b79d9e..41ae97d26ce2 100644 --- a/packages/ERTP/test/swingsetTests/splitPayments/vat-alice.js +++ b/packages/ERTP/test/swingsetTests/splitPayments/vat-alice.js @@ -1,4 +1,4 @@ -import harden from '@agoric/harden'; +/* global harden */ function makeAliceMaker(E, log) { return harden({ diff --git a/packages/ERTP/test/unitTests/mathHelpers/test-natMathHelpers.js b/packages/ERTP/test/unitTests/mathHelpers/test-natMathHelpers.js index 65433fa5962b..f61f97765180 100644 --- a/packages/ERTP/test/unitTests/mathHelpers/test-natMathHelpers.js +++ b/packages/ERTP/test/unitTests/mathHelpers/test-natMathHelpers.js @@ -1,6 +1,8 @@ +/* global harden */ // eslint-disable-next-line import/no-extraneous-dependencies + +import '@agoric/install-ses'; import { test } from 'tape-promise/tape'; -import harden from '@agoric/harden'; import makeAmountMath from '../../../src/amountMath'; diff --git a/packages/ERTP/test/unitTests/mathHelpers/test-setMathHelpers.js b/packages/ERTP/test/unitTests/mathHelpers/test-setMathHelpers.js index 2e930fe5188d..0a804a0bc7e6 100644 --- a/packages/ERTP/test/unitTests/mathHelpers/test-setMathHelpers.js +++ b/packages/ERTP/test/unitTests/mathHelpers/test-setMathHelpers.js @@ -1,6 +1,8 @@ +/* global harden */ // eslint-disable-next-line import/no-extraneous-dependencies + +import '@agoric/install-ses'; import { test } from 'tape-promise/tape'; -import harden from '@agoric/harden'; import makeAmountMath from '../../../src/amountMath'; diff --git a/packages/ERTP/test/unitTests/mathHelpers/test-strSetMathHelpers.js b/packages/ERTP/test/unitTests/mathHelpers/test-strSetMathHelpers.js index e37fb463afb8..946f20adfc85 100644 --- a/packages/ERTP/test/unitTests/mathHelpers/test-strSetMathHelpers.js +++ b/packages/ERTP/test/unitTests/mathHelpers/test-strSetMathHelpers.js @@ -1,6 +1,8 @@ +/* global harden */ // eslint-disable-next-line import/no-extraneous-dependencies + +import '@agoric/install-ses'; import { test } from 'tape-promise/tape'; -import harden from '@agoric/harden'; import makeAmountMath from '../../../src/amountMath'; diff --git a/packages/ERTP/test/unitTests/test-issuerObj.js b/packages/ERTP/test/unitTests/test-issuerObj.js index 7c95c1147fea..d88bb813c6a5 100644 --- a/packages/ERTP/test/unitTests/test-issuerObj.js +++ b/packages/ERTP/test/unitTests/test-issuerObj.js @@ -1,4 +1,5 @@ // eslint-disable-next-line import/no-extraneous-dependencies +import '@agoric/install-ses'; import test from 'tape-promise/tape'; import { E } from '@agoric/eventual-send'; diff --git a/packages/ERTP/test/unitTests/test-mintObj.js b/packages/ERTP/test/unitTests/test-mintObj.js index 350bc59134f4..989645f93cd5 100644 --- a/packages/ERTP/test/unitTests/test-mintObj.js +++ b/packages/ERTP/test/unitTests/test-mintObj.js @@ -1,6 +1,8 @@ +/* global harden */ // eslint-disable-next-line import/no-extraneous-dependencies + +import '@agoric/install-ses'; import { test } from 'tape-promise/tape'; -import harden from '@agoric/harden'; import produceIssuer from '../../src/issuer'; diff --git a/packages/acorn-eventual-send/encouragementBotCommsWavyDot/bootstrap.js b/packages/acorn-eventual-send/encouragementBotCommsWavyDot/bootstrap.js index 53d55153f644..00c34987cf3c 100644 --- a/packages/acorn-eventual-send/encouragementBotCommsWavyDot/bootstrap.js +++ b/packages/acorn-eventual-send/encouragementBotCommsWavyDot/bootstrap.js @@ -1,4 +1,4 @@ -import harden from '@agoric/harden'; +/* global harden */ // This javascript source file uses the "tildot" syntax (foo~.bar()) for // eventual sends. diff --git a/packages/acorn-eventual-send/encouragementBotCommsWavyDot/vat-bot.js b/packages/acorn-eventual-send/encouragementBotCommsWavyDot/vat-bot.js index 4e1d9383a8f7..8c12d7e5ac7b 100644 --- a/packages/acorn-eventual-send/encouragementBotCommsWavyDot/vat-bot.js +++ b/packages/acorn-eventual-send/encouragementBotCommsWavyDot/vat-bot.js @@ -1,4 +1,4 @@ -import harden from '@agoric/harden'; +/* global harden */ export default function setup(syscall, state, helpers) { function log(what) { diff --git a/packages/acorn-eventual-send/encouragementBotCommsWavyDot/vat-user.js b/packages/acorn-eventual-send/encouragementBotCommsWavyDot/vat-user.js index c8623085b8cb..65af32ed5140 100644 --- a/packages/acorn-eventual-send/encouragementBotCommsWavyDot/vat-user.js +++ b/packages/acorn-eventual-send/encouragementBotCommsWavyDot/vat-user.js @@ -1,4 +1,4 @@ -import harden from '@agoric/harden'; +/* global harden */ // This javascript source file uses the "tildot" syntax (foo~.bar()) for // eventual sends. diff --git a/packages/acorn-eventual-send/test/test-rollup.js b/packages/acorn-eventual-send/test/test-rollup.js index dd1e2b1409b8..83a608c6150a 100644 --- a/packages/acorn-eventual-send/test/test-rollup.js +++ b/packages/acorn-eventual-send/test/test-rollup.js @@ -8,7 +8,7 @@ test('SwingSet bug', async t => { const bundle = await rollup({ input: require.resolve('../encouragementBotCommsWavyDot/bootstrap.js'), treeshake: false, - external: ['@agoric/evaluate', '@agoric/nat', '@agoric/harden'], + external: ['@agoric/evaluate', '@agoric/nat'], acornInjectPlugins: [eventualSend(acorn)], }); t.ok(bundle); diff --git a/packages/agoric-cli/package.json b/packages/agoric-cli/package.json index f78a88af55b0..09f8da5f24cc 100644 --- a/packages/agoric-cli/package.json +++ b/packages/agoric-cli/package.json @@ -16,6 +16,7 @@ "lint-check-jessie": "eslint -c '.eslintrc-jessie.js' '**/*.{js,jsx}'" }, "devDependencies": { + "@agoric/install-ses": "0.1.0", "tap-spec": "^5.0.0", "tape": "^4.11.0", "tape-promise": "^4.0.0", diff --git a/packages/agoric-cli/test/test-main.js b/packages/agoric-cli/test/test-main.js index 098accc09b14..95d6410c4db6 100644 --- a/packages/agoric-cli/test/test-main.js +++ b/packages/agoric-cli/test/test-main.js @@ -1,4 +1,5 @@ /* global globalThis */ +import '@agoric/install-ses'; import { test } from 'tape-promise/tape'; import fs from 'fs'; import anylogger from 'anylogger'; diff --git a/packages/assert/package.json b/packages/assert/package.json old mode 100644 new mode 100755 index fcdcac539d7c..3f0749a29110 --- a/packages/assert/package.json +++ b/packages/assert/package.json @@ -29,10 +29,10 @@ }, "homepage": "https://github.com/Agoric/agoric-sdk#readme", "dependencies": { - "@agoric/harden": "^0.0.8" }, "devDependencies": { "esm": "^3.2.25", + "@agoric/install-ses": "0.1.0", "tap-spec": "^5.0.0", "tape": "^4.11.0", "tape-promise": "^4.0.0" diff --git a/packages/assert/src/assert.js b/packages/assert/src/assert.js index 1180c3c9882b..62f2752a5c60 100644 --- a/packages/assert/src/assert.js +++ b/packages/assert/src/assert.js @@ -1,14 +1,13 @@ // Copyright (C) 2019 Agoric, under Apache License 2.0 + +/* global harden */ + // @ts-check // This module assumes the de-facto standard `console` host object. // To the extent that this `console` is considered a resource, // this module must be considered a resource module. -import rawHarden from '@agoric/harden'; - -const harden = /** @type {(x: T) => T} */ (rawHarden); - /** * Prepend the correct indefinite article onto a noun, typically a typeof result * e.g., "an Object" vs. "a Number" diff --git a/packages/assert/test/test-assert.js b/packages/assert/test/test-assert.js index dcfb08b1ec02..13aecc6d577c 100644 --- a/packages/assert/test/test-assert.js +++ b/packages/assert/test/test-assert.js @@ -1,3 +1,4 @@ +import '@agoric/install-ses'; import { test } from 'tape'; import { an, assert, details, q } from '../src/assert'; import { throwsAndLogs } from './throwsAndLogs'; diff --git a/packages/assert/test/throwsAndLogs.js b/packages/assert/test/throwsAndLogs.js index 30bc420daa04..e8ea8ea357d2 100644 --- a/packages/assert/test/throwsAndLogs.js +++ b/packages/assert/test/throwsAndLogs.js @@ -1,4 +1,4 @@ -import harden from '@agoric/harden'; +/* global harden */ const { defineProperty } = Object; diff --git a/packages/bundle-source/demo/dir1/index.js b/packages/bundle-source/demo/dir1/index.js index deec7419fe7c..95a848e88d69 100644 --- a/packages/bundle-source/demo/dir1/index.js +++ b/packages/bundle-source/demo/dir1/index.js @@ -1,4 +1,5 @@ -import harden from '@agoric/harden'; +/* global harden */ + import { encourage, makeError } from './encourage'; import more from './sub/more'; diff --git a/packages/bundle-source/package.json b/packages/bundle-source/package.json index a4b5a2e86358..84196e4ed932 100644 --- a/packages/bundle-source/package.json +++ b/packages/bundle-source/package.json @@ -20,7 +20,7 @@ "dependencies": { "@agoric/acorn-eventual-send": "^2.0.5", "@agoric/babel-parser": "^7.6.4", - "@agoric/harden": "^0.0.8", + "@agoric/install-ses": "0.1.0", "@agoric/transform-eventual-send": "^1.3.0", "@babel/generator": "^7.6.4", "@rollup/plugin-commonjs": "^11.0.2", diff --git a/packages/bundle-source/src/index.js b/packages/bundle-source/src/index.js index 7fc8990d0f21..92c0e05e14ac 100644 --- a/packages/bundle-source/src/index.js +++ b/packages/bundle-source/src/index.js @@ -48,7 +48,7 @@ export default async function bundleSource( input: resolvedPath, treeshake: false, preserveModules: moduleFormat === 'nestedEvaluate', - external: ['@agoric/harden', ...externals], + external: [...externals], plugins: [ resolvePlugin({ preferBuiltins: true }), tildotPlugin(), diff --git a/packages/bundle-source/test/circular.js b/packages/bundle-source/test/circular.js index 434f77dbf669..36777ea5239e 100644 --- a/packages/bundle-source/test/circular.js +++ b/packages/bundle-source/test/circular.js @@ -1,4 +1,5 @@ /* global Compartment */ + import '@agoric/install-ses'; import { test } from 'tape-promise/tape'; import bundleSource from '..'; @@ -15,7 +16,6 @@ test('circular export', async t => { 'nestedEvaluate', ); - // Fake out `require('@agoric/harden')`. const require = _ => o => o; const nestedEvaluate = src => { // console.log('========== evaluating', src); diff --git a/packages/bundle-source/test/sanity.js b/packages/bundle-source/test/sanity.js index d2403c9d7bfa..b1fc8f738e76 100644 --- a/packages/bundle-source/test/sanity.js +++ b/packages/bundle-source/test/sanity.js @@ -1,4 +1,5 @@ /* global Compartment */ + import '@agoric/install-ses'; import { test } from 'tape-promise/tape'; import bundleSource from '..'; @@ -21,9 +22,7 @@ test('nestedEvaluate', async t => { // console.log(srcMap1); t.equal(mf1, 'nestedEvaluate', 'module format is nestedEvaluate'); - t.assert(src1.match(/require\('@agoric\/harden'\)/), 'harden is required'); - // Fake out `require('@agoric/harden')`. const require = _ => o => o; const nestedEvaluate = src => { // console.log('========== evaluating', src); @@ -78,9 +77,7 @@ test('getExport', async t => { // console.log(srcMap1); t.equal(mf1, 'getExport', 'module format is getExport'); - t.assert(src1.match(/require\('@agoric\/harden'\)/), 'harden is required'); - // Fake out `require('@agoric/harden')`. // eslint-disable-next-line no-eval const ex1 = eval(`const require = _ => o => o;${srcMap1}`)(); diff --git a/packages/bundle-source/test/tildot-transform.js b/packages/bundle-source/test/tildot-transform.js index a2214a5f30b7..fa006135e18f 100644 --- a/packages/bundle-source/test/tildot-transform.js +++ b/packages/bundle-source/test/tildot-transform.js @@ -1,3 +1,4 @@ +import '@agoric/install-ses'; import { test } from 'tape-promise/tape'; import bundleSource from '..'; diff --git a/packages/captp/lib/captp.js b/packages/captp/lib/captp.js index a018788713e5..4fb711299a7c 100644 --- a/packages/captp/lib/captp.js +++ b/packages/captp/lib/captp.js @@ -1,12 +1,13 @@ +/* global harden */ + // This logic was mostly lifted from @agoric/swingset-vat liveSlots.js // Defects in it are mfig's fault. import { Remotable, makeMarshal, QCLASS } from '@agoric/marshal'; -import harden from '@agoric/harden'; import Nat from '@agoric/nat'; import { HandledPromise, E } from '@agoric/eventual-send'; import { isPromise } from '@agoric/produce-promise'; -export { E, HandledPromise, Nat, harden }; +export { E, HandledPromise, Nat }; export function makeCapTP(ourId, send, bootstrapObj = undefined) { let unplug = false; diff --git a/packages/captp/package.json b/packages/captp/package.json index b13fa0a86823..789f63aa5aaf 100644 --- a/packages/captp/package.json +++ b/packages/captp/package.json @@ -32,13 +32,13 @@ "lint-check-jessie": "eslint -c '.eslintrc-jessie.js' '**/*.js'" }, "devDependencies": { + "@agoric/install-ses": "0.1.0", "tap-spec": "^5.0.0", "tape": "^4.11.0", "tape-promise": "^4.0.0" }, "dependencies": { "@agoric/eventual-send": "^0.9.2", - "@agoric/harden": "^0.0.8", "@agoric/marshal": "^0.2.2", "@agoric/nat": "^2.0.1", "@agoric/produce-promise": "^0.1.2", diff --git a/packages/captp/test/crosstalk.js b/packages/captp/test/crosstalk.js index 2d5207618695..9a74ac89959c 100644 --- a/packages/captp/test/crosstalk.js +++ b/packages/captp/test/crosstalk.js @@ -1,5 +1,8 @@ +/* global harden */ + +import '@agoric/install-ses'; import { test } from 'tape-promise/tape'; -import { harden, makeCapTP, E } from '../lib/captp'; +import { makeCapTP, E } from '../lib/captp'; test('prevent crosstalk', async t => { try { diff --git a/packages/captp/test/disco.js b/packages/captp/test/disco.js index d13ee1c03f64..1f1716a932d6 100644 --- a/packages/captp/test/disco.js +++ b/packages/captp/test/disco.js @@ -1,5 +1,8 @@ +/* global harden */ + +import '@agoric/install-ses'; import { test } from 'tape-promise/tape'; -import { harden, makeCapTP } from '../lib/captp'; +import { makeCapTP } from '../lib/captp'; test('try disconnecting captp', async t => { try { diff --git a/packages/captp/test/loopback.js b/packages/captp/test/loopback.js index c3e853e634fa..ce9f786a3471 100644 --- a/packages/captp/test/loopback.js +++ b/packages/captp/test/loopback.js @@ -1,5 +1,8 @@ +/* global harden */ + +import '@agoric/install-ses'; import { test } from 'tape-promise/tape'; -import { E, harden, makeCapTP } from '../lib/captp'; +import { E, makeCapTP } from '../lib/captp'; test('try loopback captp', async t => { try { diff --git a/packages/eventual-send/package.json b/packages/eventual-send/package.json index 35913097424a..0078c739e627 100644 --- a/packages/eventual-send/package.json +++ b/packages/eventual-send/package.json @@ -21,10 +21,10 @@ }, "homepage": "https://github.com/Agoric/agoric-sdk#readme", "dependencies": { - "@agoric/harden": "^0.0.8" }, "devDependencies": { "esm": "^3.2.7", + "@agoric/install-ses": "0.1.0", "rollup": "^1.2.2", "tape": "^4.11.0", "tape-promise": "^4.0.0" diff --git a/packages/eventual-send/rollup.config.js b/packages/eventual-send/rollup.config.js index e67a5dab481f..357d7312c6c1 100644 --- a/packages/eventual-send/rollup.config.js +++ b/packages/eventual-send/rollup.config.js @@ -6,9 +6,9 @@ export default [ file: 'dist/eventual-send.umd.js', format: 'umd', name: 'EventualSend', - globals: { - '@agoric/harden': 'harden', - }, + // globals: { + // '@agoric/harden': 'harden', + // }, }, { file: 'dist/eventual-send.esm.js', diff --git a/packages/eventual-send/src/E.js b/packages/eventual-send/src/E.js index 9f8e9682084c..e67449f9ba0c 100644 --- a/packages/eventual-send/src/E.js +++ b/packages/eventual-send/src/E.js @@ -1,9 +1,8 @@ -/* global */ +/* global harden */ + // eslint-disable-next-line spaced-comment /// -import harden from '@agoric/harden'; - const readOnlyProxy = { set(_target, _prop, _value) { return false; diff --git a/packages/eventual-send/src/index.js b/packages/eventual-send/src/index.js index 128724485472..8f6423991b58 100644 --- a/packages/eventual-send/src/index.js +++ b/packages/eventual-send/src/index.js @@ -1,6 +1,4 @@ -/* global HandledPromise */ - -import harden from '@agoric/harden'; +/* global harden HandledPromise */ import makeE from './E'; diff --git a/packages/eventual-send/test/test-e.js b/packages/eventual-send/test/test-e.js index 97fc9215310d..b17b7be68435 100644 --- a/packages/eventual-send/test/test-e.js +++ b/packages/eventual-send/test/test-e.js @@ -1,3 +1,4 @@ +import '@agoric/install-ses'; import test from 'tape-promise/tape'; import { E, HandledPromise } from '../src/index'; diff --git a/packages/import-manager/package.json b/packages/import-manager/package.json index 751d4d5c6465..c0fccbca6387 100644 --- a/packages/import-manager/package.json +++ b/packages/import-manager/package.json @@ -28,9 +28,9 @@ }, "homepage": "https://github.com/Agoric/agoric-sdk#readme", "dependencies": { - "@agoric/harden": "^0.0.8" }, "devDependencies": { + "@agoric/install-ses": "0.1.0", "esm": "^3.2.25", "tap-spec": "^5.0.0", "tape": "^4.11.0", diff --git a/packages/import-manager/src/importManager.js b/packages/import-manager/src/importManager.js index 795957d93fa4..c9e3054afe1d 100644 --- a/packages/import-manager/src/importManager.js +++ b/packages/import-manager/src/importManager.js @@ -1,6 +1,6 @@ // Copyright (C) 2019 Agoric, under Apache License 2.0 -import harden from '@agoric/harden'; +/* global harden */ // ImportManager allows a package to make some code available that can be run // locally by a calling vat without requiring a remote round trip to the hosting diff --git a/packages/import-manager/test/unitTests/test-importsA.js b/packages/import-manager/test/unitTests/test-importsA.js index c4a95f2a01a9..56e8b1b1b422 100644 --- a/packages/import-manager/test/unitTests/test-importsA.js +++ b/packages/import-manager/test/unitTests/test-importsA.js @@ -1,5 +1,6 @@ // Copyright (C) 2019 Agoric, under Apache License 2.0 +import '@agoric/install-ses'; import { test } from 'tape-promise/tape'; import { makeGoodImportManager } from './goodImports'; diff --git a/packages/marshal/marshal.js b/packages/marshal/marshal.js index e3b46a69933a..a0138773226f 100644 --- a/packages/marshal/marshal.js +++ b/packages/marshal/marshal.js @@ -1,5 +1,6 @@ +/* global harden */ // @ts-check -import harden from '@agoric/harden'; + import Nat from '@agoric/nat'; import { isPromise } from '@agoric/produce-promise'; diff --git a/packages/marshal/package.json b/packages/marshal/package.json index 97ea1b0f2aa6..6eaf79fef7ea 100644 --- a/packages/marshal/package.json +++ b/packages/marshal/package.json @@ -29,12 +29,12 @@ "homepage": "https://github.com/Agoric/agoric-sdk#readme", "dependencies": { "@agoric/eventual-send": "^0.9.2", - "@agoric/harden": "^0.0.8", "@agoric/nat": "^2.0.1", "@agoric/produce-promise": "^0.1.2" }, "devDependencies": { "esm": "^3.2.25", + "@agoric/install-ses": "0.1.0", "tap-spec": "^5.0.0", "tape": "^4.10.2", "tape-promise": "^4.0.0" diff --git a/packages/marshal/test/test-marshal.js b/packages/marshal/test/test-marshal.js index 25742fd9c579..3a41741572a3 100644 --- a/packages/marshal/test/test-marshal.js +++ b/packages/marshal/test/test-marshal.js @@ -1,7 +1,7 @@ -/* globals BigInt */ +/* global harden BigInt */ +import '@agoric/install-ses'; import { test } from 'tape-promise/tape'; -import harden from '@agoric/harden'; import { Remotable, getInterfaceOf, diff --git a/packages/notifier/package.json b/packages/notifier/package.json index a98b6b7dd57a..83629650263b 100644 --- a/packages/notifier/package.json +++ b/packages/notifier/package.json @@ -28,10 +28,10 @@ }, "homepage": "https://github.com/Agoric/agoric-sdk#readme", "dependencies": { - "@agoric/harden": "^0.0.8", "@agoric/produce-promise": "^0.1.2" }, "devDependencies": { + "@agoric/install-ses": "0.1.0", "esm": "^3.2.25", "tap-spec": "^5.0.0", "tape": "^4.11.0", diff --git a/packages/notifier/src/notifier.js b/packages/notifier/src/notifier.js index 08009bbed46f..7dd36eb60f0c 100644 --- a/packages/notifier/src/notifier.js +++ b/packages/notifier/src/notifier.js @@ -1,5 +1,6 @@ +/* global harden */ + import { producePromise } from '@agoric/produce-promise'; -import harden from '@agoric/harden'; /** * Produces a pair of objects, which allow a service to produce a stream of diff --git a/packages/notifier/test/test-notifier.js b/packages/notifier/test/test-notifier.js index 298cf3d7afb2..a4b9a5c74d03 100644 --- a/packages/notifier/test/test-notifier.js +++ b/packages/notifier/test/test-notifier.js @@ -1,4 +1,5 @@ // eslint-disable-next-line import/no-extraneous-dependencies +import '@agoric/install-ses'; import { test } from 'tape-promise/tape'; import { produceNotifier } from '../src/notifier'; diff --git a/packages/produce-promise/package.json b/packages/produce-promise/package.json index 0b3b5519844c..99062ff9736f 100644 --- a/packages/produce-promise/package.json +++ b/packages/produce-promise/package.json @@ -28,8 +28,7 @@ }, "homepage": "https://github.com/Agoric/agoric-sdk#readme", "dependencies": { - "@agoric/eventual-send": "^0.9.2", - "@agoric/harden": "^0.0.8" + "@agoric/eventual-send": "^0.9.2" }, "devDependencies": { "esm": "^3.2.25", diff --git a/packages/produce-promise/src/producePromise.js b/packages/produce-promise/src/producePromise.js index 93e33b029191..785ac217429f 100644 --- a/packages/produce-promise/src/producePromise.js +++ b/packages/produce-promise/src/producePromise.js @@ -1,5 +1,6 @@ +/* global harden */ // @ts-check -import harden from '@agoric/harden'; + import { HandledPromise } from '@agoric/eventual-send'; /** diff --git a/packages/registrar/package.json b/packages/registrar/package.json index 121efe114f00..8bbfec27f7e2 100644 --- a/packages/registrar/package.json +++ b/packages/registrar/package.json @@ -27,10 +27,10 @@ "homepage": "https://github.com/Agoric/agoric-sdk#readme", "dependencies": { "@agoric/assert": "^0.0.7", - "@agoric/harden": "^0.0.8", "@agoric/sparse-ints": "^0.0.6" }, "devDependencies": { + "@agoric/install-ses": "0.1.0", "esm": "^3.2.25", "tap-spec": "^5.0.0", "tape": "^4.11.0", diff --git a/packages/registrar/src/registrar.js b/packages/registrar/src/registrar.js index d627a9c9cea5..f69740489099 100644 --- a/packages/registrar/src/registrar.js +++ b/packages/registrar/src/registrar.js @@ -1,6 +1,7 @@ // Copyright (C) 2019 Agoric, under Apache License 2.0 -import harden from '@agoric/harden'; +/* global harden */ + import { generateSparseInts } from '@agoric/sparse-ints'; import { assert, details } from '@agoric/assert'; diff --git a/packages/registrar/test/unitTests/test-registrar.js b/packages/registrar/test/unitTests/test-registrar.js index 5f862b0cd8c7..6ec5764ae220 100644 --- a/packages/registrar/test/unitTests/test-registrar.js +++ b/packages/registrar/test/unitTests/test-registrar.js @@ -1,3 +1,4 @@ +import '@agoric/install-ses'; import { test } from 'tape-promise/tape'; import { makeRegistrar } from '../../src/registrar'; diff --git a/packages/same-structure/package.json b/packages/same-structure/package.json index a3e4f9190a81..b25333b3bb2b 100644 --- a/packages/same-structure/package.json +++ b/packages/same-structure/package.json @@ -30,7 +30,6 @@ "homepage": "https://github.com/Agoric/agoric-sdk#readme", "dependencies": { "@agoric/assert": "^0.0.7", - "@agoric/harden": "^0.0.8", "@agoric/marshal": "^0.2.2" }, "devDependencies": { diff --git a/packages/same-structure/src/sameStructure.js b/packages/same-structure/src/sameStructure.js index d3bb846284c4..da0e48c5944f 100644 --- a/packages/same-structure/src/sameStructure.js +++ b/packages/same-structure/src/sameStructure.js @@ -1,4 +1,5 @@ -import harden from '@agoric/harden'; +/* global harden */ + import { sameValueZero, passStyleOf } from '@agoric/marshal'; import { assert, details, q } from '@agoric/assert'; diff --git a/packages/sharing-service/package.json b/packages/sharing-service/package.json index f881ccfa37a8..67047ba5c74c 100644 --- a/packages/sharing-service/package.json +++ b/packages/sharing-service/package.json @@ -26,8 +26,7 @@ }, "homepage": "https://github.com/Agoric/agoric-sdk#readme", "dependencies": { - "@agoric/assert": "^0.0.7", - "@agoric/harden": "^0.0.8" + "@agoric/assert": "^0.0.7" }, "devDependencies": { "@agoric/install-ses": "0.1.0", diff --git a/packages/sharing-service/src/sharedMap.js b/packages/sharing-service/src/sharedMap.js index 137852abc60d..89acae6219df 100644 --- a/packages/sharing-service/src/sharedMap.js +++ b/packages/sharing-service/src/sharedMap.js @@ -1,6 +1,6 @@ // Copyright (C) 2019 Agoric, under Apache License 2.0 -import harden from '@agoric/harden'; +/* global harden */ // Allows multiple parties to store values for retrieval by others. function makeSharedMap(name) { diff --git a/packages/sharing-service/src/sharing.js b/packages/sharing-service/src/sharing.js index 1e970d00d986..c392fc87b12d 100644 --- a/packages/sharing-service/src/sharing.js +++ b/packages/sharing-service/src/sharing.js @@ -1,6 +1,6 @@ // Copyright (C) 2019 Agoric, under Apache License 2.0 -import harden from '@agoric/harden'; +/* global harden */ import { assert, details } from '@agoric/assert'; import { makeSharedMap } from './sharedMap'; diff --git a/packages/sharing-service/test/swingsetTests/sharingService/bootstrap.js b/packages/sharing-service/test/swingsetTests/sharingService/bootstrap.js index 48e932571d46..fb2f63222c3c 100644 --- a/packages/sharing-service/test/swingsetTests/sharingService/bootstrap.js +++ b/packages/sharing-service/test/swingsetTests/sharingService/bootstrap.js @@ -1,6 +1,6 @@ // Copyright (C) 2019 Agoric, under Apache License 2.0 -import harden from '@agoric/harden'; +/* global harden */ import { makeSharedMap } from '../../../src/sharedMap'; import { makeSharingService } from '../../../src/sharing'; diff --git a/packages/sharing-service/test/swingsetTests/sharingService/vat-alice.js b/packages/sharing-service/test/swingsetTests/sharingService/vat-alice.js index 135dfa846763..a1567816ba50 100644 --- a/packages/sharing-service/test/swingsetTests/sharingService/vat-alice.js +++ b/packages/sharing-service/test/swingsetTests/sharingService/vat-alice.js @@ -1,6 +1,6 @@ // Copyright (C) 2019 Agoric, under Apache License 2.0 -import harden from '@agoric/harden'; +/* global harden */ function makeAliceMaker(E, _host, _log) { return harden({ diff --git a/packages/sharing-service/test/swingsetTests/sharingService/vat-bob.js b/packages/sharing-service/test/swingsetTests/sharingService/vat-bob.js index 42e7e682e101..d57ca41b5407 100644 --- a/packages/sharing-service/test/swingsetTests/sharingService/vat-bob.js +++ b/packages/sharing-service/test/swingsetTests/sharingService/vat-bob.js @@ -1,6 +1,6 @@ // Copyright (C) 2019 Agoric, under Apache License 2.0 -import harden from '@agoric/harden'; +/* global harden */ function makeBobMaker(E, _host, _log) { return harden({ diff --git a/packages/sharing-service/test/swingsetTests/sharingService/vat-sharing.js b/packages/sharing-service/test/swingsetTests/sharingService/vat-sharing.js index cd4edf2406a5..1f2f474f235c 100644 --- a/packages/sharing-service/test/swingsetTests/sharingService/vat-sharing.js +++ b/packages/sharing-service/test/swingsetTests/sharingService/vat-sharing.js @@ -1,6 +1,6 @@ // Copyright (C) 2019 Agoric, under Apache License 2.0 -import harden from '@agoric/harden'; +/* global harden */ import { makeSharingService } from '../../../src/sharing'; diff --git a/packages/sharing-service/test/unitTests/test-sharing.js b/packages/sharing-service/test/unitTests/test-sharing.js index 5cc6af47acf9..f146a678a8e1 100644 --- a/packages/sharing-service/test/unitTests/test-sharing.js +++ b/packages/sharing-service/test/unitTests/test-sharing.js @@ -1,3 +1,4 @@ +import '@agoric/install-ses'; import { test } from 'tape-promise/tape'; import { makeSharingService } from '../../src/sharing'; diff --git a/packages/sparse-ints/package.json b/packages/sparse-ints/package.json index ee64b3bc6322..08b07aa5d65e 100644 --- a/packages/sparse-ints/package.json +++ b/packages/sparse-ints/package.json @@ -26,7 +26,6 @@ }, "homepage": "https://github.com/Agoric/agoric-sdk#readme", "dependencies": { - "@agoric/harden": "^0.0.8" }, "devDependencies": { "esm": "^3.2.25", diff --git a/packages/sparse-ints/src/sparseInts.js b/packages/sparse-ints/src/sparseInts.js index 201c05f9c1aa..bf58321113e7 100644 --- a/packages/sparse-ints/src/sparseInts.js +++ b/packages/sparse-ints/src/sparseInts.js @@ -1,6 +1,6 @@ // Copyright (C) 2019 Agoric, under Apache License 2.0 -import harden from '@agoric/harden'; +/* global harden */ // Generator function to produce a stream of positive integers that are // sparsely scattered across the number space. This supports IDs that diff --git a/packages/spawner/package.json b/packages/spawner/package.json index 6a4a3560f54b..4ac694608c95 100644 --- a/packages/spawner/package.json +++ b/packages/spawner/package.json @@ -31,7 +31,6 @@ "@agoric/assert": "^0.0.7", "@agoric/ertp": "^0.5.5", "@agoric/eventual-send": "^0.9.2", - "@agoric/harden": "^0.0.8", "@agoric/import-bundle": "^0.0.7", "@agoric/nat": "^2.0.1", "@agoric/produce-promise": "^0.1.2", diff --git a/packages/spawner/src/allSettled.js b/packages/spawner/src/allSettled.js index d8975594d8a7..ba48b464d9b5 100644 --- a/packages/spawner/src/allSettled.js +++ b/packages/spawner/src/allSettled.js @@ -1,4 +1,4 @@ -import harden from '@agoric/harden'; +/* global harden */ import { producePromise } from '@agoric/produce-promise'; diff --git a/packages/spawner/src/contractHost.js b/packages/spawner/src/contractHost.js index b9bc217277dc..abbf2883629d 100644 --- a/packages/spawner/src/contractHost.js +++ b/packages/spawner/src/contractHost.js @@ -1,7 +1,8 @@ // Copyright (C) 2019 Agoric, under Apache License 2.0 +/* global harden */ + import Nat from '@agoric/nat'; -import harden from '@agoric/harden'; import { importBundle } from '@agoric/import-bundle'; import makeStore from '@agoric/weak-store'; import { assert, details } from '@agoric/assert'; diff --git a/packages/spawner/src/coveredCall.js b/packages/spawner/src/coveredCall.js index 054409831b01..1484080bfbe5 100644 --- a/packages/spawner/src/coveredCall.js +++ b/packages/spawner/src/coveredCall.js @@ -1,7 +1,7 @@ -/* global E */ // Copyright (C) 2019 Agoric, under Apache License 2.0 -import harden from '@agoric/harden'; +/* global harden E */ + import { mustBeSameStructure, sameStructure } from '@agoric/same-structure'; /** diff --git a/packages/spawner/src/escrow.js b/packages/spawner/src/escrow.js index 383c60e5a73b..a2d01a9de9ee 100644 --- a/packages/spawner/src/escrow.js +++ b/packages/spawner/src/escrow.js @@ -1,7 +1,7 @@ -/* global E producePromise */ // Copyright (C) 2019 Agoric, under Apache License 2.0 -import harden from '@agoric/harden'; +/* global harden E producePromise */ + import { mustBeSameStructure } from '@agoric/same-structure'; // For clarity, the code below internally speaks of a scenario is which Alice is diff --git a/packages/spawner/src/makeCollect.js b/packages/spawner/src/makeCollect.js index c4040126153f..4d19d4d0aedd 100644 --- a/packages/spawner/src/makeCollect.js +++ b/packages/spawner/src/makeCollect.js @@ -1,4 +1,5 @@ -import harden from '@agoric/harden'; +/* global harden */ + import { allSettled } from './allSettled'; function makeCollect(E, log) { diff --git a/packages/spawner/test/swingsetTests/contractHost/bootstrap.js b/packages/spawner/test/swingsetTests/contractHost/bootstrap.js index aa8f303fe166..360d84864b4e 100644 --- a/packages/spawner/test/swingsetTests/contractHost/bootstrap.js +++ b/packages/spawner/test/swingsetTests/contractHost/bootstrap.js @@ -1,6 +1,7 @@ // Copyright (C) 2019 Agoric, under Apache License 2.0 -import harden from '@agoric/harden'; +/* global harden */ + import makeAmountMath from '@agoric/ertp/src/amountMath'; import { bundleFunction } from '../../make-function-bundle'; diff --git a/packages/spawner/test/swingsetTests/contractHost/vat-alice.js b/packages/spawner/test/swingsetTests/contractHost/vat-alice.js index a878352a50f0..e406b306a554 100644 --- a/packages/spawner/test/swingsetTests/contractHost/vat-alice.js +++ b/packages/spawner/test/swingsetTests/contractHost/vat-alice.js @@ -1,6 +1,7 @@ // Copyright (C) 2018 Agoric, under Apache License 2.0 -import harden from '@agoric/harden'; +/* global harden */ + import { allComparable } from '@agoric/same-structure'; import makeAmountMath from '@agoric/ertp/src/amountMath'; diff --git a/packages/spawner/test/swingsetTests/contractHost/vat-bob.js b/packages/spawner/test/swingsetTests/contractHost/vat-bob.js index 9144d287f2cb..054a84547928 100644 --- a/packages/spawner/test/swingsetTests/contractHost/vat-bob.js +++ b/packages/spawner/test/swingsetTests/contractHost/vat-bob.js @@ -1,7 +1,8 @@ // Copyright (C) 2013 Google Inc, under Apache License 2.0 // Copyright (C) 2018 Agoric, under Apache License 2.0 -import harden from '@agoric/harden'; +/* global harden */ + import makeAmountMath from '@agoric/ertp/src/amountMath'; import { makeCollect } from '../../../src/makeCollect'; diff --git a/packages/spawner/test/swingsetTests/contractHost/vat-fred.js b/packages/spawner/test/swingsetTests/contractHost/vat-fred.js index 097fa3d6d80b..155e7a10fb10 100644 --- a/packages/spawner/test/swingsetTests/contractHost/vat-fred.js +++ b/packages/spawner/test/swingsetTests/contractHost/vat-fred.js @@ -1,7 +1,8 @@ // Copyright (C) 2013 Google Inc, under Apache License 2.0 // Copyright (C) 2018 Agoric, under Apache License 2.0 -import harden from '@agoric/harden'; +/* global harden */ + import makeAmountMath from '@agoric/ertp/src/amountMath'; import { allComparable } from '@agoric/same-structure'; diff --git a/packages/spawner/test/swingsetTests/contractHost/vat-host.js b/packages/spawner/test/swingsetTests/contractHost/vat-host.js index 481a9d0d0c13..73ca0b49e5de 100644 --- a/packages/spawner/test/swingsetTests/contractHost/vat-host.js +++ b/packages/spawner/test/swingsetTests/contractHost/vat-host.js @@ -1,6 +1,7 @@ // Copyright (C) 2018 Agoric, under Apache License 2.0 -import harden from '@agoric/harden'; +/* global harden */ + import { makeContractHost } from '../../../src/contractHost'; function setup(syscall, state, helpers, vatPowers0) { diff --git a/packages/spawner/test/swingsetTests/contractHost/vat-mint.js b/packages/spawner/test/swingsetTests/contractHost/vat-mint.js index 2137ddc00cf6..b342200b0973 100644 --- a/packages/spawner/test/swingsetTests/contractHost/vat-mint.js +++ b/packages/spawner/test/swingsetTests/contractHost/vat-mint.js @@ -1,6 +1,6 @@ // Copyright (C) 2019 Agoric, under Apache License 2.0 -import harden from '@agoric/harden'; +/* global harden */ import produceIssuer from '@agoric/ertp'; diff --git a/packages/spawner/test/swingsetTests/escrow/bootstrap.js b/packages/spawner/test/swingsetTests/escrow/bootstrap.js index b7496c65bbd8..dd30167572e7 100644 --- a/packages/spawner/test/swingsetTests/escrow/bootstrap.js +++ b/packages/spawner/test/swingsetTests/escrow/bootstrap.js @@ -1,6 +1,7 @@ // Copyright (C) 2019 Agoric, under Apache License 2.0 -import harden from '@agoric/harden'; +/* global harden */ + import produceIssuer from '@agoric/ertp'; import { allComparable } from '@agoric/same-structure'; import { assert, details } from '@agoric/assert'; diff --git a/packages/spawner/test/swingsetTests/escrow/vat-host.js b/packages/spawner/test/swingsetTests/escrow/vat-host.js index 481a9d0d0c13..73ca0b49e5de 100644 --- a/packages/spawner/test/swingsetTests/escrow/vat-host.js +++ b/packages/spawner/test/swingsetTests/escrow/vat-host.js @@ -1,6 +1,7 @@ // Copyright (C) 2018 Agoric, under Apache License 2.0 -import harden from '@agoric/harden'; +/* global harden */ + import { makeContractHost } from '../../../src/contractHost'; function setup(syscall, state, helpers, vatPowers0) { diff --git a/packages/spawner/test/swingsetTests/escrow/vat-mint.js b/packages/spawner/test/swingsetTests/escrow/vat-mint.js index 557e4a134d62..b342200b0973 100644 --- a/packages/spawner/test/swingsetTests/escrow/vat-mint.js +++ b/packages/spawner/test/swingsetTests/escrow/vat-mint.js @@ -1,6 +1,7 @@ // Copyright (C) 2019 Agoric, under Apache License 2.0 -import harden from '@agoric/harden'; +/* global harden */ + import produceIssuer from '@agoric/ertp'; function build(_E, _log) { diff --git a/packages/store/package.json b/packages/store/package.json index 04ed73b9c2d9..0a764d710f11 100644 --- a/packages/store/package.json +++ b/packages/store/package.json @@ -28,8 +28,7 @@ }, "homepage": "https://github.com/Agoric/agoric-sdk#readme", "dependencies": { - "@agoric/assert": "^0.0.7", - "@agoric/harden": "^0.0.8" + "@agoric/assert": "^0.0.7" }, "devDependencies": { "esm": "^3.2.25", diff --git a/packages/store/src/store.js b/packages/store/src/store.js index 2effb2253202..31685ddce7a4 100644 --- a/packages/store/src/store.js +++ b/packages/store/src/store.js @@ -1,11 +1,10 @@ // Copyright (C) 2019 Agoric, under Apache license 2.0 + +/* global harden */ // @ts-check -import rawHarden from '@agoric/harden'; import { assert, details, q } from '@agoric/assert'; -const harden = /** @type {(x: T) => T} */ (rawHarden); - /** * @template K,V * @typedef {Object} Store A wrapper around a Map diff --git a/packages/weak-store/package.json b/packages/weak-store/package.json index 3ca791823887..5b3784f90c33 100644 --- a/packages/weak-store/package.json +++ b/packages/weak-store/package.json @@ -26,8 +26,7 @@ }, "homepage": "https://github.com/Agoric/agoric-sdk#readme", "dependencies": { - "@agoric/assert": "^0.0.7", - "@agoric/harden": "^0.0.8" + "@agoric/assert": "^0.0.7" }, "devDependencies": { "esm": "^3.2.25", diff --git a/packages/weak-store/src/weakStore.js b/packages/weak-store/src/weakStore.js index 94ac02b11beb..75c03640a799 100644 --- a/packages/weak-store/src/weakStore.js +++ b/packages/weak-store/src/weakStore.js @@ -1,6 +1,7 @@ // Copyright (C) 2019 Agoric, under Apache license 2.0 -import harden from '@agoric/harden'; +/* global harden */ + import { assert, details, q } from '@agoric/assert'; /** * Distinguishes between adding a new key (init) and updating or