Less.js: 3.8.0 '../lib/less/math-constants' -> '../lib/less/constants' rename breaks semver

Created on 23 Jul 2018  Â·  7Comments  Â·  Source: less/less.js

As can be seen in https://github.com/ant-design/ant-design/issues/11417 — 3.7.1 -> 3.8.0 update breaks real world packages, so it should be named 4.0.0 and this change should be reverted for 3.x branch.

Most helpful comment

For people who are facing this issue:

  • Remove less from your project
  • Remove all the less packages from yarn cache
  • Add the latest less again
  • Verify with yarn check

All 7 comments

@ojab How could this cause an issue? Internally, there are no Less references to math-constants, so I don't see why something would say the module could not be found, and the file itself hasn't existed for very long, and it's not on a public API.

I dug into this, it's a yarn bug
https://github.com/yarnpkg/yarn/issues/6139
reported and supposedly it's already solved in the nightly build

@anantoghosh Thanks for tracking that down! That was a confusing bug report.

For people who are facing this issue:

  • Remove less from your project
  • Remove all the less packages from yarn cache
  • Add the latest less again
  • Verify with yarn check

Thanks! I've assumed that math-constants is used somewhere in antd & it's rename have caused an issue.
Sorry for the confusion.

yarn cache clean && rm -rf node_modules/ && yarn worked for me (didn't have to remove less specifically)

I also had to reinstall all packages again, probably reinstalling less would suffice

Was this page helpful?
0 / 5 - 0 ratings