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

Renaming ts-files breaks typescript-editor-support #78

Open
RasPelikan opened this issue Aug 10, 2015 · 5 comments
Open

Renaming ts-files breaks typescript-editor-support #78

RasPelikan opened this issue Aug 10, 2015 · 5 comments

Comments

@RasPelikan
Copy link
Contributor

I created a file test.ts and added some lines of code. Everythings works fine: compiler, viewing errors, code completion.

Then I selected the file in the package-explore pressed F2 (for renaming) and renamed the file to juhu.ts.

After this action the log of "TS Bridge Console" says:
[Error: Could not find file: 'src/main/ts/juhu.ts'.]

Then I renamed the file back to 'test.ts' and every is fine again.

According to http://help.eclipse.org/mars/index.jsp?topic=%2Forg.eclipse.platform.doc.isv%2Fguide%2FresAdv_events.htm renaming is a move-event. For solving issue 75 I had to review the TypeScriptIndexManager and found the place where those events are processed (method "resourceChanged"): Only REMOVED and ADDED deltas are processed. A "move" is not available, only MOVE_FROM and MOVE_TO. I think both events are fired and should be treated as REMOVED and ADDED. Can you investigate this and provide a fix? At the moment I have not setup for debugging eclipse-plugins so I would appreciate I you attend to this.

@p-kudrin
Copy link
Contributor

Tank you for your feedbacks. It seems that there is a more global problem. I catch the same error after creating a new .ts-file. It seems this is due to the move to version 1.5 compiler. I'm going to research this problem.

@col-panic
Copy link

Just did a fresh install to try it out ... after creating the first file it started going

[Error: Could not find file: 'src/parkinglot.ts'.]
[Error: Could not find file: 'src/parkinglot.ts'.]
[Error: Could not find file: 'src/parkinglot.ts'.]
[Error: Could not find file: 'src/parkinglot.ts'.]

what to do?? I am a noob in typescript ... thanks

@RasPelikan
Copy link
Contributor Author

This is another facet of this bug. Renaming or creating. Just restart Eclipse. Afterwards it will pick up the new files correctly.

@neo85
Copy link

neo85 commented Dec 4, 2015

Annoying bug. Do i have to restart eclipse every time i need to create a new file?

@trendzetter
Copy link

still seems the case..

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants