diff --git a/src/model.d.ts b/src/model.d.ts index 434feb0cf1ef..7155761f8770 100644 --- a/src/model.d.ts +++ b/src/model.d.ts @@ -7,7 +7,7 @@ import { ValidationOptions } from './instance-validator'; import { IndexesOptions, QueryOptions, TableName } from './dialects/abstract/query-interface'; import { Sequelize, SyncOptions } from './sequelize'; import { Col, Fn, Literal, Where, MakeNullishOptional, AnyFunction, Cast, Json } from './utils'; -import { LOCK, Transaction, Op } from './index'; +import { LOCK, Transaction, Op, Optional } from './index'; import { SetRequired } from './utils/set-required'; export interface Logging { @@ -1962,7 +1962,12 @@ export abstract class Model, M extends InstanceType>( this: MS, - attributes: ModelAttributes>, options: InitOptions + attributes: ModelAttributes< + M, + // 'foreign keys' are optional in Model.init as they are added by association declaration methods + Optional, BrandedKeysOf, typeof ForeignKeyBrand>> + >, + options: InitOptions ): MS; /** @@ -3272,6 +3277,10 @@ type IsBranded = keyof NonNullable extends keyof Omi ? false : true; +type BrandedKeysOf = { + [P in keyof T]-?: IsBranded extends true ? P : never +}[keyof T]; + /** * Dummy Symbol used as branding by {@link NonAttribute}. * @@ -3284,7 +3293,6 @@ declare const NonAttributeBrand: unique symbol; * You can use it to tag fields from your class that are NOT attributes. * They will be ignored by {@link InferAttributes} and {@link InferCreationAttributes} */ - export type NonAttribute = // we don't brand null & undefined as they can't have properties. // This means `NonAttribute` will not work, but who makes an attribute that only accepts null? @@ -3292,6 +3300,25 @@ export type NonAttribute = T extends null | undefined ? T : (T & { [NonAttributeBrand]?: true }); +/** + * Dummy Symbol used as branding by {@link ForeignKey}. + * + * Do not export, Do not use. + */ +declare const ForeignKeyBrand: unique symbol; + +/** + * This is a Branded Type. + * You can use it to tag fields from your class that are foreign keys. + * They will become optional in {@link Model.init} (as foreign keys are added by association methods, like {@link Model.hasMany}. + */ +export type ForeignKey = + // we don't brand null & undefined as they can't have properties. + // This means `ForeignKey` will not work, but who makes an attribute that only accepts null? + // Note that `ForeignKey` does work! + T extends null | undefined ? T + : (T & { [ForeignKeyBrand]?: true }); + /** * Option bag for {@link InferAttributes}. * @@ -3366,8 +3393,8 @@ declare const CreationAttributeBrand: unique symbol; */ export type CreationOptional = // we don't brand null & undefined as they can't have properties. - // This means `CreationAttributeBrand` will not work, but who makes an attribute that only accepts null? - // Note that `CreationAttributeBrand` does work! + // This means `CreationOptional` will not work, but who makes an attribute that only accepts null? + // Note that `CreationOptional` does work! T extends null | undefined ? T : (T & { [CreationAttributeBrand]?: true }); diff --git a/test/types/infer-attributes.ts b/test/types/infer-attributes.ts index 5b925490e527..271bbfccd210 100644 --- a/test/types/infer-attributes.ts +++ b/test/types/infer-attributes.ts @@ -3,10 +3,13 @@ import { Attributes, CreationAttributes, CreationOptional, + DataTypes, + ForeignKey, InferAttributes, InferCreationAttributes, Model, NonAttribute, + Sequelize, } from 'sequelize'; class Project extends Model> { @@ -32,6 +35,7 @@ class User extends Model; + declare projectId: CreationOptional>; instanceMethod() { } @@ -40,6 +44,15 @@ class User extends Model; type UserCreationAttributes = CreationAttributes; diff --git a/test/types/typescriptDocs/Define.ts b/test/types/typescriptDocs/Define.ts index 8ea23694d01c..446ad3605082 100644 --- a/test/types/typescriptDocs/Define.ts +++ b/test/types/typescriptDocs/Define.ts @@ -4,37 +4,32 @@ * * Don't include this comment in the md file. */ -import { Sequelize, Model, DataTypes, Optional } from 'sequelize'; +import { Sequelize, Model, DataTypes, CreationOptional, InferAttributes, InferCreationAttributes } from 'sequelize'; const sequelize = new Sequelize('mysql://root:asd123@localhost:3306/mydb'); // We recommend you declare an interface for the attributes, for stricter typechecking -interface UserAttributes { - id: number; + +interface UserModel extends Model, InferCreationAttributes> { + // Some fields are optional when calling UserModel.create() or UserModel.build() + id: CreationOptional; name: string; } -// Some fields are optional when calling UserModel.create() or UserModel.build() -interface UserCreationAttributes extends Optional {} - -// We need to declare an interface for our model that is basically what our class would be -interface UserInstance - extends Model, - UserAttributes {} - -const UserModel = sequelize.define('User', { +const UserModel = sequelize.define('User', { id: { primaryKey: true, type: DataTypes.INTEGER.UNSIGNED, }, name: { type: DataTypes.STRING, - } + }, }); async function doStuff() { const instance = await UserModel.findByPk(1, { rejectOnEmpty: true, }); + console.log(instance.id); } diff --git a/test/types/typescriptDocs/DefineNoAttributes.ts b/test/types/typescriptDocs/DefineNoAttributes.ts deleted file mode 100644 index 8273cad18ff1..000000000000 --- a/test/types/typescriptDocs/DefineNoAttributes.ts +++ /dev/null @@ -1,32 +0,0 @@ -/** - * Keep this file in sync with the code in the "Usage of `sequelize.define`" - * that doesn't have attribute types in /docs/manual/other-topics/typescript.md - * - * Don't include this comment in the md file. - */ -import { Sequelize, Model, DataTypes } from 'sequelize'; - -const sequelize = new Sequelize('mysql://root:asd123@localhost:3306/mydb'); - -// We need to declare an interface for our model that is basically what our class would be -interface UserInstance extends Model { - id: number; - name: string; -} - -const UserModel = sequelize.define('User', { - id: { - primaryKey: true, - type: DataTypes.INTEGER.UNSIGNED, - }, - name: { - type: DataTypes.STRING, - }, -}); - -async function doStuff() { - const instance = await UserModel.findByPk(1, { - rejectOnEmpty: true, - }); - console.log(instance.id); -} diff --git a/test/types/typescriptDocs/ModelInit.ts b/test/types/typescriptDocs/ModelInit.ts index ea7ebe6cd6e3..fd57ae200cb9 100644 --- a/test/types/typescriptDocs/ModelInit.ts +++ b/test/types/typescriptDocs/ModelInit.ts @@ -9,7 +9,7 @@ import { HasManyCreateAssociationMixin, HasManyGetAssociationsMixin, HasManyHasAssociationMixin, HasManySetAssociationsMixin, HasManyAddAssociationsMixin, HasManyHasAssociationsMixin, HasManyRemoveAssociationMixin, HasManyRemoveAssociationsMixin, Model, ModelDefined, Optional, - Sequelize, InferAttributes, InferCreationAttributes, CreationOptional, NonAttribute + Sequelize, InferAttributes, InferCreationAttributes, CreationOptional, NonAttribute, ForeignKey, } from 'sequelize'; const sequelize = new Sequelize('mysql://root:asd123@localhost:3306/mydb'); @@ -62,7 +62,11 @@ class Project extends Model< > { // id can be undefined during creation when using `autoIncrement` declare id: CreationOptional; - declare ownerId: number; + + // foreign keys are automatically added by associations methods (like Project.belongsTo) + // by branding them using the `ForeignKey` type, `Project.init` will know it does not need to + // display an error if ownerId is missing. + declare ownerId: ForeignKey; declare name: string; // `owner` is an eagerly-loaded association. @@ -79,7 +83,7 @@ class Address extends Model< InferAttributes
, InferCreationAttributes
> { - declare userId: number; + declare userId: ForeignKey; declare address: string; // createdAt can be undefined during creation @@ -95,10 +99,6 @@ Project.init( autoIncrement: true, primaryKey: true }, - ownerId: { - type: DataTypes.INTEGER.UNSIGNED, - allowNull: false - }, name: { type: new DataTypes.STRING(128), allowNull: false @@ -138,9 +138,6 @@ User.init( Address.init( { - userId: { - type: DataTypes.INTEGER.UNSIGNED - }, address: { type: new DataTypes.STRING(128), allowNull: false diff --git a/test/types/typescriptDocs/ModelInitNoAttributes.ts b/test/types/typescriptDocs/ModelInitNoAttributes.ts index ff8a5c22a22d..a7d634be50c3 100644 --- a/test/types/typescriptDocs/ModelInitNoAttributes.ts +++ b/test/types/typescriptDocs/ModelInitNoAttributes.ts @@ -9,9 +9,9 @@ import { Sequelize, Model, DataTypes } from 'sequelize'; const sequelize = new Sequelize('mysql://root:asd123@localhost:3306/mydb'); class User extends Model { - public id!: number; // Note that the `null assertion` `!` is required in strict mode. - public name!: string; - public preferredName!: string | null; // for nullable fields + declare id: number; + declare name: string; + declare preferredName: string | null; } User.init( diff --git a/yarn.lock b/yarn.lock index 8d6032049228..7ec00d439fcd 100644 --- a/yarn.lock +++ b/yarn.lock @@ -242,11 +242,6 @@ dependencies: "@babel/types" "^7.16.7" -"@babel/helper-validator-identifier@^7.15.7": - version "7.15.7" - resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.15.7.tgz#220df993bfe904a4a6b02ab4f3385a5ebf6e2389" - integrity sha512-K4JvCtQqad9OY2+yTU8w+E82ywk/fe+ELNlt1G8z3bVGlZfn/hOcQQsUhGhW/N+tb3fxK800wLtKOE/aM0m72w== - "@babel/helper-validator-identifier@^7.16.7": version "7.16.7" resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.16.7.tgz#e8c602438c4a8195751243da9031d1607d247cad" @@ -691,16 +686,6 @@ minimatch "^3.0.4" read-package-json-fast "^2.0.1" -"@npmcli/map-workspaces@^2.0.0": - version "2.0.1" - resolved "https://registry.yarnpkg.com/@npmcli/map-workspaces/-/map-workspaces-2.0.1.tgz#da8b4d2e1f4cef30efcc81e425bd11a9bf5489f2" - integrity sha512-awwkB/tSWWaCD8F0IbawBdmoPFlbXMaEPN9LyTuJcyJz404/QhB4B/vhQntpk6uxOAkM+bxR7qWMJghYg0tcYQ== - dependencies: - "@npmcli/name-from-folder" "^1.0.1" - glob "^7.2.0" - minimatch "^5.0.0" - read-package-json-fast "^2.0.3" - "@npmcli/metavuln-calculator@^1.1.0": version "1.1.1" resolved "https://registry.yarnpkg.com/@npmcli/metavuln-calculator/-/metavuln-calculator-1.1.1.tgz#2f95ff3c6d88b366dd70de1c3f304267c631b458" @@ -1236,7 +1221,7 @@ agent-base@^4.3.0: dependencies: es6-promisify "^5.0.0" -agentkeepalive@^4.1.3, agentkeepalive@^4.2.0: +agentkeepalive@^4.1.3: version "4.2.1" resolved "https://registry.yarnpkg.com/agentkeepalive/-/agentkeepalive-4.2.1.tgz#a7975cbb9f83b367f06c90cc51ff28fe7d499717" integrity sha512-Zn4cw2NEqd+9fiSVWMscnjyQ1a8Yfoc5oBajLeo5w+YBHgDUcEBY2hS4YpTz6iN5f/2zQiktcuM6tS8x1p9dpA== @@ -1510,7 +1495,7 @@ async-hook-jl@^1.7.6: dependencies: stack-chain "^1.3.7" -async@>=0.6.0, async@^3.1.0: +async@>=0.6.0: version "3.2.2" resolved "https://registry.yarnpkg.com/async/-/async-3.2.2.tgz#2eb7671034bb2194d45d30e31e24ec7e7f9670cd" integrity sha512-H0E+qZaDEfx/FY4t7iLRv1W2fFI6+pyCeTw1uN20AQPiwqwM6ojPxHxdLv4z8hi2DtnW9BOckSspLucW7pIE5g== @@ -1520,6 +1505,11 @@ async@^1.5.2: resolved "https://registry.yarnpkg.com/async/-/async-1.5.2.tgz#ec6a61ae56480c0c3cb241c95618e20892f9672a" integrity sha1-7GphrlZIDAw8skHJVhjiCJL5Zyo= +async@^3.2.3: + version "3.2.3" + resolved "https://registry.yarnpkg.com/async/-/async-3.2.3.tgz#ac53dafd3f4720ee9e8a160628f18ea91df196c9" + integrity sha512-spZRyzKL5l5BZQrr/6m/SqFdBN0q3OCI0f9rjfBzCMBIP4p75P620rR3gTmaksNOhmzgdxcaxdNfMy6anrbM0g== + asynckit@^0.4.0: version "0.4.0" resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" @@ -1749,13 +1739,6 @@ brace-expansion@^1.1.7: balanced-match "^1.0.0" concat-map "0.0.1" -brace-expansion@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-2.0.1.tgz#1edc459e0f0c548486ecf9fc99f2221364b9a0ae" - integrity sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA== - dependencies: - balanced-match "^1.0.0" - braces@^3.0.1, braces@~3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/braces/-/braces-3.0.2.tgz#3454e1a462ee8d599e236df336cd9ea4f8afe107" @@ -4115,7 +4098,7 @@ hosted-git-info@^2.1.4: resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.8.9.tgz#dffc0bf9a21c02209090f2aa69429e1414daf3f9" integrity sha512-mxIDAb9Lsm6DoOJ7xH+5+X4y1LU/4Hi50L9C5sIswK3JzULS4bwk1FvjdBgvYR4bzT4tuUQiC15FE2f5HbLvYw== -hosted-git-info@^4.0.0, hosted-git-info@^4.0.1, hosted-git-info@^4.1.0: +hosted-git-info@^4.0.0, hosted-git-info@^4.0.1: version "4.1.0" resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-4.1.0.tgz#827b82867e9ff1c8d0c4d9d53880397d2c86d224" integrity sha512-kyCuEOWjJqZuDbRHzL8V93NzQhwIB71oFWSyzVo+KPZI+pnQPPxucdkrOZvkLRnrf5URsQM+IJ09Dw29cRALIA== @@ -5467,11 +5450,6 @@ lru-cache@^6.0.0: dependencies: yallist "^4.0.0" -lru-cache@^7.3.1: - version "7.4.0" - resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-7.4.0.tgz#2830a779b483e9723e20f26fa5278463c50599d8" - integrity sha512-YOfuyWa/Ee+PXbDm40j9WXyJrzQUynVbgn4Km643UYcWNcrSfRkKL0WaiUcxcIbkXcVTgNpDqSnPXntWXT75cw== - make-dir@^3.0.0, make-dir@^3.0.2: version "3.1.0" resolved "https://registry.yarnpkg.com/make-dir/-/make-dir-3.1.0.tgz#415e967046b3a7f1d185277d84aa58203726a13f" @@ -5484,28 +5462,6 @@ make-error@^1, make-error@^1.1.1: resolved "https://registry.yarnpkg.com/make-error/-/make-error-1.3.6.tgz#2eb2e37ea9b67c4891f684a1394799af484cf7a2" integrity sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw== -make-fetch-happen@^10.0.1, make-fetch-happen@^10.0.2: - version "10.0.3" - resolved "https://registry.yarnpkg.com/make-fetch-happen/-/make-fetch-happen-10.0.3.tgz#94bbe675cf62a811dbab59668052388a078beaf2" - integrity sha512-CzarPHynPpHjhF5in/YapnO44rSZeYX5VCMfdXa99+gLwpbfFLh20CWa6dP/taV9Net9PWJwXNKtp/4ZTCQnag== - dependencies: - agentkeepalive "^4.2.0" - cacache "^15.3.0" - http-cache-semantics "^4.1.0" - http-proxy-agent "^5.0.0" - https-proxy-agent "^5.0.0" - is-lambda "^1.0.1" - lru-cache "^7.3.1" - minipass "^3.1.6" - minipass-collect "^1.0.2" - minipass-fetch "^1.4.1" - minipass-flush "^1.0.5" - minipass-pipeline "^1.2.4" - negotiator "^0.6.3" - promise-retry "^2.0.1" - socks-proxy-agent "^6.1.1" - ssri "^8.0.1" - make-fetch-happen@^9.0.1, make-fetch-happen@^9.1.0: version "9.1.0" resolved "https://registry.yarnpkg.com/make-fetch-happen/-/make-fetch-happen-9.1.0.tgz#53085a09e7971433e6765f7971bf63f4e05cb968" @@ -5702,13 +5658,6 @@ minimatch@^3.0.2, minimatch@^3.0.3, minimatch@^3.0.4: dependencies: brace-expansion "^1.1.7" -minimatch@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-5.0.0.tgz#281d8402aaaeed18a9e8406ad99c46a19206c6ef" - integrity sha512-EU+GCVjXD00yOUf1TwAHVP7v3fBD3A8RkkPYsWWKGWesxM/572sL53wJQnHxquHlRhYUV36wHkqrN8cdikKc2g== - dependencies: - brace-expansion "^2.0.1" - minimist-options@4.1.0: version "4.1.0" resolved "https://registry.yarnpkg.com/minimist-options/-/minimist-options-4.1.0.tgz#c0655713c53a8a2ebd77ffa247d342c40f010619" @@ -5735,7 +5684,7 @@ minipass-collect@^1.0.2: dependencies: minipass "^3.0.0" -minipass-fetch@^1.3.0, minipass-fetch@^1.3.2, minipass-fetch@^1.4.1: +minipass-fetch@^1.3.0, minipass-fetch@^1.3.2: version "1.4.1" resolved "https://registry.yarnpkg.com/minipass-fetch/-/minipass-fetch-1.4.1.tgz#d75e0091daac1b0ffd7e9d41629faff7d0c1f1b6" integrity sha512-CGH1eblLq26Y15+Azk7ey4xh0J/XfJfrCox5LDJiKqI2Q2iwOLOKrlmIaODiSQS8d18jalF6y2K2ePUm0CmShw== @@ -5775,14 +5724,14 @@ minipass-sized@^1.0.3: dependencies: minipass "^3.0.0" -minipass@^3.0.0, minipass@^3.1.0, minipass@^3.1.1, minipass@^3.1.3, minipass@^3.1.6: +minipass@^3.0.0, minipass@^3.1.0, minipass@^3.1.1, minipass@^3.1.3: version "3.1.6" resolved "https://registry.yarnpkg.com/minipass/-/minipass-3.1.6.tgz#3b8150aa688a711a1521af5e8779c1d3bb4f45ee" integrity sha512-rty5kpw9/z8SX9dmxblFA6edItUmwJgMeYDZRrwlIVN27i8gysGbznJwUggw2V/FVqFSDdWy040ZPS811DYAqQ== dependencies: yallist "^4.0.0" -minizlib@^2.0.0, minizlib@^2.1.1, minizlib@^2.1.2: +minizlib@^2.0.0, minizlib@^2.1.1: version "2.1.2" resolved "https://registry.yarnpkg.com/minizlib/-/minizlib-2.1.2.tgz#e90d3466ba209b932451508a11ce3d3632145931" integrity sha512-bAxsR8BVfj60DWXHE3u30oHzfl4G7khkSuPW+qvpd7jFRHm7dLxOjUk1EHACJ/hxLY8phGJ0YhYHZo7jil7Qdg== @@ -5932,7 +5881,7 @@ natural-compare@^1.4.0: resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" integrity sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc= -negotiator@^0.6.2, negotiator@^0.6.3: +negotiator@^0.6.2: version "0.6.3" resolved "https://registry.yarnpkg.com/negotiator/-/negotiator-0.6.3.tgz#58e323a72fedc0d6f9cd4d31fe49f51479590ccd" integrity sha512-+EUsqGPLsM+j/zdChZjsnX51g4XrHFOIXwfnCVPGlQk/k5giakcKsuxCObBRu6DSm9opw/O6slWbJdghQM4bBg== @@ -6112,15 +6061,6 @@ npm-package-arg@^8.0.0, npm-package-arg@^8.0.1, npm-package-arg@^8.1.0, npm-pack semver "^7.3.4" validate-npm-package-name "^3.0.0" -npm-package-arg@^9.0.0: - version "9.0.0" - resolved "https://registry.yarnpkg.com/npm-package-arg/-/npm-package-arg-9.0.0.tgz#955a5e4735298fc23f71cb72da3574daa134340c" - integrity sha512-yhzXxeor+Zfhe5MGwPdDumz6HtNlj2pMekWB95IX3CC6uDNgde0oPKHDCLDPoJqQfd0HqAWt+y4Hs5m7CK1+9Q== - dependencies: - hosted-git-info "^4.1.0" - semver "^7.3.5" - validate-npm-package-name "^3.0.0" - npm-packlist@^2.1.4: version "2.2.2" resolved "https://registry.yarnpkg.com/npm-packlist/-/npm-packlist-2.2.2.tgz#076b97293fa620f632833186a7a8f65aaa6148c8" @@ -6141,13 +6081,12 @@ npm-pick-manifest@^6.0.0, npm-pick-manifest@^6.1.0, npm-pick-manifest@^6.1.1: npm-package-arg "^8.1.2" semver "^7.3.4" -npm-profile@^6.0.0: - version "6.0.2" - resolved "https://registry.yarnpkg.com/npm-profile/-/npm-profile-6.0.2.tgz#b2da9887d16d1f0d1ce8a9c3b37a48454a372919" - integrity sha512-0Fq8l+A10YXnnS63E3HThWjOb7+19Wsh1nOVutC2fKuowar8t/5PpINsbcm5xQ2dA28uAu+wjFfUyiEVSMz4Jw== +npm-profile@^5.0.3: + version "5.0.4" + resolved "https://registry.yarnpkg.com/npm-profile/-/npm-profile-5.0.4.tgz#73e5bd1d808edc2c382d7139049cc367ac43161b" + integrity sha512-OKtU7yoAEBOnc8zJ+/uo5E4ugPp09sopo+6y1njPp+W99P8DvQon3BJYmpvyK2Bf1+3YV5LN1bvgXRoZ1LUJBA== dependencies: - npm-registry-fetch "^13.0.0" - proc-log "^2.0.0" + npm-registry-fetch "^11.0.0" npm-registry-fetch@^11.0.0: version "11.0.0" @@ -6161,31 +6100,6 @@ npm-registry-fetch@^11.0.0: minizlib "^2.0.0" npm-package-arg "^8.0.0" -npm-registry-fetch@^12.0.0, npm-registry-fetch@^12.0.1, npm-registry-fetch@^12.0.2: - version "12.0.2" - resolved "https://registry.yarnpkg.com/npm-registry-fetch/-/npm-registry-fetch-12.0.2.tgz#ae583bb3c902a60dae43675b5e33b5b1f6159f1e" - integrity sha512-Df5QT3RaJnXYuOwtXBXS9BWs+tHH2olvkCLh6jcR/b/u3DvPMlp3J0TvvYwplPKxHMOwfg287PYih9QqaVFoKA== - dependencies: - make-fetch-happen "^10.0.1" - minipass "^3.1.6" - minipass-fetch "^1.4.1" - minipass-json-stream "^1.0.1" - minizlib "^2.1.2" - npm-package-arg "^8.1.5" - -npm-registry-fetch@^13.0.0: - version "13.0.0" - resolved "https://registry.yarnpkg.com/npm-registry-fetch/-/npm-registry-fetch-13.0.0.tgz#f0cf807f661184217651e0465668e4fd255fd6a8" - integrity sha512-MmiMuV9DU5gRuAU0jia952Qq+E4h7ZoUaeltCXivhClcqfOVKqNLZEQsRUOb6a8WQY+um8x97JcUuaWFoPoBBw== - dependencies: - make-fetch-happen "^10.0.2" - minipass "^3.1.6" - minipass-fetch "^1.4.1" - minipass-json-stream "^1.0.1" - minizlib "^2.1.2" - npm-package-arg "^9.0.0" - proc-log "^2.0.0" - npm-run-path@^4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/npm-run-path/-/npm-run-path-4.0.1.tgz#b7ecd1e5ed53da8e37a55e1c2269e0b97ed748ea" @@ -6901,11 +6815,6 @@ proc-log@^1.0.0: resolved "https://registry.yarnpkg.com/proc-log/-/proc-log-1.0.0.tgz#0d927307401f69ed79341e83a0b2c9a13395eb77" integrity sha512-aCk8AO51s+4JyuYGg3Q/a6gnrlDO09NpVWePtjp7xwphcoQ04x5WAfCyugcsbLooWcMJ87CLkD4+604IckEdhg== -proc-log@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/proc-log/-/proc-log-2.0.0.tgz#25f8cb346a5d08e27f2422b3ca6ba8379bcbf8ba" - integrity sha512-I/35MfCX2H8jBUhKN8JB8nmqvQo/nKdrBodBY7L3RhDSPPyvOHwLYNmPuhwuJq7a7C3vgFKWGQM+ecPStcvOHA== - process-nextick-args@^2.0.0, process-nextick-args@~2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.1.tgz#7820d9b16120cc55ca9ae7792680ae7dba6d7fe2" @@ -7545,7 +7454,7 @@ side-channel@^1.0.4: get-intrinsic "^1.0.2" object-inspect "^1.9.0" -signal-exit@^3.0.0, signal-exit@^3.0.2, signal-exit@^3.0.3, signal-exit@^3.0.7: +signal-exit@^3.0.0, signal-exit@^3.0.2, signal-exit@^3.0.3: version "3.0.7" resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.7.tgz#a9a1767f8af84155114eaabd73f99273c8f59ad9" integrity sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ== @@ -7667,7 +7576,7 @@ snowflake-sdk@^1.6.6: uuid "^3.3.2" winston "^3.1.0" -socks-proxy-agent@^6.0.0, socks-proxy-agent@^6.1.1: +socks-proxy-agent@^6.0.0: version "6.1.1" resolved "https://registry.yarnpkg.com/socks-proxy-agent/-/socks-proxy-agent-6.1.1.tgz#e664e8f1aaf4e1fb3df945f09e3d94f911137f87" integrity sha512-t8J0kG3csjA4g6FTbsMOWws+7R7vuRC8aQ/wy3/1OWmsgwA68zs/+cExQ0koSitUDXqhufF/YJr9wtNMZHw5Ew== @@ -8784,7 +8693,7 @@ wrappy@1: resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" integrity sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8= -write-file-atomic@^3.0.0: +write-file-atomic@^3.0.0, write-file-atomic@^3.0.3: version "3.0.3" resolved "https://registry.yarnpkg.com/write-file-atomic/-/write-file-atomic-3.0.3.tgz#56bd5c5a5c70481cd19c571bd39ab965a5de56e8" integrity sha512-AvHcyZ5JnSfq3ioSyjrBkH9yW4m7Ayk8/9My/DD9onKeu/94fwrMocemO2QAJFAlnnDN+ZDS+ZjAR5ua1/PV/Q== @@ -8794,14 +8703,6 @@ write-file-atomic@^3.0.0: signal-exit "^3.0.2" typedarray-to-buffer "^3.1.5" -write-file-atomic@^4.0.0: - version "4.0.1" - resolved "https://registry.yarnpkg.com/write-file-atomic/-/write-file-atomic-4.0.1.tgz#9faa33a964c1c85ff6f849b80b42a88c2c537c8f" - integrity sha512-nSKUxgAbyioruk6hU87QzVbY279oYT6uiwgDoujth2ju4mJ+TZau7SQBhtbTmUyuNYTuXnSyRn66FV0+eCgcrQ== - dependencies: - imurmurhash "^0.1.4" - signal-exit "^3.0.7" - "xml-name-validator@>= 2.0.1 < 3.0.0": version "2.0.1" resolved "https://registry.yarnpkg.com/xml-name-validator/-/xml-name-validator-2.0.1.tgz#4d8b8f1eccd3419aa362061becef515e1e559635"