@salesforce/core-bundle 7.4.1 → 7.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.d.ts +16 -52
- package/lib/index.js +91 -58
- package/lib/pino-file.js +26 -11
- package/lib/pino-pretty.js +86 -31
- package/lib/pino-worker.js +133 -68
- package/lib/thread-stream-worker.js +5 -1
- package/package.json +7 -7
- package/lib/pino-pipeline-worker.js +0 -87
package/lib/index.d.ts
CHANGED
@@ -1675,7 +1675,7 @@ declare module '@salesforce/core-bundle/index' {
|
|
1675
1675
|
export { Messages, StructuredMessage } from '@salesforce/core-bundle/messages';
|
1676
1676
|
export { Org, SandboxProcessObject, StatusEvent, SandboxInfo, SandboxEvents, SandboxUserAuthResponse, SandboxUserAuthRequest, SandboxRequest, ResumeSandboxRequest, OrgTypes, ResultEvent, ScratchOrgRequest, } from '@salesforce/core-bundle/org/org';
|
1677
1677
|
export { OrgConfigProperties, ORG_CONFIG_ALLOWED_PROPERTIES } from '@salesforce/core-bundle/org/orgConfigProperties';
|
1678
|
-
export {
|
1678
|
+
export { NamedPackageDir, SfProject, SfProjectJson } from '@salesforce/core-bundle/sfProject';
|
1679
1679
|
export { SchemaValidator } from '@salesforce/core-bundle/schema/validator';
|
1680
1680
|
export { SfError } from '@salesforce/core-bundle/sfError';
|
1681
1681
|
export { PollingClient } from '@salesforce/core-bundle/status/pollingClient';
|
@@ -4519,42 +4519,10 @@ declare module '@salesforce/core-bundle/sfError' {
|
|
4519
4519
|
}
|
4520
4520
|
declare module '@salesforce/core-bundle/sfProject' {
|
4521
4521
|
import { Dictionary, JsonMap, Nullable, Optional } from '@salesforce/ts-types';
|
4522
|
+
import { PackageDir, ProjectJson as ProjectJsonSchema, PackagePackageDir } from '@salesforce/schemas';
|
4522
4523
|
import { ConfigFile } from '@salesforce/core-bundle/config/configFile';
|
4523
4524
|
import { ConfigContents } from '@salesforce/core-bundle/config/configStackTypes';
|
4524
|
-
|
4525
|
-
[k: string]: unknown;
|
4526
|
-
package: string;
|
4527
|
-
versionNumber?: string;
|
4528
|
-
};
|
4529
|
-
export type PackageDir = {
|
4530
|
-
ancestorId?: string;
|
4531
|
-
ancestorVersion?: string;
|
4532
|
-
default?: boolean;
|
4533
|
-
definitionFile?: string;
|
4534
|
-
dependencies?: PackageDirDependency[];
|
4535
|
-
includeProfileUserLicenses?: boolean;
|
4536
|
-
package?: string;
|
4537
|
-
packageMetadataAccess?: {
|
4538
|
-
permissionSets: string | string[];
|
4539
|
-
permissionSetLicenses: string | string[];
|
4540
|
-
};
|
4541
|
-
path: string;
|
4542
|
-
postInstallScript?: string;
|
4543
|
-
postInstallUrl?: string;
|
4544
|
-
releaseNotesUrl?: string;
|
4545
|
-
scopeProfiles?: boolean;
|
4546
|
-
uninstallScript?: string;
|
4547
|
-
versionDescription?: string;
|
4548
|
-
versionName?: string;
|
4549
|
-
versionNumber?: string;
|
4550
|
-
unpackagedMetadata?: {
|
4551
|
-
path: string;
|
4552
|
-
};
|
4553
|
-
seedMetadata?: {
|
4554
|
-
path: string;
|
4555
|
-
};
|
4556
|
-
};
|
4557
|
-
export type NamedPackageDir = PackageDir & {
|
4525
|
+
type NameAndFullPath = {
|
4558
4526
|
/**
|
4559
4527
|
* The [normalized](https://nodejs.org/api/path.html#path_path_normalize_path) path used as the package name.
|
4560
4528
|
*/
|
@@ -4564,20 +4532,9 @@ declare module '@salesforce/core-bundle/sfProject' {
|
|
4564
4532
|
*/
|
4565
4533
|
fullPath: string;
|
4566
4534
|
};
|
4567
|
-
export type
|
4568
|
-
|
4569
|
-
|
4570
|
-
sourceApiVersion?: string;
|
4571
|
-
sfdcLoginUrl?: string;
|
4572
|
-
signupTargetLoginUrl?: string;
|
4573
|
-
oauthLocalPort?: number;
|
4574
|
-
plugins?: {
|
4575
|
-
[k: string]: unknown;
|
4576
|
-
};
|
4577
|
-
packageAliases?: {
|
4578
|
-
[k: string]: string;
|
4579
|
-
};
|
4580
|
-
};
|
4535
|
+
export type NamedPackagingDir = PackagePackageDir & NameAndFullPath;
|
4536
|
+
export type NamedPackageDir = PackageDir & NameAndFullPath;
|
4537
|
+
export type ProjectJson = ConfigContents & ProjectJsonSchema;
|
4581
4538
|
/**
|
4582
4539
|
* The sfdx-project.json config object. This file determines if a folder is a valid sfdx project.
|
4583
4540
|
*
|
@@ -4596,6 +4553,7 @@ declare module '@salesforce/core-bundle/sfProject' {
|
|
4596
4553
|
* **See** [force:project:create](https://developer.salesforce.com/docs/atlas.en-us.sfdx_dev.meta/sfdx_dev/sfdx_dev_ws_create_new.htm)
|
4597
4554
|
*/
|
4598
4555
|
export class SfProjectJson extends ConfigFile<ConfigFile.Options, ProjectJson> {
|
4556
|
+
/** json properties that are uppercase, or allow uppercase keys inside them */
|
4599
4557
|
static BLOCKLIST: string[];
|
4600
4558
|
static getFileName(): string;
|
4601
4559
|
static getDefaultOptions(isGlobal?: boolean): ConfigFile.Options;
|
@@ -4680,7 +4638,7 @@ declare module '@salesforce/core-bundle/sfProject' {
|
|
4680
4638
|
*
|
4681
4639
|
* @param packageDir
|
4682
4640
|
*/
|
4683
|
-
addPackageDirectory(packageDir:
|
4641
|
+
addPackageDirectory(packageDir: PackageDir): void;
|
4684
4642
|
private doesPackageExist;
|
4685
4643
|
private validateKeys;
|
4686
4644
|
}
|
@@ -4878,6 +4836,11 @@ declare module '@salesforce/core-bundle/sfProject' {
|
|
4878
4836
|
getPackageIdFromAlias(alias: string): Optional<string>;
|
4879
4837
|
getAliasesFromPackageId(id: string): string[];
|
4880
4838
|
}
|
4839
|
+
/** differentiate between the Base PackageDir (path, maybe default) and the Packaging version (package and maybe a LOT of other fields) by whether is has the `package` property */
|
4840
|
+
export const isPackagingDirectory: (packageDir: PackageDir) => packageDir is PackagePackageDir;
|
4841
|
+
/** differentiate between the Base PackageDir (path, maybe default) and the Packaging version (package and maybe a LOT of other fields) by whether is has the `package` property */
|
4842
|
+
export const isNamedPackagingDirectory: (packageDir: NamedPackageDir) => packageDir is NamedPackagingDir;
|
4843
|
+
export {};
|
4881
4844
|
|
4882
4845
|
}
|
4883
4846
|
declare module '@salesforce/core-bundle/stateAggregator/accessors/aliasAccessor' {
|
@@ -6194,8 +6157,9 @@ declare module '@salesforce/core-bundle/util/findSuggestion' {
|
|
6194
6157
|
|
6195
6158
|
}
|
6196
6159
|
declare module '@salesforce/core-bundle/util/findUppercaseKeys' {
|
6197
|
-
import { JsonMap
|
6198
|
-
|
6160
|
+
import { JsonMap } from '@salesforce/ts-types';
|
6161
|
+
/** will throw on any upperCase unless they are present in the allowList. Recursively searches the object, returning valid keys */
|
6162
|
+
export const ensureNoUppercaseKeys: (path: string) => (allowList?: string[]) => (data: JsonMap) => string[];
|
6199
6163
|
|
6200
6164
|
}
|
6201
6165
|
declare module '@salesforce/core-bundle/util/getJwtAudienceUrl' {
|
package/lib/index.js
CHANGED
@@ -952,13 +952,7 @@ var require_duration = __commonJS({
|
|
952
952
|
* The string representation of this `Duration`. e.g. "645 seconds"
|
953
953
|
*/
|
954
954
|
toString() {
|
955
|
-
return this.
|
956
|
-
}
|
957
|
-
pluralize(num = this.quantity, unit = this.unit) {
|
958
|
-
const name = _Duration.Unit[unit].toLowerCase();
|
959
|
-
if (num === 1)
|
960
|
-
return `${num} ${name.slice(0, name.length - 1)}`;
|
961
|
-
return `${num} ${name}`;
|
955
|
+
return pluralize(this.quantity, this.unit);
|
962
956
|
}
|
963
957
|
};
|
964
958
|
exports2.Duration = Duration;
|
@@ -996,6 +990,10 @@ var require_duration = __commonJS({
|
|
996
990
|
return Object.assign(promise, { interrupt: wake });
|
997
991
|
}
|
998
992
|
exports2.sleep = sleep;
|
993
|
+
var pluralize = (num, unit) => {
|
994
|
+
const name = Duration.Unit[unit].toLowerCase();
|
995
|
+
return `${num} ${num === 1 ? name.slice(0, name.length - 1) : name}`;
|
996
|
+
};
|
999
997
|
}
|
1000
998
|
});
|
1001
999
|
|
@@ -5426,7 +5424,7 @@ var require_package = __commonJS({
|
|
5426
5424
|
"node_modules/thread-stream/package.json"(exports2, module2) {
|
5427
5425
|
module2.exports = {
|
5428
5426
|
name: "thread-stream",
|
5429
|
-
version: "
|
5427
|
+
version: "3.1.0",
|
5430
5428
|
description: "A streaming way to send data to a Node.js Worker Thread",
|
5431
5429
|
main: "index.js",
|
5432
5430
|
types: "index.d.ts",
|
@@ -5441,7 +5439,7 @@ var require_package = __commonJS({
|
|
5441
5439
|
fastbench: "^1.0.1",
|
5442
5440
|
husky: "^9.0.6",
|
5443
5441
|
"pino-elasticsearch": "^8.0.0",
|
5444
|
-
"sonic-boom": "^
|
5442
|
+
"sonic-boom": "^4.0.1",
|
5445
5443
|
standard: "^17.0.0",
|
5446
5444
|
tap: "^16.2.0",
|
5447
5445
|
"ts-node": "^10.8.0",
|
@@ -5449,7 +5447,8 @@ var require_package = __commonJS({
|
|
5449
5447
|
"why-is-node-running": "^2.2.2"
|
5450
5448
|
},
|
5451
5449
|
scripts: {
|
5452
|
-
|
5450
|
+
build: "tsc --noEmit",
|
5451
|
+
test: 'standard && npm run build && npm run transpile && tap "test/**/*.test.*js" && tap --ts test/*.test.*ts',
|
5453
5452
|
"test:ci": "standard && npm run transpile && npm run test:ci:js && npm run test:ci:ts",
|
5454
5453
|
"test:ci:js": 'tap --no-check-coverage --timeout=120 --coverage-report=lcovonly "test/**/*.test.*js"',
|
5455
5454
|
"test:ci:ts": 'tap --ts --no-check-coverage --coverage-report=lcovonly "test/**/*.test.*ts"',
|
@@ -5459,7 +5458,8 @@ var require_package = __commonJS({
|
|
5459
5458
|
},
|
5460
5459
|
standard: {
|
5461
5460
|
ignore: [
|
5462
|
-
"test/ts/**/*"
|
5461
|
+
"test/ts/**/*",
|
5462
|
+
"test/syntax-error.mjs"
|
5463
5463
|
]
|
5464
5464
|
},
|
5465
5465
|
repository: {
|
@@ -6035,7 +6035,10 @@ var require_transport = __commonJS({
|
|
6035
6035
|
stream.flushSync();
|
6036
6036
|
}
|
6037
6037
|
function transport(fullOptions) {
|
6038
|
-
const { pipeline, targets, levels, dedupe,
|
6038
|
+
const { pipeline, targets, levels, dedupe, worker = {}, caller = getCallers() } = fullOptions;
|
6039
|
+
const options = {
|
6040
|
+
...fullOptions.options
|
6041
|
+
};
|
6039
6042
|
const callers = typeof caller === "string" ? [caller] : caller;
|
6040
6043
|
const bundlerOverrides = "__bundlerPathsOverrides" in globalThis ? globalThis.__bundlerPathsOverrides : {};
|
6041
6044
|
let target = fullOptions.target;
|
@@ -6044,20 +6047,30 @@ var require_transport = __commonJS({
|
|
6044
6047
|
}
|
6045
6048
|
if (targets) {
|
6046
6049
|
target = bundlerOverrides["pino-worker"] || join(__dirname, "worker.js");
|
6047
|
-
options.targets = targets.map((dest) => {
|
6050
|
+
options.targets = targets.filter((dest) => dest.target).map((dest) => {
|
6048
6051
|
return {
|
6049
6052
|
...dest,
|
6050
6053
|
target: fixTarget(dest.target)
|
6051
6054
|
};
|
6052
6055
|
});
|
6056
|
+
options.pipelines = targets.filter((dest) => dest.pipeline).map((dest) => {
|
6057
|
+
return dest.pipeline.map((t) => {
|
6058
|
+
return {
|
6059
|
+
...t,
|
6060
|
+
level: dest.level,
|
6061
|
+
// duplicate the pipeline `level` property defined in the upper level
|
6062
|
+
target: fixTarget(t.target)
|
6063
|
+
};
|
6064
|
+
});
|
6065
|
+
});
|
6053
6066
|
} else if (pipeline) {
|
6054
|
-
target = bundlerOverrides["pino-
|
6055
|
-
options.
|
6067
|
+
target = bundlerOverrides["pino-worker"] || join(__dirname, "worker.js");
|
6068
|
+
options.pipelines = [pipeline.map((dest) => {
|
6056
6069
|
return {
|
6057
6070
|
...dest,
|
6058
6071
|
target: fixTarget(dest.target)
|
6059
6072
|
};
|
6060
|
-
});
|
6073
|
+
})];
|
6061
6074
|
}
|
6062
6075
|
if (levels) {
|
6063
6076
|
options.levels = levels;
|
@@ -6640,7 +6653,7 @@ var require_levels = __commonJS({
|
|
6640
6653
|
var require_meta = __commonJS({
|
6641
6654
|
"node_modules/pino/lib/meta.js"(exports2, module2) {
|
6642
6655
|
"use strict";
|
6643
|
-
module2.exports = { version: "
|
6656
|
+
module2.exports = { version: "9.2.0" };
|
6644
6657
|
}
|
6645
6658
|
});
|
6646
6659
|
|
@@ -7604,7 +7617,7 @@ var require_pino = __commonJS({
|
|
7604
7617
|
return f(p);
|
7605
7618
|
}
|
7606
7619
|
}
|
7607
|
-
globalThis.__bundlerPathsOverrides = { ...globalThis.__bundlerPathsOverrides || {}, "thread-stream-worker": pinoBundlerAbsolutePath("./thread-stream-worker.js"), "pino-worker": pinoBundlerAbsolutePath("./pino-worker.js"), "pino/file": pinoBundlerAbsolutePath("./pino-file.js"), "pino-
|
7620
|
+
globalThis.__bundlerPathsOverrides = { ...globalThis.__bundlerPathsOverrides || {}, "thread-stream-worker": pinoBundlerAbsolutePath("./thread-stream-worker.js"), "pino-worker": pinoBundlerAbsolutePath("./pino-worker.js"), "pino/file": pinoBundlerAbsolutePath("./pino-file.js"), "pino-pretty": pinoBundlerAbsolutePath("./pino-pretty.js") };
|
7608
7621
|
var os = require("os");
|
7609
7622
|
var stdSerializers = require_pino_std_serializers();
|
7610
7623
|
var caller = require_caller();
|
@@ -12075,7 +12088,7 @@ var require_package2 = __commonJS({
|
|
12075
12088
|
"package.json"(exports2, module2) {
|
12076
12089
|
module2.exports = {
|
12077
12090
|
name: "@salesforce/core-bundle",
|
12078
|
-
version: "7.
|
12091
|
+
version: "7.5.0",
|
12079
12092
|
description: "Core libraries to interact with SFDX projects, orgs, and APIs.",
|
12080
12093
|
main: "lib/index",
|
12081
12094
|
types: "lib/index.d.ts",
|
@@ -12112,9 +12125,9 @@ var require_package2 = __commonJS({
|
|
12112
12125
|
],
|
12113
12126
|
dependencies: {
|
12114
12127
|
"@jsforce/jsforce-node": "^3.2.0",
|
12115
|
-
"@salesforce/kit": "^3.1.
|
12128
|
+
"@salesforce/kit": "^3.1.6",
|
12116
12129
|
"@salesforce/schemas": "^1.9.0",
|
12117
|
-
"@salesforce/ts-types": "^2.0.
|
12130
|
+
"@salesforce/ts-types": "^2.0.10",
|
12118
12131
|
ajv: "^8.15.0",
|
12119
12132
|
"change-case": "^4.1.2",
|
12120
12133
|
"fast-levenshtein": "^3.0.0",
|
@@ -12123,16 +12136,16 @@ var require_package2 = __commonJS({
|
|
12123
12136
|
js2xmlparser: "^4.0.1",
|
12124
12137
|
jsonwebtoken: "9.0.2",
|
12125
12138
|
jszip: "3.10.1",
|
12126
|
-
pino: "^
|
12139
|
+
pino: "^9.2.0",
|
12127
12140
|
"pino-abstract-transport": "^1.2.0",
|
12128
|
-
"pino-pretty": "^
|
12141
|
+
"pino-pretty": "^11.2.1",
|
12129
12142
|
"proper-lockfile": "^4.1.2",
|
12130
12143
|
semver: "^7.6.2",
|
12131
12144
|
"ts-retry-promise": "^0.8.1"
|
12132
12145
|
},
|
12133
12146
|
devDependencies: {
|
12134
|
-
"@salesforce/dev-scripts": "^
|
12135
|
-
"@salesforce/ts-sinon": "^1.4.
|
12147
|
+
"@salesforce/dev-scripts": "^10.1.1",
|
12148
|
+
"@salesforce/ts-sinon": "^1.4.22",
|
12136
12149
|
"@types/benchmark": "^2.1.5",
|
12137
12150
|
"@types/chai-string": "^1.4.5",
|
12138
12151
|
"@types/fast-levenshtein": "^0.0.4",
|
@@ -14538,16 +14551,24 @@ function __asyncGenerator(thisArg, _arguments, generator) {
|
|
14538
14551
|
if (!Symbol.asyncIterator)
|
14539
14552
|
throw new TypeError("Symbol.asyncIterator is not defined.");
|
14540
14553
|
var g = generator.apply(thisArg, _arguments || []), i, q = [];
|
14541
|
-
return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function() {
|
14554
|
+
return i = {}, verb("next"), verb("throw"), verb("return", awaitReturn), i[Symbol.asyncIterator] = function() {
|
14542
14555
|
return this;
|
14543
14556
|
}, i;
|
14544
|
-
function
|
14545
|
-
|
14557
|
+
function awaitReturn(f) {
|
14558
|
+
return function(v) {
|
14559
|
+
return Promise.resolve(v).then(f, reject);
|
14560
|
+
};
|
14561
|
+
}
|
14562
|
+
function verb(n, f) {
|
14563
|
+
if (g[n]) {
|
14546
14564
|
i[n] = function(v) {
|
14547
14565
|
return new Promise(function(a, b) {
|
14548
14566
|
q.push([n, v, a, b]) > 1 || resume(n, v);
|
14549
14567
|
});
|
14550
14568
|
};
|
14569
|
+
if (f)
|
14570
|
+
i[n] = f(i[n]);
|
14571
|
+
}
|
14551
14572
|
}
|
14552
14573
|
function resume(n, v) {
|
14553
14574
|
try {
|
@@ -14651,7 +14672,7 @@ function __addDisposableResource(env, value, async) {
|
|
14651
14672
|
if (value !== null && value !== void 0) {
|
14652
14673
|
if (typeof value !== "object" && typeof value !== "function")
|
14653
14674
|
throw new TypeError("Object expected.");
|
14654
|
-
var dispose;
|
14675
|
+
var dispose, inner;
|
14655
14676
|
if (async) {
|
14656
14677
|
if (!Symbol.asyncDispose)
|
14657
14678
|
throw new TypeError("Symbol.asyncDispose is not defined.");
|
@@ -14661,9 +14682,19 @@ function __addDisposableResource(env, value, async) {
|
|
14661
14682
|
if (!Symbol.dispose)
|
14662
14683
|
throw new TypeError("Symbol.dispose is not defined.");
|
14663
14684
|
dispose = value[Symbol.dispose];
|
14685
|
+
if (async)
|
14686
|
+
inner = dispose;
|
14664
14687
|
}
|
14665
14688
|
if (typeof dispose !== "function")
|
14666
14689
|
throw new TypeError("Object not disposable.");
|
14690
|
+
if (inner)
|
14691
|
+
dispose = function() {
|
14692
|
+
try {
|
14693
|
+
inner.call(this);
|
14694
|
+
} catch (e) {
|
14695
|
+
return Promise.reject(e);
|
14696
|
+
}
|
14697
|
+
};
|
14667
14698
|
env.stack.push({ value, dispose, async });
|
14668
14699
|
} else if (async) {
|
14669
14700
|
env.stack.push({ async: true });
|
@@ -92184,25 +92215,19 @@ var require_findUppercaseKeys = __commonJS({
|
|
92184
92215
|
"lib/util/findUppercaseKeys.js"(exports2) {
|
92185
92216
|
"use strict";
|
92186
92217
|
Object.defineProperty(exports2, "__esModule", { value: true });
|
92187
|
-
exports2.
|
92218
|
+
exports2.ensureNoUppercaseKeys = void 0;
|
92219
|
+
var strict_1 = require("node:assert/strict");
|
92188
92220
|
var ts_types_1 = require_lib();
|
92189
|
-
var
|
92190
|
-
var
|
92191
|
-
|
92192
|
-
|
92193
|
-
|
92194
|
-
|
92195
|
-
|
92196
|
-
if (sectionBlocklist.includes(k)) {
|
92197
|
-
return key;
|
92198
|
-
}
|
92199
|
-
key = (0, exports2.findUpperCaseKeys)((0, ts_types_1.asJsonMap)(val));
|
92200
|
-
}
|
92201
|
-
return key;
|
92202
|
-
});
|
92203
|
-
return key;
|
92221
|
+
var messages_12 = require_messages();
|
92222
|
+
var coreMessages = new messages_12.Messages("@salesforce/core-bundle", "core", /* @__PURE__ */ new Map([["authInfoCreationError", "Must pass a username and/or OAuth options when creating an AuthInfo instance."], ["authInfoOverwriteError", "Cannot create an AuthInfo instance that will overwrite existing auth data."], ["authInfoOverwriteError.actions", ["Create the AuthInfo instance using existing auth data by just passing the username. E.g., `AuthInfo.create({ username: 'my@user.org' });`."]], ["authCodeExchangeError", "Error authenticating with auth code due to: %s"], ["authCodeUsernameRetrievalError", "Could not retrieve the username after successful auth code exchange.\n\nDue to: %s"], ["jwtAuthError", "Error authenticating with JWT config due to: %s"], ["jwtAuthErrors", "Error authenticating with JWT.\nErrors encountered:\n%s"], ["refreshTokenAuthError", "Error authenticating with the refresh token due to: %s"], ["orgDataNotAvailableError", "An attempt to refresh the authentication token failed with a 'Data Not Found Error'. The org identified by username %s does not appear to exist. Likely cause is that the org was deleted by another user or has expired."], ["orgDataNotAvailableError.actions", ["Run `sfdx force:org:list --clean` to remove stale org authentications.", "Use `sfdx force:config:set` to update the defaultusername.", "Use `sfdx force:org:create` to create a new org.", "Use `sfdx auth` to authenticate an existing org."]], ["namedOrgNotFound", "No authorization information found for %s."], ["noAliasesFound", "Nothing to set."], ["invalidFormat", "Setting aliases must be in the format <key>=<value> but found: [%s]."], ["invalidJsonCasing", 'All JSON input must have heads down camelcase keys. E.g., `{ sfdcLoginUrl: "https://login.salesforce.com" }`\nFound "%s" at %s'], ["missingClientId", "Client ID is required for JWT authentication."]]));
|
92223
|
+
var ensureNoUppercaseKeys = (path) => (allowList = []) => (data) => {
|
92224
|
+
const keys2 = getKeys(data, allowList);
|
92225
|
+
const upperCaseKeys = keys2.filter((key) => /^[A-Z]/.test(key)).join(", ");
|
92226
|
+
(0, strict_1.strictEqual)(upperCaseKeys.length, 0, coreMessages.getMessage("invalidJsonCasing", [upperCaseKeys, path]));
|
92227
|
+
return keys2;
|
92204
92228
|
};
|
92205
|
-
exports2.
|
92229
|
+
exports2.ensureNoUppercaseKeys = ensureNoUppercaseKeys;
|
92230
|
+
var getKeys = (data, allowList) => Object.entries(data).filter(([k]) => !allowList.includes(k)).flatMap(([key, value]) => (0, ts_types_1.isJsonMap)(value) ? [key, ...getKeys(value, allowList)] : [key]);
|
92206
92231
|
}
|
92207
92232
|
});
|
92208
92233
|
|
@@ -93232,7 +93257,7 @@ var require_sfProject = __commonJS({
|
|
93232
93257
|
return result;
|
93233
93258
|
};
|
93234
93259
|
Object.defineProperty(exports2, "__esModule", { value: true });
|
93235
|
-
exports2.SfProject = exports2.SfProjectJson = void 0;
|
93260
|
+
exports2.isNamedPackagingDirectory = exports2.isPackagingDirectory = exports2.SfProject = exports2.SfProjectJson = void 0;
|
93236
93261
|
var node_path_1 = require("node:path");
|
93237
93262
|
var fs = __importStar2(require("node:fs"));
|
93238
93263
|
var kit_1 = require_lib2();
|
@@ -93246,8 +93271,8 @@ var require_sfProject = __commonJS({
|
|
93246
93271
|
var messages_12 = require_messages();
|
93247
93272
|
var findUppercaseKeys_1 = require_findUppercaseKeys();
|
93248
93273
|
var messages = new messages_12.Messages("@salesforce/core-bundle", "config", /* @__PURE__ */ new Map([["unknownConfigKey", "Unknown config name: %s."], ["deprecatedConfigKey", "Deprecated config name: %s. Please use %s instead."], ["invalidWrite", "The writeSync method is not allowed on SfdxConfig. Use the async write method instead."], ["invalidConfigValue", "Invalid config value: %s."], ["invalidInstanceUrl", "Specify a valid Salesforce instance URL."], ["invalidApiVersion", "Specify a valid Salesforce API version, for example, 42.0."], ["invalidCustomOrgMetadataTemplates", "Specify a valid repository URL or directory for the custom org metadata templates."], ["invalidIsvDebuggerSid", "Specify a valid Debugger SID."], ["invalidIsvDebuggerUrl", "Specify a valid Debugger URL."], ["invalidNumberConfigValue", "Specify a valid positive integer, for example, 150000."], ["invalidBooleanConfigValue", "The config value can only be set to true or false."], ["invalidProjectWorkspace", "This directory does not contain a valid Salesforce DX project."], ["schemaValidationError", 'The config file "%s" is not schema valid.\nDue to: %s'], ["schemaValidationError.actions", ["Fix the invalid entries at %s."]], ["missingDefaultPath", 'In sfdx-project.json, be sure to specify which package directory (path) is the default. Example: `[{ "path": "packageDirectory1", "default": true }, { "path": "packageDirectory2" }]`'], ["missingPackageDirectory", 'The path "%s", specified in sfdx-project.json, does not exist. Be sure this directory is included in your project root.'], ["invalidPackageDirectory", 'The path "%s", specified in sfdx-project.json, must be indicated as a relative path to the project root.'], ["multipleDefaultPaths", "In sfdx-project.json, indicate only one package directory (path) as the default."], ["singleNonDefaultPackage", 'The sfdx-project.json file must include one, and only one, default package directory (path). Because your sfdx-project.json file contains only one package directory, it must be the default. Remove the `"default": false` key and try again.'], ["target-org", "Username or alias of the org that all commands run against by default. (sf only)"], ["target-dev-hub", "Username or alias of your default Dev Hub org. (sf only)"], ["defaultUsername", "Username or alias of the org that all commands run against by default. (sfdx only)"], ["defaultDevHubUsername", "Username or alias of your default Dev Hub org. (sfdx only)"], ["isvDebuggerSid", "ISV debugger SID (sfdx only)"], ["isvDebuggerUrl", "ISV debugger URL (sfdx only)"], ["org-isv-debugger-sid", "ISV debugger SID."], ["org-isv-debugger-url", "ISV debugger URL."], ["apiVersion", "API version of your project. Default: API version of your Dev Hub org. (sfdx only)"], ["org-api-version", "API version of your project. Default: API version of your Dev Hub org."], ["disableTelemetry", "Disables the collection of usage and user environment information, etc. Default: false. (sfdx only)"], ["disable-telemetry", "Disables the collection of usage and user environment information, etc. Default: false."], ["maxQueryLimit", "Maximum number of Salesforce records returned by a CLI command. Default: 10,000. (sfdx only)"], ["org-max-query-limit", "Maximum number of Salesforce records returned by a CLI command. Default: 10,000."], ["restDeploy", "Whether deployments use the Metadata REST API (true) or SOAP API (false, default value). (sfdx only)"], ["instanceUrl", "URL of the Salesforce instance hosting your org. Default: https://login.salesforce.com. (sfdx only)"], ["org-instance-url", "URL of the Salesforce instance hosting your org. Default: https://login.salesforce.com."], ["customOrgMetadataTemplates", "A valid repository URL or directory for the custom org metadata templates."], ["org-custom-metadata-templates", "A valid repository URL or directory for the custom org metadata templates."], ["org-capitalize-record-types", "Whether record types are capitalized on scratch org creation."], ["invalidId", "The given id %s is not a valid 15 or 18 character Salesforce ID."]]));
|
93249
|
-
var coreMessages = new messages_12.Messages("@salesforce/core-bundle", "core", /* @__PURE__ */ new Map([["authInfoCreationError", "Must pass a username and/or OAuth options when creating an AuthInfo instance."], ["authInfoOverwriteError", "Cannot create an AuthInfo instance that will overwrite existing auth data."], ["authInfoOverwriteError.actions", ["Create the AuthInfo instance using existing auth data by just passing the username. E.g., `AuthInfo.create({ username: 'my@user.org' });`."]], ["authCodeExchangeError", "Error authenticating with auth code due to: %s"], ["authCodeUsernameRetrievalError", "Could not retrieve the username after successful auth code exchange.\n\nDue to: %s"], ["jwtAuthError", "Error authenticating with JWT config due to: %s"], ["jwtAuthErrors", "Error authenticating with JWT.\nErrors encountered:\n%s"], ["refreshTokenAuthError", "Error authenticating with the refresh token due to: %s"], ["orgDataNotAvailableError", "An attempt to refresh the authentication token failed with a 'Data Not Found Error'. The org identified by username %s does not appear to exist. Likely cause is that the org was deleted by another user or has expired."], ["orgDataNotAvailableError.actions", ["Run `sfdx force:org:list --clean` to remove stale org authentications.", "Use `sfdx force:config:set` to update the defaultusername.", "Use `sfdx force:org:create` to create a new org.", "Use `sfdx auth` to authenticate an existing org."]], ["namedOrgNotFound", "No authorization information found for %s."], ["noAliasesFound", "Nothing to set."], ["invalidFormat", "Setting aliases must be in the format <key>=<value> but found: [%s]."], ["invalidJsonCasing", 'All JSON input must have heads down camelcase keys. E.g., `{ sfdcLoginUrl: "https://login.salesforce.com" }`\nFound "%s" at %s'], ["missingClientId", "Client ID is required for JWT authentication."]]));
|
93250
93274
|
var SfProjectJson = class _SfProjectJson extends configFile_12.ConfigFile {
|
93275
|
+
/** json properties that are uppercase, or allow uppercase keys inside them */
|
93251
93276
|
static BLOCKLIST = ["packageAliases"];
|
93252
93277
|
static getFileName() {
|
93253
93278
|
return internal_1.SFDX_PROJECT_JSON;
|
@@ -93446,10 +93471,7 @@ var require_sfProject = __commonJS({
|
|
93446
93471
|
* @param packageDir
|
93447
93472
|
*/
|
93448
93473
|
addPackageDirectory(packageDir) {
|
93449
|
-
const dirIndex = this.getContents().packageDirectories.findIndex((
|
93450
|
-
const withId = pd;
|
93451
|
-
return withId.path === packageDir.path && !withId.id && !withId.package || !!packageDir.package && packageDir.package === withId.package;
|
93452
|
-
});
|
93474
|
+
const dirIndex = this.getContents().packageDirectories.findIndex(findPackageDir(packageDir));
|
93453
93475
|
const packageDirEntry = Object.assign({}, dirIndex > -1 ? this.getContents().packageDirectories[dirIndex] : packageDir, packageDir);
|
93454
93476
|
const modifiedPackagesDirs = dirIndex > -1 ? (
|
93455
93477
|
// replace the matching entry with the new entry
|
@@ -93460,15 +93482,13 @@ var require_sfProject = __commonJS({
|
|
93460
93482
|
);
|
93461
93483
|
this.set("packageDirectories", modifiedPackagesDirs);
|
93462
93484
|
}
|
93485
|
+
// keep it because testSetup stubs it!
|
93463
93486
|
// eslint-disable-next-line class-methods-use-this
|
93464
93487
|
doesPackageExist(packagePath) {
|
93465
93488
|
return fs.existsSync(packagePath);
|
93466
93489
|
}
|
93467
93490
|
validateKeys() {
|
93468
|
-
|
93469
|
-
if (upperCaseKey) {
|
93470
|
-
throw coreMessages.createError("invalidJsonCasing", [upperCaseKey, this.getPath()]);
|
93471
|
-
}
|
93491
|
+
(0, findUppercaseKeys_1.ensureNoUppercaseKeys)(this.getPath())(_SfProjectJson.BLOCKLIST)(this.toObject());
|
93472
93492
|
}
|
93473
93493
|
};
|
93474
93494
|
exports2.SfProjectJson = SfProjectJson;
|
@@ -93661,7 +93681,9 @@ var require_sfProject = __commonJS({
|
|
93661
93681
|
*/
|
93662
93682
|
getPackageNameFromPath(path) {
|
93663
93683
|
const packageDir = this.getPackageFromPath(path);
|
93664
|
-
|
93684
|
+
if (!packageDir)
|
93685
|
+
return void 0;
|
93686
|
+
return (0, exports2.isNamedPackagingDirectory)(packageDir) ? packageDir.package : packageDir.path;
|
93665
93687
|
}
|
93666
93688
|
/**
|
93667
93689
|
* Returns the package directory.
|
@@ -93794,6 +93816,17 @@ var require_sfProject = __commonJS({
|
|
93794
93816
|
}
|
93795
93817
|
};
|
93796
93818
|
exports2.SfProject = SfProject;
|
93819
|
+
var isPackagingDirectory = (packageDir) => isPackagingDir(packageDir);
|
93820
|
+
exports2.isPackagingDirectory = isPackagingDirectory;
|
93821
|
+
var isNamedPackagingDirectory = (packageDir) => isPackagingDir(packageDir);
|
93822
|
+
exports2.isNamedPackagingDirectory = isNamedPackagingDirectory;
|
93823
|
+
var isPackagingDir = (packageDir) => "package" in packageDir && typeof packageDir.package === "string";
|
93824
|
+
var findPackageDir = (target) => (potentialMatch) => (
|
93825
|
+
// an entry w/o a package or id is considered a directory entry for which a package has yet to be created
|
93826
|
+
// find a matching dir entry that where path is the same and id and package are not present
|
93827
|
+
potentialMatch.path === target.path && !("id" in potentialMatch) && !(0, exports2.isPackagingDirectory)(potentialMatch) || // if that fails, then find a matching dir entry package is present and is same as the new entry
|
93828
|
+
(0, exports2.isPackagingDirectory)(target) && (0, exports2.isPackagingDirectory)(potentialMatch) && target.package === potentialMatch.package
|
93829
|
+
);
|
93797
93830
|
}
|
93798
93831
|
});
|
93799
93832
|
|
@@ -107286,7 +107319,7 @@ var require_scratchOrgInfoGenerator = __commonJS({
|
|
107286
107319
|
if (Reflect.has(scratchOrgInfo, "package2AncestorIds")) {
|
107287
107320
|
throw new sfError_12.SfError(messages.getMessage("Package2AncestorsIdsKeyNotSupportedError"), "DeprecationError");
|
107288
107321
|
}
|
107289
|
-
const packagesWithAncestors = (await projectJson.getPackageDirectories()).filter((packageDir) => packageDir.ancestorId ?? packageDir.ancestorVersion);
|
107322
|
+
const packagesWithAncestors = (await projectJson.getPackageDirectories()).filter(sfProject_12.isPackagingDirectory).filter((packageDir) => packageDir.ancestorId ?? packageDir.ancestorVersion);
|
107290
107323
|
if (packagesWithAncestors.length === 0) {
|
107291
107324
|
return "";
|
107292
107325
|
}
|
package/lib/pino-file.js
CHANGED
@@ -1945,7 +1945,7 @@ var require_package = __commonJS({
|
|
1945
1945
|
"node_modules/thread-stream/package.json"(exports2, module2) {
|
1946
1946
|
module2.exports = {
|
1947
1947
|
name: "thread-stream",
|
1948
|
-
version: "
|
1948
|
+
version: "3.1.0",
|
1949
1949
|
description: "A streaming way to send data to a Node.js Worker Thread",
|
1950
1950
|
main: "index.js",
|
1951
1951
|
types: "index.d.ts",
|
@@ -1960,7 +1960,7 @@ var require_package = __commonJS({
|
|
1960
1960
|
fastbench: "^1.0.1",
|
1961
1961
|
husky: "^9.0.6",
|
1962
1962
|
"pino-elasticsearch": "^8.0.0",
|
1963
|
-
"sonic-boom": "^
|
1963
|
+
"sonic-boom": "^4.0.1",
|
1964
1964
|
standard: "^17.0.0",
|
1965
1965
|
tap: "^16.2.0",
|
1966
1966
|
"ts-node": "^10.8.0",
|
@@ -1968,7 +1968,8 @@ var require_package = __commonJS({
|
|
1968
1968
|
"why-is-node-running": "^2.2.2"
|
1969
1969
|
},
|
1970
1970
|
scripts: {
|
1971
|
-
|
1971
|
+
build: "tsc --noEmit",
|
1972
|
+
test: 'standard && npm run build && npm run transpile && tap "test/**/*.test.*js" && tap --ts test/*.test.*ts',
|
1972
1973
|
"test:ci": "standard && npm run transpile && npm run test:ci:js && npm run test:ci:ts",
|
1973
1974
|
"test:ci:js": 'tap --no-check-coverage --timeout=120 --coverage-report=lcovonly "test/**/*.test.*js"',
|
1974
1975
|
"test:ci:ts": 'tap --ts --no-check-coverage --coverage-report=lcovonly "test/**/*.test.*ts"',
|
@@ -1978,7 +1979,8 @@ var require_package = __commonJS({
|
|
1978
1979
|
},
|
1979
1980
|
standard: {
|
1980
1981
|
ignore: [
|
1981
|
-
"test/ts/**/*"
|
1982
|
+
"test/ts/**/*",
|
1983
|
+
"test/syntax-error.mjs"
|
1982
1984
|
]
|
1983
1985
|
},
|
1984
1986
|
repository: {
|
@@ -2554,7 +2556,10 @@ var require_transport = __commonJS({
|
|
2554
2556
|
stream.flushSync();
|
2555
2557
|
}
|
2556
2558
|
function transport(fullOptions) {
|
2557
|
-
const { pipeline, targets, levels, dedupe,
|
2559
|
+
const { pipeline, targets, levels, dedupe, worker = {}, caller = getCallers() } = fullOptions;
|
2560
|
+
const options = {
|
2561
|
+
...fullOptions.options
|
2562
|
+
};
|
2558
2563
|
const callers = typeof caller === "string" ? [caller] : caller;
|
2559
2564
|
const bundlerOverrides = "__bundlerPathsOverrides" in globalThis ? globalThis.__bundlerPathsOverrides : {};
|
2560
2565
|
let target = fullOptions.target;
|
@@ -2563,20 +2568,30 @@ var require_transport = __commonJS({
|
|
2563
2568
|
}
|
2564
2569
|
if (targets) {
|
2565
2570
|
target = bundlerOverrides["pino-worker"] || join(__dirname, "worker.js");
|
2566
|
-
options.targets = targets.map((dest) => {
|
2571
|
+
options.targets = targets.filter((dest) => dest.target).map((dest) => {
|
2567
2572
|
return {
|
2568
2573
|
...dest,
|
2569
2574
|
target: fixTarget(dest.target)
|
2570
2575
|
};
|
2571
2576
|
});
|
2577
|
+
options.pipelines = targets.filter((dest) => dest.pipeline).map((dest) => {
|
2578
|
+
return dest.pipeline.map((t) => {
|
2579
|
+
return {
|
2580
|
+
...t,
|
2581
|
+
level: dest.level,
|
2582
|
+
// duplicate the pipeline `level` property defined in the upper level
|
2583
|
+
target: fixTarget(t.target)
|
2584
|
+
};
|
2585
|
+
});
|
2586
|
+
});
|
2572
2587
|
} else if (pipeline) {
|
2573
|
-
target = bundlerOverrides["pino-
|
2574
|
-
options.
|
2588
|
+
target = bundlerOverrides["pino-worker"] || join(__dirname, "worker.js");
|
2589
|
+
options.pipelines = [pipeline.map((dest) => {
|
2575
2590
|
return {
|
2576
2591
|
...dest,
|
2577
2592
|
target: fixTarget(dest.target)
|
2578
2593
|
};
|
2579
|
-
});
|
2594
|
+
})];
|
2580
2595
|
}
|
2581
2596
|
if (levels) {
|
2582
2597
|
options.levels = levels;
|
@@ -3159,7 +3174,7 @@ var require_levels = __commonJS({
|
|
3159
3174
|
var require_meta = __commonJS({
|
3160
3175
|
"node_modules/pino/lib/meta.js"(exports2, module2) {
|
3161
3176
|
"use strict";
|
3162
|
-
module2.exports = { version: "
|
3177
|
+
module2.exports = { version: "9.2.0" };
|
3163
3178
|
}
|
3164
3179
|
});
|
3165
3180
|
|
@@ -4123,7 +4138,7 @@ var require_pino = __commonJS({
|
|
4123
4138
|
return f(p);
|
4124
4139
|
}
|
4125
4140
|
}
|
4126
|
-
globalThis.__bundlerPathsOverrides = { ...globalThis.__bundlerPathsOverrides || {}, "thread-stream-worker": pinoBundlerAbsolutePath("./thread-stream-worker.js"), "pino-worker": pinoBundlerAbsolutePath("./pino-worker.js"), "pino/file": pinoBundlerAbsolutePath("./pino-file.js"), "pino-
|
4141
|
+
globalThis.__bundlerPathsOverrides = { ...globalThis.__bundlerPathsOverrides || {}, "thread-stream-worker": pinoBundlerAbsolutePath("./thread-stream-worker.js"), "pino-worker": pinoBundlerAbsolutePath("./pino-worker.js"), "pino/file": pinoBundlerAbsolutePath("./pino-file.js"), "pino-pretty": pinoBundlerAbsolutePath("./pino-pretty.js") };
|
4127
4142
|
var os = require("os");
|
4128
4143
|
var stdSerializers = require_pino_std_serializers();
|
4129
4144
|
var caller = require_caller();
|