Comments (5)
This should now be fixed by using the github.com/tdewolff/parse/v2
import path!
from parse.
Should be fixed, see https://github.com/tdewolff/minify/releases/tag/v2.3.7!!
from parse.
Thanks for your time @aofei, do you think we can make this work without updating the v1 branch? Version 1 is out-dated an unsupported and should not be receiving updates. I'm afraid that users with an older Go version might get reverted to version 1 if they don't update their import paths.
Additionally, while a new v3 might not be necessary, as import paths need to be updated this is a major breaking change which should bring out a new major version. But I guess we can just ignore that though and keep it on v2...that could work for me.
I'm also quite inclined to ignore Go modules as it seems to handle libraries versioned like mine poorly, does it currently not just grab the latest version since there is no go.mod
anymore?
EDIT: Let's see what they say: https://www.reddit.com/r/golang/comments/9u9pt6/go_modules_start_at_v2/
from parse.
It seems that the Go module tool has checked out the latest tag (v2.3.4). Since it has a go.mod
file inside, and its module path is invalid (missing /v2
suffix), so... crack...
Releasing a new version (maybe v2.3.5
) without a go.mod
file seems to temporarily solve the check out problem. But that is definitely not a good solution, isn't it? I mean, after all, the Go module will become more and more supported anyway. Why not start supporting now?
In fact, changes to v1 can be ignored. Just need to consider v2.
...
I'm afraid that users with an older Go version might get reverted to version 1 if they don't update their import paths.
...
Emmm, yeah, this will be a very serious consequence...
...
This section so far has been focused on code that opts in to modules. However, putting major versions in import paths for v2+ modules could create incompatibilities with older versions of Go, or with code that has not yet opted in to modules. To help with this, Go versions 1.9.7+, 1.10.3+ and 1.11 have been updated so that code built with those releases can properly consume v2+ modules without requiring modification of pre-existing code. (When relying on this updated mechanism, a package that has not opted in to modules would not include the major version in the import path for any imported v2+ modules. In contrast, a package that has opted in to modules must include the major version in the import path for any imported v2+ modules).
...
According to the Modules, section Semantic Import Versioning, it's not a big problem for the Go >= v1.9. But for older versions, seems that they will all fail to run go get
.
I personally think that changing the import path is acceptable. After all, it's now a problem, and it will still be a problem in the future (even if v3 is released). Or, freeze the master branch (for older Go versions, just like the russross/blackfriday), and only commit new changes to the v2 branch in the future. In this way, nothing will break. But that would be weird.
from parse.
Awesome! I believe that you have made a very good choice.
Now, I think it's time to fix tdewolff/minify.
from parse.
Related Issues (20)
- Fast js detection HOT 1
- What is the advantages of html lexer of this package? HOT 2
- Questions about JS() method and String() method in js ast code HOT 3
- Rule case will be modified when parse css HOT 2
- CSS parser ignoring comments within rulesets HOT 1
- Is pretty-printing JS in-scope? HOT 5
- JS: tokenizing regular expressions HOT 7
- JS: Error parsing incremental operator in comparison HOT 1
- Typescript and jsx,tsx support HOT 2
- Document usage of JS parsers HOT 1
- question about media queries HOT 2
- JS parser doesn't handle \u2028 and \u2029 like modern browsers HOT 1
- export const { name1, internal: name2 } = obj AST representation HOT 8
- Top-level await HOT 12
- Whether there is js AST to json format with scope ? HOT 5
- CSS Nesting HOT 5
- JS parser: get the expression of a declared variable. HOT 3
- Wrong handling of JS numeric separators in some circumstances HOT 1
- v2.5.33 backwards-breaks packages depending on it, including current github.com/tdewolff/minify/v2 HOT 2
- js parser accepts a single backtick as valid js HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from parse.