Skip to content

fix: bumped up [at]types/tar to fix the error TS2709: Cannot use namespace 'MiniPass' as a type #845

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 2 commits into from

Conversation

zhaow-de
Copy link

@zhaow-de zhaow-de commented Jul 26, 2022

For my application with dependencies:

{
  "dependencies": {
    "@kubernetes/client-node": "^0.17.0",
    "aws-sdk": "^2.1181.0",
    "dotenv": "^16.0.1",
    "request": "^2.88.2",
    "request-promise": "^4.2.6",
    "winston": "^3.8.1"
  },
  "devDependencies": {
    "@types/jest": "^28.1.6",
    "@types/request": "^2.48.8",
    "@types/request-promise": "^4.1.48",
    "core-js": "^3.24.0",
    "jest": "^28.1.3",
    "jest-coverage-badges": "^1.1.2",
    "nock": "^13.2.9",
    "ts-jest": "^28.0.7",
    "typemoq": "^2.1.0",
    "typescript": "^4.7.4"
  }
}

npx tsc is failing because:

node_modules/@types/tar/index.d.ts:252:36 - error TS2709: Cannot use namespace 'MiniPass' as a type.
252 export interface ReadEntry extends MiniPass, HeaderProperties {
                                       ~~~~~~~~
Found 1 error in node_modules/@types/tar/index.d.ts:252

Bumping up the version of @types/tar from 4.x to 6.x matching tar and added explicit dependency to minipass solve the problem.

Refer to DefinitelyTyped/DefinitelyTyped#60901

@k8s-ci-robot k8s-ci-robot added the do-not-merge/invalid-commit-message Indicates that a PR should not merge because it has an invalid commit message. label Jul 26, 2022
@linux-foundation-easycla
Copy link

linux-foundation-easycla bot commented Jul 26, 2022

CLA Signed

The committers listed above are authorized under a signed CLA.

  • ✅ login: zhaow-de / name: Zhao Wang (41394d1)

@k8s-ci-robot
Copy link
Contributor

Keywords which can automatically close issues and at(@) mentions are not allowed in the title of a Pull Request.

You can edit the title by writing /retitle in a comment.

When GitHub merges a Pull Request, the title is included in the merge commit. To avoid invalid keywords in the merge commit, please edit the title of the PR.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@k8s-ci-robot k8s-ci-robot added the cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. label Jul 26, 2022
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: zhaow-de
Once this PR has been reviewed and has the lgtm label, please assign brendandburns for approval by writing /assign @brendandburns in a comment. For more information see:The Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot
Copy link
Contributor

Welcome @zhaow-de!

It looks like this is your first PR to kubernetes-client/javascript 🎉. Please refer to our pull request process documentation to help your PR have a smooth ride to approval.

You will be prompted by a bot to use commands during the review process. Do not be afraid to follow the prompts! It is okay to experiment. Here is the bot commands documentation.

You can also check if kubernetes-client/javascript has its own contribution guidelines.

You may want to refer to our testing guide if you run into trouble with your tests not passing.

If you are having difficulty getting your pull request seen, please follow the recommended escalation practices. Also, for tips and tricks in the contribution process you may want to read the Kubernetes contributor cheat sheet. We want to make sure your contribution gets all the attention it needs!

Thank you, and welcome to Kubernetes. 😃

@k8s-ci-robot k8s-ci-robot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. and removed cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. labels Jul 26, 2022
@zhaow-de zhaow-de changed the title fix: bumped up @types/tar to fix the error TS2709: Cannot use namespace 'MiniPass' as a type fix: bumped up [at]types/tar to fix the error TS2709: Cannot use namespace 'MiniPass' as a type Jul 26, 2022
@k8s-ci-robot k8s-ci-robot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Jul 26, 2022
@k8s-ci-robot
Copy link
Contributor

Keywords which can automatically close issues and at(@) or hashtag(#) mentions are not allowed in commit messages.

The list of commits with invalid commit messages:

  • 41394d1 fix: bumped up @types/tar to fix the error TS2709: Cannot use namespace 'MiniPass' as a type
  • 8416778 fix: explicitly added minipass to the dependency to override the unnecessary @types/minipass

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@brendandburns
Copy link
Contributor

Hrm, since that is a transitive dependency of the tar package, I'm not sure why we need to add this dependency? Shouldn't it be a dependency of tar?

@k8s-ci-robot
Copy link
Contributor

@zhaow-de: PR needs rebase.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jul 30, 2022
@yotamselementor
Copy link

This #847 should fix this issue - I moved the problematic dependencies to devDependencies.
If anyone could create a new release, it would be great.
Maybe @brendandburns could help out here.

@alvesalex
Copy link

This #847 should fix this issue - I moved the problematic dependencies to devDependencies. If anyone could create a new release, it would be great. Maybe @brendandburns could help out here.

I appreciate if we get a new release for 0.15.x as well.

@skhaz
Copy link

skhaz commented Aug 19, 2022

I am having this issue

@k8s-triage-robot
Copy link

The Kubernetes project currently lacks enough contributors to adequately respond to all issues and PRs.

This bot triages issues and PRs according to the following rules:

  • After 90d of inactivity, lifecycle/stale is applied
  • After 30d of inactivity since lifecycle/stale was applied, lifecycle/rotten is applied
  • After 30d of inactivity since lifecycle/rotten was applied, the issue is closed

You can:

  • Mark this issue or PR as fresh with /remove-lifecycle stale
  • Mark this issue or PR as rotten with /lifecycle rotten
  • Close this issue or PR with /close
  • Offer to help out with Issue Triage

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

@k8s-ci-robot k8s-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Nov 17, 2022
@yotamselementor
Copy link

/remove-lifecycle stale

@k8s-ci-robot k8s-ci-robot removed the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Nov 18, 2022
@brendandburns
Copy link
Contributor

Closing this since #924 merged and provides the same bump.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. do-not-merge/invalid-commit-message Indicates that a PR should not merge because it has an invalid commit message. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants