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

typescript 2 on-demand compilation #10639

Closed
kataik opened this issue Aug 31, 2016 · 4 comments
Closed

typescript 2 on-demand compilation #10639

kataik opened this issue Aug 31, 2016 · 4 comments
Labels
External Relates to another program, environment, or user action which we cannot control.

Comments

@kataik
Copy link

kataik commented Aug 31, 2016

TypeScript Version: 2.0 beta

Environment and stack: Windows 10, Visual Studio 2015 update 3, .NET Framework 4.6.1, Web Core RC2, Node.js 4.5.0, Gulp

Task Runner Explorer used to properly identify and execute tasks written in typescript using the typescript-node (0.1.3), typescript-register (1.1.0) and typescript-require (0.2.9-1) node packages. This no longer works after upgraded to typescript 2.0 beta. Task Runner explorer fails to properly update its task list (although still recognizes the gulpfile.ts as source).

When I try to execute one of the tasks, I get the following exception during runtime:

[15:03:15] Requiring external module typescript-require
node.js:708
throw new Error('Implement me. Unknown stdin file type!');
^
Error: Implement me. Unknown stdin file type!
at process.stdin (node.js:708:17)
at merge (C:\Work\Dev\T_CoreWebRc2\src\T_CoreWebRc2\node_modules\typescript-require\index.js:112:17)
at compileTS (C:\Work\Dev\T_CoreWebRc2\src\T_CoreWebRc2\node_modules\typescript-require\index.js:64:20)
at Object.require.extensions..ts (C:\Work\Dev\T_CoreWebRc2\src\T_CoreWebRc2\node_modules\typescript-require\index.js:21:16)
at Module.load (module.js:343:32)
at Function.Module._load (module.js:300:12)
at Module.require (module.js:353:17)
at require (internal/module.js:12:17)
at Liftoff.handleArguments (C:\Work\Dev\T_CoreWebRc2\src\T_CoreWebRc2\node_modules\gulp\bin\gulp.js:116:3)
at Liftoff. (C:\Work\Dev\T_CoreWebRc2\src\T_CoreWebRc2\node_modules\liftoff\index.js:198:16)
Process terminated with code 1.

@RyanCavanaugh RyanCavanaugh added the External Relates to another program, environment, or user action which we cannot control. label Aug 31, 2016
@RyanCavanaugh
Copy link
Member

TypeScript isn't anywhere in that stack trace; we do not own typescript-node, typescript-register, or typescript-require. Please log a bug with the appropriate external component.

@mhegazy
Copy link
Contributor

mhegazy commented Aug 31, 2016

@blakeembrey any thoughts?

@blakeembrey
Copy link
Contributor

blakeembrey commented Aug 31, 2016

@kataik I would recommend using ts-node. Both typescript-register and typescript-require haven't been updated for a long time (see theblacksmith/typescript-require#36 and https://github.com/pspeter3/typescript-register#typescript-register---). On top of that, if you installed typescript-node you should also see it is deprecated (both on the README and an NPM warning) and is called ts-node.

@kataik
Copy link
Author

kataik commented Sep 1, 2016

Thanks a lot, it works fine now. The problem was that typescript-register and typescript-require were still there and gulp tried to use them. Removed, now works properly. Sorry for the invalid issue.

@microsoft microsoft locked and limited conversation to collaborators Jun 19, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
External Relates to another program, environment, or user action which we cannot control.
Projects
None yet
Development

No branches or pull requests

4 participants