From 48ef7c4879333ddc826a6a8092a04119b672d877 Mon Sep 17 00:00:00 2001 From: Trevor Moody Date: Thu, 11 Dec 2025 12:55:08 +0000 Subject: [PATCH 01/10] fix: @sasjs/core path for npx execution edge case --- src/utils/setConstants.ts | 23 +++++++++++++++++++++-- 1 file changed, 21 insertions(+), 2 deletions(-) diff --git a/src/utils/setConstants.ts b/src/utils/setConstants.ts index f8574098..d25455b6 100644 --- a/src/utils/setConstants.ts +++ b/src/utils/setConstants.ts @@ -43,7 +43,26 @@ export const setConstants = async ( const buildDestinationJobsFolder = path.join(buildDestinationFolder, 'jobs') const buildDestinationDbFolder = path.join(buildDestinationFolder, 'db') const buildDestinationDocsFolder = path.join(buildDestinationFolder, 'docs') - const macroCorePath = await getNodeModulePath('@sasjs/core') + // Arriving here from a `@sasjs/cli` command invoked with `npx` can result + // in no discoverable installation of '@sasjs/core' for getNodeModulePath() + // to find (`npx` will have cached the @sasjs/cli dependencies in a temporary + // area). + let macroCorePath = await getNodeModulePath('@sasjs/core') + if ( macroCorePath === '' ) { + // If @sasjs/core was not found, check for and use an environment + // variable with the same name as the variable we are setting. + macroCorePath = process.env.macroCorePath as string ?? '' + if ( macroCorePath === '' ) { + throw new Error( + `@sasjs/core folder location is unknown.\n` + + `Either install @sasjs/core, install @sasjs/cli, or declare an ` + + `environment variable named\n'macroCorePath' containing the path to ` + + `the @sasjs/core root folder.\n` + + `Note: 'npx' invocations of @sasjs/cli do not install a discoverable ` + + `@sasjs/core dependency.` + ) + } + } const buildDestinationResultsFolder = getAbsolutePath( buildResultsFolder, @@ -81,4 +100,4 @@ export const setConstants = async ( invalidSasError, sas9GUID } -} +} \ No newline at end of file From 13a28e3ba6977ce6a2ccb474a151449dbef40cc7 Mon Sep 17 00:00:00 2001 From: Trevor Moody Date: Thu, 11 Dec 2025 14:16:29 +0000 Subject: [PATCH 02/10] fix: thrown macroCorePath error moved to appropriate location --- src/commands/build/build.ts | 15 +++++++++++++-- src/utils/setConstants.ts | 11 +---------- 2 files changed, 14 insertions(+), 12 deletions(-) diff --git a/src/commands/build/build.ts b/src/commands/build/build.ts index e1b80e15..7b046720 100644 --- a/src/commands/build/build.ts +++ b/src/commands/build/build.ts @@ -203,11 +203,11 @@ ${ * The serverName represents the SAS 9 logical server context * There is no programmatic (SAS code) way to obtain this * So it is taken from the sasjsconfig file OR supplied at runtime, eg: - * + * * %let apploc=/my/apploc; * %let serverName=SASAppDC; * %inc thisfile; - * + * */ %global serverName; @@ -235,6 +235,17 @@ ${removeHeader(buildConfig)} async function getCreateWebServiceScript(serverType: ServerType) { const { macroCorePath } = process.sasjsConstants + if ( macroCorePath === '' ) { + throw new Error( + `The @sasjs/core folder location is unknown.\n` + + `Either install @sasjs/core, install @sasjs/cli, or declare an ` + + `environment variable named\n'macroCorePath' containing the path to ` + + `the @sasjs/core root folder.\n` + + `Note: 'npx' invocations of @sasjs/cli do not install a discoverable ` + + `@sasjs/core dependency.` + ) + } + switch (serverType) { case ServerType.SasViya: return await readFile(`${macroCorePath}/viya/mv_createwebservice.sas`) diff --git a/src/utils/setConstants.ts b/src/utils/setConstants.ts index d25455b6..0cb183a9 100644 --- a/src/utils/setConstants.ts +++ b/src/utils/setConstants.ts @@ -52,16 +52,7 @@ export const setConstants = async ( // If @sasjs/core was not found, check for and use an environment // variable with the same name as the variable we are setting. macroCorePath = process.env.macroCorePath as string ?? '' - if ( macroCorePath === '' ) { - throw new Error( - `@sasjs/core folder location is unknown.\n` + - `Either install @sasjs/core, install @sasjs/cli, or declare an ` + - `environment variable named\n'macroCorePath' containing the path to ` + - `the @sasjs/core root folder.\n` + - `Note: 'npx' invocations of @sasjs/cli do not install a discoverable ` + - `@sasjs/core dependency.` - ) - } + } const buildDestinationResultsFolder = getAbsolutePath( From bfb6d4c51a9112cf23e30b1e754003f0f046a395 Mon Sep 17 00:00:00 2001 From: Trevor Moody Date: Thu, 11 Dec 2025 14:29:27 +0000 Subject: [PATCH 03/10] fix: Throw macroCorePath error at earliest 'build' opportunity --- src/commands/build/build.ts | 24 +++++++++++++----------- 1 file changed, 13 insertions(+), 11 deletions(-) diff --git a/src/commands/build/build.ts b/src/commands/build/build.ts index 7b046720..abedd9dc 100644 --- a/src/commands/build/build.ts +++ b/src/commands/build/build.ts @@ -31,6 +31,19 @@ import { getBuildInit, getBuildTerm } from './internal/config' import { getLaunchPageCode } from './internal/getLaunchPageCode' export async function build(target: Target) { + const { macroCorePath } = process.sasjsConstants + + if ( macroCorePath === '' ) { + throw new Error( + `The @sasjs/core folder location is unknown.\n` + + `Either install @sasjs/core, install @sasjs/cli, or declare an ` + + `environment variable named\n'macroCorePath' containing the path to ` + + `the @sasjs/core root folder.\n` + + `Note: 'npx' invocations of @sasjs/cli do not install a discoverable ` + + `@sasjs/core dependency.` + ) + } + if ( process.sasjsConstants.buildDestinationFolder && !(await folderExists(process.sasjsConstants.buildDestinationFolder)) @@ -235,17 +248,6 @@ ${removeHeader(buildConfig)} async function getCreateWebServiceScript(serverType: ServerType) { const { macroCorePath } = process.sasjsConstants - if ( macroCorePath === '' ) { - throw new Error( - `The @sasjs/core folder location is unknown.\n` + - `Either install @sasjs/core, install @sasjs/cli, or declare an ` + - `environment variable named\n'macroCorePath' containing the path to ` + - `the @sasjs/core root folder.\n` + - `Note: 'npx' invocations of @sasjs/cli do not install a discoverable ` + - `@sasjs/core dependency.` - ) - } - switch (serverType) { case ServerType.SasViya: return await readFile(`${macroCorePath}/viya/mv_createwebservice.sas`) From 7b0626a278a4056a5400b908d9c89c04c0c7d773 Mon Sep 17 00:00:00 2001 From: Trevor Moody Date: Thu, 11 Dec 2025 14:52:18 +0000 Subject: [PATCH 04/10] chore: blank line did not belong --- src/utils/setConstants.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/src/utils/setConstants.ts b/src/utils/setConstants.ts index 0cb183a9..145f7a90 100644 --- a/src/utils/setConstants.ts +++ b/src/utils/setConstants.ts @@ -52,7 +52,6 @@ export const setConstants = async ( // If @sasjs/core was not found, check for and use an environment // variable with the same name as the variable we are setting. macroCorePath = process.env.macroCorePath as string ?? '' - } const buildDestinationResultsFolder = getAbsolutePath( From 09fdb53d19dfac54c3d6d8adb3def76adec9701a Mon Sep 17 00:00:00 2001 From: Trevor Moody Date: Thu, 11 Dec 2025 15:10:25 +0000 Subject: [PATCH 05/10] fix: lint adjustments --- src/commands/build/build.ts | 12 ++++++------ src/utils/setConstants.ts | 6 +++--- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/commands/build/build.ts b/src/commands/build/build.ts index abedd9dc..a141ccfc 100644 --- a/src/commands/build/build.ts +++ b/src/commands/build/build.ts @@ -33,14 +33,14 @@ import { getLaunchPageCode } from './internal/getLaunchPageCode' export async function build(target: Target) { const { macroCorePath } = process.sasjsConstants - if ( macroCorePath === '' ) { + if (macroCorePath === '') { throw new Error( `The @sasjs/core folder location is unknown.\n` + - `Either install @sasjs/core, install @sasjs/cli, or declare an ` + - `environment variable named\n'macroCorePath' containing the path to ` + - `the @sasjs/core root folder.\n` + - `Note: 'npx' invocations of @sasjs/cli do not install a discoverable ` + - `@sasjs/core dependency.` + `Either install @sasjs/core, install @sasjs/cli, or declare an ` + + `environment variable named\n'macroCorePath' containing the path to ` + + `the @sasjs/core root folder.\n` + + `Note: 'npx' invocations of @sasjs/cli do not install a discoverable ` + + `@sasjs/core dependency.` ) } diff --git a/src/utils/setConstants.ts b/src/utils/setConstants.ts index 145f7a90..d900a509 100644 --- a/src/utils/setConstants.ts +++ b/src/utils/setConstants.ts @@ -48,10 +48,10 @@ export const setConstants = async ( // to find (`npx` will have cached the @sasjs/cli dependencies in a temporary // area). let macroCorePath = await getNodeModulePath('@sasjs/core') - if ( macroCorePath === '' ) { + if (macroCorePath === '') { // If @sasjs/core was not found, check for and use an environment // variable with the same name as the variable we are setting. - macroCorePath = process.env.macroCorePath as string ?? '' + macroCorePath = (process.env.macroCorePath as string) ?? '' } const buildDestinationResultsFolder = getAbsolutePath( @@ -90,4 +90,4 @@ export const setConstants = async ( invalidSasError, sas9GUID } -} \ No newline at end of file +} From 6db4ba75bb180677d04a80ed7e4bd17efc249396 Mon Sep 17 00:00:00 2001 From: Trevor Moody Date: Thu, 11 Dec 2025 23:07:29 +0000 Subject: [PATCH 06/10] fix: use require.resolve() to better locate package paths --- src/commands/build/build.ts | 9 ++++----- src/utils/setConstants.ts | 19 +++++++++++-------- src/utils/utils.ts | 33 +++++++++------------------------ 3 files changed, 24 insertions(+), 37 deletions(-) diff --git a/src/commands/build/build.ts b/src/commands/build/build.ts index a141ccfc..46bf6e4d 100644 --- a/src/commands/build/build.ts +++ b/src/commands/build/build.ts @@ -36,13 +36,12 @@ export async function build(target: Target) { if (macroCorePath === '') { throw new Error( `The @sasjs/core folder location is unknown.\n` + - `Either install @sasjs/core, install @sasjs/cli, or declare an ` + - `environment variable named\n'macroCorePath' containing the path to ` + - `the @sasjs/core root folder.\n` + - `Note: 'npx' invocations of @sasjs/cli do not install a discoverable ` + - `@sasjs/core dependency.` + `Check that @sasjs/core is a dependency in the package.json, or\n` + + `populate environment variable 'macroCorePath' with the path to\n` + + `a local @sasjs/core package's root directory.` ) } + process.logger?.info(`@sasjs/core found at ${macroCorePath}`) if ( process.sasjsConstants.buildDestinationFolder && diff --git a/src/utils/setConstants.ts b/src/utils/setConstants.ts index d900a509..cb501ae3 100644 --- a/src/utils/setConstants.ts +++ b/src/utils/setConstants.ts @@ -43,15 +43,18 @@ export const setConstants = async ( const buildDestinationJobsFolder = path.join(buildDestinationFolder, 'jobs') const buildDestinationDbFolder = path.join(buildDestinationFolder, 'db') const buildDestinationDocsFolder = path.join(buildDestinationFolder, 'docs') - // Arriving here from a `@sasjs/cli` command invoked with `npx` can result - // in no discoverable installation of '@sasjs/core' for getNodeModulePath() - // to find (`npx` will have cached the @sasjs/cli dependencies in a temporary - // area). - let macroCorePath = await getNodeModulePath('@sasjs/core') + // Edge case: @sasjs/cli has a dependency on @sasjs/core. + // When @sasjs/cli is used to submit a test of the @sasjs/core + // repo, it is desirable to use that @sasjs/core repo as the dependency rather + // than the older version in @sasjs/cli node_modules. + // To achieve this, set environment variable `macroCorePath` to the root dir + // of the local @sasjs/core package. If found, this takes precedence over + // any node_modules installations of @sasjs/core. + let macroCorePath = (process.env.macroCorePath as string) ?? '' if (macroCorePath === '') { - // If @sasjs/core was not found, check for and use an environment - // variable with the same name as the variable we are setting. - macroCorePath = (process.env.macroCorePath as string) ?? '' + // If no environment variable is set/populated then check for an installed + // @sasjs/core in locations known to node. + macroCorePath = await getNodeModulePath('@sasjs/core') } const buildDestinationResultsFolder = getAbsolutePath( diff --git a/src/utils/utils.ts b/src/utils/utils.ts index 7e29c241..ffd17284 100644 --- a/src/utils/utils.ts +++ b/src/utils/utils.ts @@ -552,30 +552,15 @@ export const isSASjsProject = async () => { } export const getNodeModulePath = async (module: string): Promise => { - // Check if module is present in project's dependencies - const projectPath = path.join(process.cwd(), 'node_modules', module) - - if (await folderExists(projectPath)) return projectPath - - // Check if module is present in @sasjs/cli located in project's dependencies - const cliDepsPath = path.join('@sasjs', 'cli', 'node_modules') - const cliLocalPath = path.join( - process.cwd(), - 'node_modules', - cliDepsPath, - module - ) - - if (await folderExists(cliLocalPath)) return cliLocalPath - - // Check if module is present in global @sasjs/cli - const cliGlobalPath = path.join( - shelljs.exec(`npm root -g`, { silent: true }).stdout.replace(/\n/, ''), - cliDepsPath, - module - ) - - if (await folderExists(cliGlobalPath)) return cliGlobalPath + // Look for ${module}/package.json, then return only the path + try { + const nodePackagePath = path.dirname( + require.resolve(path.join(module, 'package.json')) + ) + if (nodePackagePath) return nodePackagePath + } catch (e: any) { + if (e.code !== 'MODULE_NOT_FOUND') throw e + } // Return default value return '' From 0069ed08c0051bf38297d34a01bd8cfb6e5d7994 Mon Sep 17 00:00:00 2001 From: Trevor Moody Date: Fri, 12 Dec 2025 18:17:49 +0000 Subject: [PATCH 07/10] fix: add new tests --- src/utils/spec/setConstants.spec.ts | 54 +++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) diff --git a/src/utils/spec/setConstants.spec.ts b/src/utils/spec/setConstants.spec.ts index ddfd7302..072f1bad 100644 --- a/src/utils/spec/setConstants.spec.ts +++ b/src/utils/spec/setConstants.spec.ts @@ -3,9 +3,11 @@ import path from 'path' import * as configUtils from '../config' import { setConstants } from '../setConstants' import * as fileModule from '@sasjs/utils/file' +import * as utils from '../utils' describe('setConstants', () => { let config: Configuration + const origProcessEnv = process.env beforeAll(async () => { ;({ config } = JSON.parse( @@ -13,6 +15,10 @@ describe('setConstants', () => { )) }) + afterEach(() => { + process.env = { ...origProcessEnv } + }) + test('should set constants inside appFolder when @sasjs/core dependency is present', async () => { const appFolder = ['some', 'app', 'folder'].join(path.sep) process.projectDir = appFolder @@ -81,6 +87,54 @@ describe('setConstants', () => { verifySasjsConstants(undefined, false, false) }) + + test('should call getNodeModulePath once when environment variable macroCorePath is undefined', async () => { + process.env.macroCorePath = undefined + + const getNodeModulePathSpy = jest + .spyOn(utils, 'getNodeModulePath') + .mockImplementation(async (packageName: string) => + Promise.resolve( + path.join('some', 'app', 'folder', 'node_modules', packageName) + ) + ) + + await setConstants() + + expect(getNodeModulePathSpy).toHaveBeenCalledOnceWith('@sasjs/core') + }) + + test('should not call getNodeModulePath when environment variable macroCorePath is blank', async () => { + process.env.macroCorePath = '' + + const getNodeModulePathSpy = jest + .spyOn(utils, 'getNodeModulePath') + .mockImplementation(async (packageName: string) => + Promise.resolve( + path.join('some', 'app', 'folder', 'node_modules', packageName) + ) + ) + + await setConstants() + + expect(getNodeModulePathSpy).toHaveBeenCalledOnceWith('@sasjs/core') + }) + + test('should not call getNodeModulePath when environment variable macroCorePath is populated', async () => { + process.env.macroCorePath = '../core' + + const getNodeModulePathSpy = jest + .spyOn(utils, 'getNodeModulePath') + .mockImplementation(async (packageName: string) => + Promise.resolve( + path.join('some', 'app', 'folder', 'node_modules', packageName) + ) + ) + + await setConstants() + + expect(getNodeModulePathSpy).toBeCalledTimes(0) + }) }) const verifySasjsConstants = ( From f2c9bb581f5b593bb248604d606fa5f1a6c9f425 Mon Sep 17 00:00:00 2001 From: Trevor Moody Date: Fri, 12 Dec 2025 22:36:47 +0000 Subject: [PATCH 08/10] fix: reshaped setConstants tests to fit new getNodeModulePath --- src/commands/build/build.ts | 7 ++-- src/utils/spec/setConstants.spec.ts | 60 ++++++++++------------------- 2 files changed, 25 insertions(+), 42 deletions(-) diff --git a/src/commands/build/build.ts b/src/commands/build/build.ts index 46bf6e4d..e0052d24 100644 --- a/src/commands/build/build.ts +++ b/src/commands/build/build.ts @@ -36,9 +36,10 @@ export async function build(target: Target) { if (macroCorePath === '') { throw new Error( `The @sasjs/core folder location is unknown.\n` + - `Check that @sasjs/core is a dependency in the package.json, or\n` + - `populate environment variable 'macroCorePath' with the path to\n` + - `a local @sasjs/core package's root directory.` + `Check that @sasjs/core is a dependency in the package.json, and \n` + + `that the package has been installed.\n` + + `Alternatively populate environment variable 'macroCorePath' with\n` + + `the path to a local @sasjs/core package's root directory.` ) } process.logger?.info(`@sasjs/core found at ${macroCorePath}`) diff --git a/src/utils/spec/setConstants.spec.ts b/src/utils/spec/setConstants.spec.ts index 072f1bad..542cdf42 100644 --- a/src/utils/spec/setConstants.spec.ts +++ b/src/utils/spec/setConstants.spec.ts @@ -20,8 +20,7 @@ describe('setConstants', () => { }) test('should set constants inside appFolder when @sasjs/core dependency is present', async () => { - const appFolder = ['some', 'app', 'folder'].join(path.sep) - process.projectDir = appFolder + process.projectDir = process.cwd() jest .spyOn(configUtils, 'getLocalOrGlobalConfig') @@ -32,14 +31,8 @@ describe('setConstants', () => { }) ) - jest.spyOn(process, 'cwd').mockImplementation(() => appFolder) - const hasSasjsCore = true - jest - .spyOn(fileModule, 'folderExists') - .mockImplementation((path: string) => Promise.resolve(hasSasjsCore)) - await setConstants() verifySasjsConstants(process.projectDir, hasSasjsCore) @@ -48,6 +41,7 @@ describe('setConstants', () => { test('should set constants inside appFolder when @sasjs/core dependency is not present', async () => { const appFolder = ['some', 'app', 'folder'].join(path.sep) process.projectDir = appFolder + process.env.macroCorePath = undefined jest .spyOn(configUtils, 'getLocalOrGlobalConfig') @@ -60,13 +54,7 @@ describe('setConstants', () => { jest.spyOn(process, 'cwd').mockImplementation(() => appFolder) - jest - .spyOn(fileModule, 'folderExists') - .mockImplementation((folderPath: string) => - Promise.resolve( - folderPath !== path.join(appFolder, 'node_modules', '@sasjs', 'core') - ) - ) + jest.spyOn(utils, 'getNodeModulePath').mockImplementation(async () => '') await setConstants() @@ -74,6 +62,8 @@ describe('setConstants', () => { }) test('should set constants outside appFolder', async () => { + process.env.macroCorePath = undefined + jest .spyOn(configUtils, 'getLocalOrGlobalConfig') .mockImplementation(async () => @@ -83,6 +73,8 @@ describe('setConstants', () => { }) ) + jest.spyOn(utils, 'getNodeModulePath').mockImplementation(async () => '') + await setConstants(false) verifySasjsConstants(undefined, false, false) @@ -93,27 +85,19 @@ describe('setConstants', () => { const getNodeModulePathSpy = jest .spyOn(utils, 'getNodeModulePath') - .mockImplementation(async (packageName: string) => - Promise.resolve( - path.join('some', 'app', 'folder', 'node_modules', packageName) - ) - ) + .mockImplementation(async (packageName: string) => Promise.resolve('')) await setConstants() expect(getNodeModulePathSpy).toHaveBeenCalledOnceWith('@sasjs/core') }) - test('should not call getNodeModulePath when environment variable macroCorePath is blank', async () => { + test('should call getNodeModulePath once when environment variable macroCorePath is blank', async () => { process.env.macroCorePath = '' const getNodeModulePathSpy = jest .spyOn(utils, 'getNodeModulePath') - .mockImplementation(async (packageName: string) => - Promise.resolve( - path.join('some', 'app', 'folder', 'node_modules', packageName) - ) - ) + .mockImplementation(async (packageName: string) => Promise.resolve('')) await setConstants() @@ -125,11 +109,7 @@ describe('setConstants', () => { const getNodeModulePathSpy = jest .spyOn(utils, 'getNodeModulePath') - .mockImplementation(async (packageName: string) => - Promise.resolve( - path.join('some', 'app', 'folder', 'node_modules', packageName) - ) - ) + .mockImplementation(async (packageName: string) => Promise.resolve('')) await setConstants() @@ -180,15 +160,17 @@ const verifySasjsConstants = ( path.join(prefixAppFolder, isLocal ? '' : '.sasjs', 'sasjsbuild', 'tests') ) - const corePath = hasSasjsCore - ? 'core' - : path.join('cli', 'node_modules', '@sasjs', 'core') + const corePath = hasSasjsCore ? 'core' : '' - if (appFolder) { - expect(sasjsConstants.macroCorePath).toEqual( - path.join(prefixAppFolder, 'node_modules', '@sasjs', corePath) - ) + if (hasSasjsCore) { + if (appFolder) { + expect(sasjsConstants.macroCorePath).toEqual( + path.join(prefixAppFolder, 'node_modules', '@sasjs', corePath) + ) + } else { + expect(sasjsConstants.macroCorePath).toEqual(expect.toEndWith(corePath)) + } } else { - expect(sasjsConstants.macroCorePath).toEqual(expect.toEndWith(corePath)) + expect(sasjsConstants.macroCorePath).toEqual(corePath) } } From 4e460659f94fb452d279a5958094ef9d9c38510c Mon Sep 17 00:00:00 2001 From: Trevor Moody Date: Fri, 12 Dec 2025 23:18:37 +0000 Subject: [PATCH 09/10] chore: housekeeping to harden against npm attacks and CRLF --- .gitattributes | 1 + .npmrc | 1 + package.json | 1 - 3 files changed, 2 insertions(+), 1 deletion(-) create mode 100644 .gitattributes create mode 100644 .npmrc diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 00000000..94f480de --- /dev/null +++ b/.gitattributes @@ -0,0 +1 @@ +* text=auto eol=lf \ No newline at end of file diff --git a/.npmrc b/.npmrc new file mode 100644 index 00000000..537f81f5 --- /dev/null +++ b/.npmrc @@ -0,0 +1 @@ +ignore-scripts=true \ No newline at end of file diff --git a/package.json b/package.json index c93f1a4b..71422142 100644 --- a/package.json +++ b/package.json @@ -19,7 +19,6 @@ "test:mocked": "jest --silent --runInBand --config=jest.config.js --coverage", "lint:fix": "npx prettier --write \"{src,test}/**/*.{ts,tsx,js,jsx,html,css,sass,less,yml,md,graphql}\"", "lint": "npx prettier --check \"{src,test}/**/*.{ts,tsx,js,jsx,html,css,sass,less,yml,md,graphql}\"", - "preinstall": "npm run nodeVersionMessage", "prepare": "git rev-parse --git-dir && git config core.hooksPath ./.git-hooks || true", "doc": "npx compodoc -p tsconfig.doc.json --coverageTest 16 --coverageTestThresholdFail" }, From 99bc3ba14e4dd9c593a0701385542540bcacace8 Mon Sep 17 00:00:00 2001 From: Trevor Moody Date: Tue, 16 Dec 2025 11:56:20 +0000 Subject: [PATCH 10/10] chore(deps): bumped @sasjs/adapter to v4.16.1 --- package-lock.json | 57 ++++++++++++++++++++++++++++++++++------------- package.json | 2 +- 2 files changed, 42 insertions(+), 17 deletions(-) diff --git a/package-lock.json b/package-lock.json index 9f8cbe14..54c2b6af 100644 --- a/package-lock.json +++ b/package-lock.json @@ -6,10 +6,9 @@ "packages": { "": { "name": "@sasjs/cli", - "hasInstallScript": true, "license": "ISC", "dependencies": { - "@sasjs/adapter": "^4.16.0", + "@sasjs/adapter": "^4.16.1", "@sasjs/core": "4.59.9", "@sasjs/lint": "2.4.3", "@sasjs/utils": "3.5.2", @@ -108,7 +107,6 @@ "integrity": "sha512-D58mjF+Y+89UfbMJpV57UTCg+JRQIFgvROPfH7mmIfBcoFVMkwiiiJyzPyW3onN9kg9noDg7MVyI+Yt64bnfQQ==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "@ampproject/remapping": "^2.2.0", "@babel/code-frame": "^7.21.4", @@ -2301,13 +2299,12 @@ } }, "node_modules/@sasjs/adapter": { - "version": "4.16.0", - "resolved": "https://registry.npmjs.org/@sasjs/adapter/-/adapter-4.16.0.tgz", - "integrity": "sha512-DzF/+s++FtSfuBmONicBbgeKI8feiwDOm1iKWlcDlmHCPmHIoj1IbI0v2fGktzurnE37/vkyp6dvHO+FhwI87Q==", - "hasInstallScript": true, + "version": "4.16.1", + "resolved": "https://registry.npmjs.org/@sasjs/adapter/-/adapter-4.16.1.tgz", + "integrity": "sha512-NsW9f5n9USYJbRe7f7AghfopVegI4lDKBn8dixopGnqbmGsTmMaZOdSOiKmmRmm0qrxet/MAor7h6ic/vqDCLA==", "license": "ISC", "dependencies": { - "@sasjs/utils": "3.5.2", + "@sasjs/utils": "3.5.6", "axios": "1.12.2", "axios-cookiejar-support": "5.0.5", "form-data": "4.0.4", @@ -2315,6 +2312,41 @@ "tough-cookie": "4.1.3" } }, + "node_modules/@sasjs/adapter/node_modules/@sasjs/utils": { + "version": "3.5.6", + "resolved": "https://registry.npmjs.org/@sasjs/utils/-/utils-3.5.6.tgz", + "integrity": "sha512-jx8zWSOysDD66vTjA0BWiZ8bcFqmqh8F+56fUCgLmJhm89eDbKrGF3mDKMQx3UE7d2+gxp9xYhJCdaBWz0Dlxw==", + "license": "ISC", + "dependencies": { + "@fast-csv/format": "4.3.5", + "@types/fs-extra": "11.0.4", + "@types/prompts": "2.0.13", + "chalk": "4.1.1", + "cli-table": "0.3.6", + "consola": "2.15.0", + "find": "0.3.0", + "fs-extra": "11.3.0", + "jwt-decode": "3.1.2", + "prompts": "2.4.1", + "valid-url": "1.0.9" + } + }, + "node_modules/@sasjs/adapter/node_modules/chalk": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.1.tgz", + "integrity": "sha512-diHzdDKxcU+bAsUboHLPEDQiw0qEe0qd7SYUn3HgcFlWgbDcfLGswOHYeGrHKzG9z6UYf01d9VFMfZxPM1xZSg==", + "license": "MIT", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, "node_modules/@sasjs/core": { "version": "4.59.9", "resolved": "https://registry.npmjs.org/@sasjs/core/-/core-4.59.9.tgz", @@ -2639,8 +2671,7 @@ "version": "18.14.1", "resolved": "https://registry.npmjs.org/@types/node/-/node-18.14.1.tgz", "integrity": "sha512-QH+37Qds3E0eDlReeboBxfHbX9omAcBCXEzswCu6jySP642jiM3cYSIkU/REqwhCUqXdonHFuBfJDiAJxMNhaQ==", - "license": "MIT", - "peer": true + "license": "MIT" }, "node_modules/@types/prompts": { "version": "2.0.13", @@ -2879,7 +2910,6 @@ "resolved": "https://registry.npmjs.org/axios/-/axios-1.12.2.tgz", "integrity": "sha512-vMJzPewAlRyOgxV2dU0Cuz2O8zzzx9VYtbJOaBgXFeLc4IV/Eg50n4LowmehOOR61S8ZMpc2K5Sa7g6A4jfkUw==", "license": "MIT", - "peer": true, "dependencies": { "follow-redirects": "^1.15.6", "form-data": "^4.0.4", @@ -3195,7 +3225,6 @@ } ], "license": "MIT", - "peer": true, "dependencies": { "caniuse-lite": "^1.0.30001688", "electron-to-chromium": "^1.5.73", @@ -4991,7 +5020,6 @@ "integrity": "sha512-XvK65feuEFGZT8OO0fB/QAQS+LGHvQpaadkH5p47/j3Ocqq3xf2pK9R+G0GzgfuhXVxEv76qCOOcMb5efLk6PA==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "@jest/core": "^29.4.3", "@jest/types": "^29.4.3", @@ -7349,7 +7377,6 @@ "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-4.1.3.tgz", "integrity": "sha512-aX/y5pVRkfRnfmuX+OdbSdXvPe6ieKX/G2s7e98f4poJHnqH3281gDPm/metm6E/WRamfx7WC4HUqkWHfQHprw==", "license": "BSD-3-Clause", - "peer": true, "dependencies": { "psl": "^1.1.33", "punycode": "^2.1.1", @@ -7456,7 +7483,6 @@ "integrity": "sha512-g0FlPvvCXSIO1JDF6S232P5jPYqBkRL9qly81ZgAOSU7rwI0stphCgd2kLiCrU9DjQCrJMWEqcNSjQL02s6d8A==", "dev": true, "license": "MIT", - "peer": true, "dependencies": { "@cspotcode/source-map-support": "0.7.0", "@tsconfig/node10": "^1.0.7", @@ -7529,7 +7555,6 @@ "integrity": "sha512-1FXk9E2Hm+QzZQ7z+McJiHL4NW1F2EzMu9Nq9i3zAaGqibafqYwCVU6WyWAuyQRRzOlxou8xZSyXLEN8oKj24g==", "dev": true, "license": "Apache-2.0", - "peer": true, "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" diff --git a/package.json b/package.json index 71422142..52cf9927 100644 --- a/package.json +++ b/package.json @@ -50,7 +50,7 @@ "access": "public" }, "dependencies": { - "@sasjs/adapter": "^4.16.0", + "@sasjs/adapter": "^4.16.1", "@sasjs/core": "4.59.9", "@sasjs/lint": "2.4.3", "@sasjs/utils": "3.5.2",