-
Notifications
You must be signed in to change notification settings - Fork 130
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
3.1.0 has broken my typescript build #449
Comments
@mikesnare It appears that TypeScript will automatically load all @ejmarino The package does exist on the npm website, so I don't know why you're seeing that. Are you using a proxy? Or are you using a very old version of Node and NPM? |
This is how it always behaved, typings are always global, you cannot have two versions of the same typings. Especially for ambient typings like node it is not even possible to have conflict resolution - they are global by definition. Installing typings for the user will result in conflicts if the user has typings of the same package installed, which is why I was for #436 (comment). This just broke our builds - in a minor version. |
In my case the error was:
Because I use the better node typings from the typings registry until microsoft/types-publisher#4 is implemented, which conflict with the crappy ones from DT. |
In version 3.1.1, @felixfbecker Most |
Personally I will not use |
@mikesnare: Are you using sources for type declarations such as I already said it earlier, but I feel that
With these two factors, we're stuck with leaking and outdated declarations. I was hoping that the first one will be less of an issue if the ease of maintenance (so accuracy of the declarations) is improved but it turns out it won't be so easy. I have to admit that I was expecting Node's modules to be locally scoped so each lib gets the version of Here is the answer we got from the |
Did you call |
For users of |
@mikesnare You probably still have @felixfbecker You shouldn't see this issue any more with 3.1.1, if you still see the same errors you've probably still got @demurgos If we would have used typings for gulp-typescript, all consumers of the bundled type declarations should install the types for our dependencies manually (either using |
I just saw that |
All types packages are now marked as devDependencies. Can everyone verify that the Node types are not installed any more with version 3.1.2? Note that |
@ivogabe, In my case it was a mix of things:
Now I moved over to @types but I think it still needs a little polishing. |
Expected behavior:
TSC build still works.
Actual behavior:
TSC build doesn't work.
Since gulp-typescript now includes the @types from required libs, npm install now moves those libs into my node_modules/@types directory and they get picked up by the build. As a result, calls in my code to
setTimeout
/setInterval
andrequire
are failing to compile because of the @types/node typings that get copied up.Any pointers as to how to prevent this (besides using window.setTimeout, etc...) would be appreciated, but for now I've downgraded to 3.0.2.
The text was updated successfully, but these errors were encountered: