Skip to content
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

[@types/mime] Remove mime types in favour of mime@4.0.0 #69213

Merged
merged 1 commit into from
Mar 31, 2024

Conversation

ghost
Copy link

@ghost ghost commented Mar 30, 2024

Please fill in this template.

If removing a declaration:

  • If a package was never on Definitely Typed, you don't need to do anything. (If you wrote a package and provided types, you don't need to register it with us.)
  • Delete the package's directory.
  • Add it to notNeededPackages.json.

@ghost ghost marked this pull request as ready for review March 30, 2024 15:52
@typescript-bot
Copy link
Contributor

typescript-bot commented Mar 30, 2024

@codershiba Thank you for submitting this PR!

This is a live comment which I will keep updated.

This PR touches some part of DefinitelyTyped infrastructure, so a DT maintainer will need to review it. This is rare — did you mean to do this?

1 package in this PR (and infra files)

Code Reviews

Because this is a widely-used package, a DT maintainer will need to review it before it can be merged.

You can test the changes of this PR in the Playground.

Status

  • ✅ No merge conflicts
  • ✅ Continuous integration tests have passed
  • ✅ A DT maintainer needs to approve changes which affect DT infrastructure (notNeededPackages.json)

All of the items on the list are green. To merge, you need to post a comment including the string "Ready to merge" to bring in your changes.


Diagnostic Information: What the bot saw about this PR
{
  "type": "info",
  "now": "-",
  "pr_number": 69213,
  "author": "codershiba",
  "headCommitOid": "c4b3053db4d474bcc1e305436da96ec18da4eff1",
  "mergeBaseOid": "e59d0a7f1f9bc6dcdaa7cc1abe95cd3d9c6b81c7",
  "lastPushDate": "2024-03-30T15:52:33.000Z",
  "lastActivityDate": "2024-03-31T09:26:24.000Z",
  "mergeOfferDate": "2024-03-30T22:10:17.000Z",
  "mergeRequestDate": "2024-03-31T09:26:24.000Z",
  "mergeRequestUser": "codershiba",
  "hasMergeConflict": false,
  "isFirstContribution": false,
  "tooManyFiles": false,
  "hugeChange": false,
  "popularityLevel": "Critical",
  "pkgInfo": [
    {
      "name": null,
      "kind": "edit",
      "files": [
        {
          "path": "notNeededPackages.json",
          "kind": "infrastructure"
        }
      ],
      "owners": [],
      "addedOwners": [],
      "deletedOwners": [],
      "popularityLevel": "Critical",
      "isSafeInfrastructureEdit": false
    },
    {
      "name": "mime",
      "kind": "delete",
      "files": [
        {
          "path": "types/mime/.npmignore",
          "kind": "package-meta-ok"
        },
        {
          "path": "types/mime/Mime.d.ts",
          "kind": "definition"
        },
        {
          "path": "types/mime/index.d.ts",
          "kind": "definition"
        },
        {
          "path": "types/mime/lite.d.ts",
          "kind": "definition"
        },
        {
          "path": "types/mime/mime-tests.ts",
          "kind": "test"
        },
        {
          "path": "types/mime/package.json",
          "kind": "package-meta-ok"
        },
        {
          "path": "types/mime/tsconfig.json",
          "kind": "package-meta-ok"
        },
        {
          "path": "types/mime/v1/.npmignore",
          "kind": "package-meta-ok"
        },
        {
          "path": "types/mime/v1/Mime.d.ts",
          "kind": "definition"
        },
        {
          "path": "types/mime/v1/index.d.ts",
          "kind": "definition"
        },
        {
          "path": "types/mime/v1/lite.d.ts",
          "kind": "definition"
        },
        {
          "path": "types/mime/v1/mime-tests.ts",
          "kind": "test"
        },
        {
          "path": "types/mime/v1/package.json",
          "kind": "package-meta-ok"
        },
        {
          "path": "types/mime/v1/tsconfig.json",
          "kind": "package-meta-ok"
        }
      ],
      "owners": [
        "jedigo",
        "dhritzkiv"
      ],
      "addedOwners": [],
      "deletedOwners": [],
      "popularityLevel": "Critical"
    }
  ],
  "reviews": [
    {
      "type": "approved",
      "reviewer": "peterblazejewicz",
      "date": "2024-03-30T22:09:34.000Z",
      "isMaintainer": true
    },
    {
      "type": "approved",
      "reviewer": "dhritzkiv",
      "date": "2024-03-30T15:58:11.000Z",
      "isMaintainer": false
    }
  ],
  "mainBotCommentID": 2028163564,
  "ciResult": "pass"
}

@typescript-bot
Copy link
Contributor

🔔 @jedigo @dhritzkiv — please review this PR in the next few days. Be sure to explicitly select Approve or Request Changes in the GitHub UI so I know what's going on.

@typescript-bot typescript-bot added this to Waiting for Code Reviews in New Pull Request Status Board Mar 30, 2024
@typescript-bot typescript-bot added the Owner Approved A listed owner of this package signed off on the pull request. label Mar 30, 2024
@typescript-bot typescript-bot moved this from Waiting for Code Reviews to Needs Maintainer Action in New Pull Request Status Board Mar 30, 2024
Copy link
Member

@peterblazejewicz peterblazejewicz left a comment

Choose a reason for hiding this comment

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

@codershiba thanks!

@typescript-bot typescript-bot added Maintainer Approved Self Merge This PR can now be self-merged by the PR author or an owner labels Mar 30, 2024
@typescript-bot typescript-bot moved this from Needs Maintainer Action to Waiting for Author to Merge in New Pull Request Status Board Mar 30, 2024
@ghost
Copy link
Author

ghost commented Mar 31, 2024

Ready to merge

@typescript-bot typescript-bot moved this from Waiting for Author to Merge to Recently Merged in New Pull Request Status Board Mar 31, 2024
@typescript-bot typescript-bot merged commit 8de1d4d into DefinitelyTyped:master Mar 31, 2024
4 checks passed
@ghost ghost deleted the remove-mime branch March 31, 2024 09:29
@typescript-bot typescript-bot removed this from Recently Merged in New Pull Request Status Board Mar 31, 2024
@esetnik
Copy link
Contributor

esetnik commented Apr 1, 2024

@codershiba this breaks @types/serve-static which depends on @types/mime https://github.com/DefinitelyTyped/DefinitelyTyped/blob/master/types/serve-static/index.d.ts#L4C21-L4C25.

See #69231

@ghost
Copy link
Author

ghost commented Apr 1, 2024

@codershiba this breaks @types/serve-static which depends on @types/mime https://github.com/DefinitelyTyped/DefinitelyTyped/blob/master/types/serve-static/index.d.ts#L4C21-L4C25.

See #69231

Yeah I have tried to fix this in PR #69231 by pinning the version to a lower version.

@jakebailey
Copy link
Member

We should revert this; this PR should not have modified notNeededPaackages as the mime types are far too popular (22M weekly!!!) for a shim package to work.

jakebailey added a commit to jakebailey/DefinitelyTyped that referenced this pull request Apr 2, 2024
…pes in favour of `mime@4.0.0` by @codershiba"

This reverts commit 8de1d4d.
@jakebailey
Copy link
Member

Er, it's too late, @types/mime was published as a shim at v4, so we can't undo that. All we can do is start switching users to v3 when needed, and everyone else needs to be pinning to the right major version, as the DT types versioning aren't wrong here.

@peterblazejewicz
Copy link
Member

Sorry for this, I could have undervalued the v3, it was listed as updated (npm) 2 years ago.

@jakebailey
Copy link
Member

No worries, I think the shim is actually okay in this instance given it's a clear major version difference. But it's also a failure of the tooling that we did not detect that the other package would break.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Critical package Edits Infrastructure Maintainer Approved Owner Approved A listed owner of this package signed off on the pull request. Self Merge This PR can now be self-merged by the PR author or an owner
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants