Conversation
PR Metrics✔ Thanks for keeping your pull request small.
Metrics computed by PR Metrics. Add it to your Azure DevOps and GitHub PRs! |
Super-linter summary
All files and directories linted successfully For more information, see the GitHub Actions workflow run Powered by Super-linter |
There was a problem hiding this comment.
Pull request overview
This PR reduces dependency footprint in the PR Metrics repo by replacing third-party packages with narrower or built-in alternatives (glob/file discovery in tests; Octokit client/error types in source and tests).
Changes:
- Replaced
globusage inresources.resjson.spec.tswith Node’sfs.globSync()and removedglobfrom devDependencies. - Replaced the
octokitumbrella dependency with@octokit/restand@octokit/request-error, updating imports across wrappers, repos invokers, and tests. - Updated lockfile to reflect removed/transitive packages.
Reviewed changes
Copilot reviewed 16 out of 18 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| src/task/tests/testUtilities/createRequestError.ts | Switches RequestError import to @octokit/request-error. |
| src/task/tests/Strings/resources.resjson.spec.ts | Uses fs.globSync() instead of globSync() for TS file discovery. |
| src/task/tests/repos/gitHubReposInvoker.spec.ts | Updates RequestError type import to @octokit/request-error. |
| src/task/src/wrappers/octokitWrapper.ts | Swaps Octokit client import to @octokit/rest while continuing to call REST endpoints via octokit.rest.*. |
| src/task/src/wrappers/octokitInterfaces/updatePullResponse.ts | Updates Octokit import source for response typing. |
| src/task/src/wrappers/octokitInterfaces/updateIssueCommentResponse.ts | Updates Octokit import source for response typing. |
| src/task/src/wrappers/octokitInterfaces/listCommitsResponse.ts | Updates Octokit import source for response typing. |
| src/task/src/wrappers/octokitInterfaces/getReviewCommentsResponse.ts | Updates Octokit import source for response typing. |
| src/task/src/wrappers/octokitInterfaces/getPullResponse.ts | Updates Octokit import source for response typing. |
| src/task/src/wrappers/octokitInterfaces/getIssueCommentsResponse.ts | Updates Octokit import source for response typing. |
| src/task/src/wrappers/octokitInterfaces/deleteReviewCommentResponse.ts | Updates Octokit import source for response typing. |
| src/task/src/wrappers/octokitInterfaces/createReviewCommentResponse.ts | Updates Octokit import source for response typing. |
| src/task/src/wrappers/octokitInterfaces/createIssueCommentResponse.ts | Updates Octokit import source for response typing. |
| src/task/src/repos/gitHubReposInvoker.ts | Switches RequestError import to @octokit/request-error for runtime instanceof handling. |
| package.json | Removes octokit and glob; adds @octokit/rest and @octokit/request-error. |
| package-lock.json | Lockfile updates reflecting dependency replacements/removals. |
Super-linter summary
All files and directories linted successfully For more information, see the GitHub Actions workflow run Powered by Super-linter |
Super-linter summary
All files and directories linted successfully For more information, see the GitHub Actions workflow run Powered by Super-linter |
Summary
globdev dependency with Node's built-infs.globSync(): Removes theglobpackage (v13.0.6) from devDependencies and usesfs.globSync()withcwdoption in the test fileresources.resjson.spec.ts. Results are mapped to absolute paths to match the prior behaviour.octokitumbrella with@octokit/rest+@octokit/request-error: Replaces the heavyoctokitumbrella package (which pulls in GraphQL, webhooks, OAuth, GitHub App auth, retry, and throttling) with the two specific packages actually used:@octokit/rest(v22.0.1) for REST API calls and@octokit/request-error(v7.1.0) for error handling. Updates all 14 source and test files that imported from"octokit".