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

[pickers] 5.0.0-beta.7 forces date-fns import even when not using date-fns #5966

Closed
2 tasks done
lenzi-e opened this issue Aug 30, 2022 · 2 comments
Closed
2 tasks done
Labels
component: pickers This is the name of the generic UI component, not the React module! duplicate This issue or pull request already exists

Comments

@lenzi-e
Copy link

lenzi-e commented Aug 30, 2022

Duplicates

  • I have searched the existing issues

Latest version

  • I have tested the latest version

Current behavior 😯

When using TypeScript, @mui/x-date-pickers-pro, yarn zero installs, and luxon adapter:

On 5.0.0-beta.6 I only needed the following packages for everything to work properly:

  • @mui/x-date-pickers-pro
  • luxon
  • @types/luxon
  • @mui/x-license-pro

On 5.0.0-beta.7 with the same packages, I get yarn errors on every test:

Cannot find module 'date-fns/locale/en-US' from '[ BLOCKING OUT MY LOCAL REPO FOLDER PATH ]/.yarn/__virtual__/@mui-x-date-pickers-virtual-7234c9173b/0/cache/@mui-x-date-pickers-npm-5.0.0-beta.7-8b8b1f43c6-985738535c.zip/node_modules/@mui/x-date-pickers/node/internals/hooks/useField'

On 5.0.0-beta.7 I now need to add date-fns to make everything work and need the following packages:

  • @mui/x-date-pickers-pro
  • luxon
  • @types/luxon
  • @mui/x-license-pro
  • date-fns

Expected behavior 🤔

When using TypeScript, @mui/x-date-pickers-pro, yarn zero installs, and luxon adapter:

On 5.0.0-beta.7 with the following packages installed, I would get no yarn errors:

  • @mui/x-date-pickers-pro
  • luxon
  • @types/luxon
  • @mui/x-license-pro

Steps to reproduce 🕹

Steps:

  1. Create a project using TypeScript, @mui/x-date-pickers-pro, yarn zero installs, and luxon adapter
  2. Use @mui/x-license-pro version 5.0.0-beta.7 without importing date-fns package

Context 🔦

No response

Your environment 🌎

npx @mui/envinfo
  System:
    OS: macOS 12.5.1
  Binaries:
    Node: 17.9.0 - /usr/local/bin/node
    Yarn: 3.2.3 - /usr/local/bin/yarn
    npm: 8.5.5 - /usr/local/bin/npm
  Browsers:
    Chrome: 104.0.5112.79
    Edge: Not Found
    Firefox: 103.0
    Safari: 15.6.1

Order ID 💳 (optional)

We pay for the PRO account, but I don't know how to find my order ID.

@lenzi-e lenzi-e added the status: waiting for maintainer These issues haven't been looked at yet by a maintainer label Aug 30, 2022
@flaviendelangle
Copy link
Member

Duplicates #5916
It is fixed and will be released on the next batch (probably tomorrow)
You can say on beta.6 until then, sorry for the inconvenience.

@flaviendelangle flaviendelangle changed the title 5.0.0-beta.7 forces date-fns import even when not using date-fns [pickers] 5.0.0-beta.7 forces date-fns import even when not using date-fns Aug 31, 2022
@flaviendelangle flaviendelangle added duplicate This issue or pull request already exists component: pickers This is the name of the generic UI component, not the React module! and removed status: waiting for maintainer These issues haven't been looked at yet by a maintainer labels Aug 31, 2022
@lenzi-e
Copy link
Author

lenzi-e commented Sep 1, 2022

Duplicates #5916 It is fixed and will be released on the next batch (probably tomorrow) You can say on beta.6 until then, sorry for the inconvenience.

Thank you so much for the speedy resolution!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: pickers This is the name of the generic UI component, not the React module! duplicate This issue or pull request already exists
Projects
None yet
Development

No branches or pull requests

2 participants