Skip to content
This repository has been archived by the owner on Jul 1, 2024. It is now read-only.

Don't treat mts/cts files as config files by using same check as dt-tools #488

Merged
merged 4 commits into from
Feb 26, 2024
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
895 changes: 838 additions & 57 deletions package-lock.json
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This adds 1000 lines to the package-json; I can copy the glob out instead if that feels better. I doubt it will change.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Slightly better after refactoring dt-tools, but still pulling in stuff. Maybe that's okay.

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,9 @@
"license": "MIT",
"dependencies": {
"@apollo/client": "latest",
"@definitelytyped/old-header-parser": "npm:@definitelytyped/[email protected]",
"@azure/functions": "^4.0.0-alpha.1",
"@definitelytyped/old-header-parser": "npm:@definitelytyped/[email protected]",
"@definitelytyped/utils": "^0.1.5",
"@octokit/webhooks": "^9.5.1",
"dayjs": "^1.10.3",
"fast-json-patch": "^3.0.0-1",
Expand Down
3 changes: 1 addition & 2 deletions src/_tests/fixtures/67090/derived.json
Original file line number Diff line number Diff line change
Expand Up @@ -100,8 +100,7 @@
"files": [
{
"path": "types/marked-terminal/index.d.cts",
"kind": "package-meta",
"suspect": "edited"
"kind": "definition"
},
{
"path": "types/marked-terminal/index.d.ts",
Expand Down
2 changes: 1 addition & 1 deletion src/_tests/fixtures/67090/mutations.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"variables": {
"input": {
"id": "IC_kwDOAFz6BM5pVwbO",
"body": "@andrewbranch Thank you for submitting this PR!\n\n***This is a live comment which I will keep updated.***\n\n## 3 packages in this PR\n\n* `ansicolors` — [on npm](https://www.npmjs.com/package/ansicolors), [on unpkg](https://unpkg.com/browse/ansicolors@latest/)\n* `cardinal` (*new!*) — [on npm](https://www.npmjs.com/package/cardinal), [on unpkg](https://unpkg.com/browse/cardinal@latest/)\n - 1 added owner: ✎@andrewbranch\n - Config files to check:\n - [`cardinal/tslint.json`](https://github.com/DefinitelyTyped/DefinitelyTyped/pull/67090/files/bb7d42f514b9f9cfca6b9a84dc99fac76ac35643#diff-9f471f9ba6ffa73024ae9aeb049dd98078364c565db83ee831e0498cbb678d67): edited\n* `marked-terminal` — [on npm](https://www.npmjs.com/package/marked-terminal), [on unpkg](https://unpkg.com/browse/marked-terminal@latest/)\n - Config files to check:\n - [`marked-terminal/index.d.cts`](https://github.com/DefinitelyTyped/DefinitelyTyped/pull/67090/files/bb7d42f514b9f9cfca6b9a84dc99fac76ac35643#diff-5e4cfea677a3d26cff8f1c90abf32caa2f3c310beee12f6f84364821c728aef6): edited\n - [`marked-terminal/marked-terminal-tests.cts`](https://github.com/DefinitelyTyped/DefinitelyTyped/pull/67090/files/bb7d42f514b9f9cfca6b9a84dc99fac76ac35643#diff-c57707862a9de137333983d3c0ee294d8a046f4f23a7e2557f7c4f4c77529dd7): edited\n\n## Code Reviews\n\nThis PR adds a new definition, so it needs to be reviewed by a DT maintainer before it can be merged.\n\nYou can test the changes of this PR [in the Playground](https://www.typescriptlang.org/play/?dtPR=67090&install-plugin=playground-dt-review).\n\n## Status\n\n * ✅ No merge conflicts\n * ❌ Continuous integration tests have failed\n * 🕐 Only a DT maintainer can approve changes when there are new packages added\n\nOnce every item on this list is checked, I'll ask you for permission to merge and publish the changes.\n\n----------------------\n... diagnostics scrubbed ...\n<!--typescript_bot_welcome-->"
"body": "@andrewbranch Thank you for submitting this PR!\n\n***This is a live comment which I will keep updated.***\n\n## 3 packages in this PR\n\n* `ansicolors` — [on npm](https://www.npmjs.com/package/ansicolors), [on unpkg](https://unpkg.com/browse/ansicolors@latest/)\n* `cardinal` (*new!*) — [on npm](https://www.npmjs.com/package/cardinal), [on unpkg](https://unpkg.com/browse/cardinal@latest/)\n - 1 added owner: ✎@andrewbranch\n - Config files to check:\n - [`cardinal/tslint.json`](https://github.com/DefinitelyTyped/DefinitelyTyped/pull/67090/files/bb7d42f514b9f9cfca6b9a84dc99fac76ac35643#diff-9f471f9ba6ffa73024ae9aeb049dd98078364c565db83ee831e0498cbb678d67): edited\n* `marked-terminal` — [on npm](https://www.npmjs.com/package/marked-terminal), [on unpkg](https://unpkg.com/browse/marked-terminal@latest/)\n - Config files to check:\n - [`marked-terminal/marked-terminal-tests.cts`](https://github.com/DefinitelyTyped/DefinitelyTyped/pull/67090/files/bb7d42f514b9f9cfca6b9a84dc99fac76ac35643#diff-c57707862a9de137333983d3c0ee294d8a046f4f23a7e2557f7c4f4c77529dd7): edited\n\n## Code Reviews\n\nThis PR adds a new definition, so it needs to be reviewed by a DT maintainer before it can be merged.\n\nYou can test the changes of this PR [in the Playground](https://www.typescriptlang.org/play/?dtPR=67090&install-plugin=playground-dt-review).\n\n## Status\n\n * ✅ No merge conflicts\n * ❌ Continuous integration tests have failed\n * 🕐 Only a DT maintainer can approve changes when there are new packages added\n\nOnce every item on this list is checked, I'll ask you for permission to merge and publish the changes.\n\n----------------------\n... diagnostics scrubbed ...\n<!--typescript_bot_welcome-->"
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/_tests/fixtures/67090/result.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"responseComments": [
{
"tag": "welcome",
"status": "@andrewbranch Thank you for submitting this PR!\n\n***This is a live comment which I will keep updated.***\n\n## 3 packages in this PR\n\n* `ansicolors` — [on npm](https://www.npmjs.com/package/ansicolors), [on unpkg](https://unpkg.com/browse/ansicolors@latest/)\n* `cardinal` (*new!*) — [on npm](https://www.npmjs.com/package/cardinal), [on unpkg](https://unpkg.com/browse/cardinal@latest/)\n - 1 added owner: ✎@andrewbranch\n - Config files to check:\n - [`cardinal/tslint.json`](https://github.com/DefinitelyTyped/DefinitelyTyped/pull/67090/files/bb7d42f514b9f9cfca6b9a84dc99fac76ac35643#diff-9f471f9ba6ffa73024ae9aeb049dd98078364c565db83ee831e0498cbb678d67): edited\n* `marked-terminal` — [on npm](https://www.npmjs.com/package/marked-terminal), [on unpkg](https://unpkg.com/browse/marked-terminal@latest/)\n - Config files to check:\n - [`marked-terminal/index.d.cts`](https://github.com/DefinitelyTyped/DefinitelyTyped/pull/67090/files/bb7d42f514b9f9cfca6b9a84dc99fac76ac35643#diff-5e4cfea677a3d26cff8f1c90abf32caa2f3c310beee12f6f84364821c728aef6): edited\n - [`marked-terminal/marked-terminal-tests.cts`](https://github.com/DefinitelyTyped/DefinitelyTyped/pull/67090/files/bb7d42f514b9f9cfca6b9a84dc99fac76ac35643#diff-c57707862a9de137333983d3c0ee294d8a046f4f23a7e2557f7c4f4c77529dd7): edited\n\n## Code Reviews\n\nThis PR adds a new definition, so it needs to be reviewed by a DT maintainer before it can be merged.\n\nYou can test the changes of this PR [in the Playground](https://www.typescriptlang.org/play/?dtPR=67090&install-plugin=playground-dt-review).\n\n## Status\n\n * ✅ No merge conflicts\n * ❌ Continuous integration tests have failed\n * 🕐 Only a DT maintainer can approve changes when there are new packages added\n\nOnce every item on this list is checked, I'll ask you for permission to merge and publish the changes.\n\n----------------------\n... diagnostics scrubbed ..."
"status": "@andrewbranch Thank you for submitting this PR!\n\n***This is a live comment which I will keep updated.***\n\n## 3 packages in this PR\n\n* `ansicolors` — [on npm](https://www.npmjs.com/package/ansicolors), [on unpkg](https://unpkg.com/browse/ansicolors@latest/)\n* `cardinal` (*new!*) — [on npm](https://www.npmjs.com/package/cardinal), [on unpkg](https://unpkg.com/browse/cardinal@latest/)\n - 1 added owner: ✎@andrewbranch\n - Config files to check:\n - [`cardinal/tslint.json`](https://github.com/DefinitelyTyped/DefinitelyTyped/pull/67090/files/bb7d42f514b9f9cfca6b9a84dc99fac76ac35643#diff-9f471f9ba6ffa73024ae9aeb049dd98078364c565db83ee831e0498cbb678d67): edited\n* `marked-terminal` — [on npm](https://www.npmjs.com/package/marked-terminal), [on unpkg](https://unpkg.com/browse/marked-terminal@latest/)\n - Config files to check:\n - [`marked-terminal/marked-terminal-tests.cts`](https://github.com/DefinitelyTyped/DefinitelyTyped/pull/67090/files/bb7d42f514b9f9cfca6b9a84dc99fac76ac35643#diff-c57707862a9de137333983d3c0ee294d8a046f4f23a7e2557f7c4f4c77529dd7): edited\n\n## Code Reviews\n\nThis PR adds a new definition, so it needs to be reviewed by a DT maintainer before it can be merged.\n\nYou can test the changes of this PR [in the Playground](https://www.typescriptlang.org/play/?dtPR=67090&install-plugin=playground-dt-review).\n\n## Status\n\n * ✅ No merge conflicts\n * ❌ Continuous integration tests have failed\n * 🕐 Only a DT maintainer can approve changes when there are new packages added\n\nOnce every item on this list is checked, I'll ask you for permission to merge and publish the changes.\n\n----------------------\n... diagnostics scrubbed ..."
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like we need to account for non-declaration test files too:

  • Config files to check:\n - [marked-terminal/marked-terminal-tests.cts]

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Aha, yes.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's even more weird edge cases here... may do a little refactoring to fix them.

},
{
"tag": "pinging-reviewers",
Expand Down
3 changes: 3 additions & 0 deletions src/_tests/fixtures/68772/_downloads.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"relationship.js": 21
}
6 changes: 6 additions & 0 deletions src/_tests/fixtures/68772/_files.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"3f76a3a2d73f3fe577d32ca07c73c79016707328:types/relationship.js/package.json": "{\n \"private\": true,\n \"name\": \"@types/relationship.js\",\n \"version\": \"1.2.9999\",\n \"projects\": [\n \"https://passer-by.com/relationship/\"\n ],\n \"devDependencies\": {\n \"@types/relationship.js\": \"workspace:.\"\n },\n \"exports\": {\n \".\": {\n \"import\": \"./dist/relationship.min.d.mts\",\n \"require\": \"./dist/relationship.min.d.ts\",\n \"default\": \"./dist/relationship.min.d.ts\"\n },\n \"./mode\": {\n \"import\": \"./dist/relationship-mode.min.d.mts\",\n \"require\": \"./dist/relationship-mode.min.d.ts\",\n \"default\": \"./dist/relationship-mode.min.d.ts\"\n },\n \"./zh-HK\": {\n \"import\": \"./dist/relationship.min.d.mts\",\n \"require\": \"./dist/relationship.min.d.ts\",\n \"default\": \"./dist/relationship.min.d.ts\"\n },\n \"./zh-HK/mode\": {\n \"import\": \"./dist/relationship-mode.min.d.mts\",\n \"require\": \"./dist/relationship-mode.min.d.ts\",\n \"default\": \"./dist/relationship-mode.min.d.ts\"\n }\n },\n \"owners\": [\n {\n \"name\": \"whincwu\",\n \"githubUsername\": \"whinc\"\n }\n ]\n}\n",
"dd92afb5a03c591944601de73a58bf49bb31e1dc:types/relationship.js/package.json": "{\n \"private\": true,\n \"name\": \"@types/relationship.js\",\n \"version\": \"1.2.9999\",\n \"projects\": [\n \"https://passer-by.com/relationship/\"\n ],\n \"devDependencies\": {\n \"@types/relationship.js\": \"workspace:.\"\n },\n \"owners\": [\n {\n \"name\": \"whincwu\",\n \"githubUsername\": \"whinc\"\n }\n ]\n}\n",
"3f76a3a2d73f3fe577d32ca07c73c79016707328:types/relationship.js/tsconfig.json": "{\n \"compilerOptions\": {\n \"module\": \"node16\",\n \"lib\": [\n \"es6\"\n ],\n \"noImplicitAny\": true,\n \"noImplicitThis\": true,\n \"strictFunctionTypes\": true,\n \"strictNullChecks\": true,\n \"types\": [],\n \"noEmit\": true,\n \"forceConsistentCasingInFileNames\": true\n },\n \"files\": [\n \"index.d.ts\",\n \"dist/relationship.min.d.ts\",\n \"dist/relationship.min.d.mts\",\n \"dist/relationship-mode.min.d.ts\",\n \"dist/relationship-mode.min.d.mts\",\n \"relationship.js-tests.ts\"\n ]\n}\n",
"dd92afb5a03c591944601de73a58bf49bb31e1dc:types/relationship.js/tsconfig.json": "{\n \"compilerOptions\": {\n \"module\": \"node16\",\n \"lib\": [\n \"es6\"\n ],\n \"noImplicitAny\": true,\n \"noImplicitThis\": true,\n \"strictFunctionTypes\": true,\n \"strictNullChecks\": true,\n \"types\": [],\n \"noEmit\": true,\n \"forceConsistentCasingInFileNames\": true\n },\n \"files\": [\n \"index.d.ts\",\n \"relationship.js-tests.ts\"\n ]\n}\n"
}
Loading
Loading