Skip to content
This repository has been archived by the owner on Sep 3, 2021. It is now read-only.

Converter functions do not work #1

Open
lord3lm0 opened this issue May 4, 2016 · 17 comments
Open

Converter functions do not work #1

lord3lm0 opened this issue May 4, 2016 · 17 comments
Assignees
Labels

Comments

@lord3lm0
Copy link

lord3lm0 commented May 4, 2016

Using version 1.0 of VS Code none of the converter functions work;

No handler found for the command: 'extension.convertToTml'. An extension might be missing an activation event.
No handler found for the command: 'extension.convertToJsonTml'. An extension might be missing an activation event.
No handler found for the command: 'extension.convertToYamlTml'. An extension might be missing an activation event.

@Togusa09
Copy link
Owner

Togusa09 commented May 5, 2016

This issue is fixed in the v0.0.6 release I just made.

I had the node_modules folder being excluded from the extension package, so an error was being thrown before the commands were registered.

Thank you for reporting this issue. Can you please confirm if it is resolved?

@lord3lm0
Copy link
Author

lord3lm0 commented May 5, 2016

Thanks for your quick reply and for implementing this missing feature in VS Code, I have no access to TextMate and refuse to edit XML files by hand.

Using the following file as input:
https://github.com/Togusa09/vscode-tmlanguage/blob/master/syntaxes/json-tmlanguage.JSON-tmLanguage

When I use "convert to tmLanguage File" It now opens a new empty file. So it improved a little. (currently under VS Code on ubuntu).

@Togusa09
Copy link
Owner

Togusa09 commented May 5, 2016

Could you try copying the file to another folder and performing the conversion? There could be an existing file that is preventing the converter creating and populating a new file correctly.

I'll improve the file name handling for conflicts and do some testing in ubuntu.

@Togusa09
Copy link
Owner

New release, I think I've resolved your issue now.

@lord3lm0
Copy link
Author

Thanks, I'm currently on vacation so I can not check it right now, but will
let you know later.
Best regards,
Almar
Op 10 mei 2016 11:09 schreef "Togusa09" [email protected]:

New release, I think I've resolved your issue now.


You are receiving this because you authored the thread.
Reply to this email directly or view it on GitHub
#1 (comment)

@heartsekai
Copy link

Hi, I have the version 0.0.7 installed and still throwing the error.

@Togusa09
Copy link
Owner

Togusa09 commented Jun 7, 2016

@heartsekai What OS and VSCode version are you using? I tested a clean install of VSCode 1.2 on Windows 10 with the file: https://github.com/SublimeText/PackageDev/blob/master/Syntax%20Definitions/Sublime%20Text%20Syntax%20Def%20%28JSON%29.JSON-tmLanguage and was able to convert it.

Can you open Help->Toggle Developer Tools, then select the Console tab and post the error stack trace it displays?

@monoteba
Copy link

monoteba commented Jun 7, 2016

Hi, I'm also experiencing this issue. It worked the first time, then I deleted the file and tried again. Since then I've been getting the error.

nativeExtensionService.ts:98
Activating extension `Togusa09.tmlanguage` failed: Cannot find module '/Users/Morten/.vscode/extensions/vscode-tmlanguage-master/out/src/extension'.t.$localShowMessage @nativeExtensionService.ts:98

messageService.ts:119
No handler found for the command: 'extension.convertToJsonTml'. An extension might be missing an activation event.

btw, I'm using VSCode 1.2.0 and Mac OS 10.11.5

@heartsekai
Copy link

Exactly the same error.

@Togusa09
Copy link
Owner

Togusa09 commented Jun 9, 2016

Did you install the plugin by downloading the source code and copying it into vscode extensions folder?
I noticed that your error mentions vscode-tmlanguage-master, where the installed versions are in vscode.tmlanguage-0.0.7.

@monoteba
Copy link

monoteba commented Jun 9, 2016

Yes I downloaded the source and copied it in. I couldn't find it in the built-in "Install extension" in VSCode.

@monoteba
Copy link

monoteba commented Jun 9, 2016

Ok so I found it now, now when I'm trying to convert YAML to tmLanguage, it just gives me a blank file, with the following console output

[Extension Host] WARNING: Promise with no error callback:65 threadService.ts:207 [Extension Host] Object {exception: Object, error: null, promise: Object, id: 65} threadService.ts:207 [Extension Host] undefined shell.ts:400 You cannot define a sequence item when in a mappinge.onUnexpectedError @ shell.ts:400(anonymous function) @ shell.ts:302e.onUnexpectedError @ errors.ts:73u @ errors.ts:88e.onUnexpectedExtHostError @ extHost.api.impl.ts:487e.handle @ abstractThreadService.ts:100s @ ipcRemoteCom.ts:269f @ ipcRemoteCom.ts:226_combinedTickCallback @ internal/process/next_tick.js:67_tickCallback @ internal/process/next_tick.js:98

@Togusa09
Copy link
Owner

Togusa09 commented Jun 9, 2016

The YAML parser may be unable to process the file, if this is the case, then you will see an error in the console under Developer Tools.

I'll have to improve feedback to he user in the next release.

@monoteba
Copy link

monoteba commented Jun 9, 2016

Alright, I'll keep an eye out! It's great you're doing this. I'm currently using Sublime alongside VSCode to develop a custom language, and enjoy the process with PackageDev, so having that directly in VSCode would be super :)

Thanks

@Togusa09 Togusa09 added the bug label Jun 11, 2016
@Togusa09 Togusa09 self-assigned this Jun 11, 2016
@Togusa09
Copy link
Owner

Are any users still getting the "No handler found for the command" error? I have created separate issue for the for the silent conversion failures (Issue #3)

@monoteba
Copy link

I'm not receiving any errors. Tried converting a YAML to tmLanguage, appears to work.

@gwicksted
Copy link

I only received this error when trying to convert from a tmLanguage format file that had a file extension of .tmLanguage.txt (VSCode Version 1.9.1)

The option to convert shows up in the CTRL+SHIFT+P menu but activating it fails saying no handler found for the command.

Thought it was this exact issue until I realized that VSCode (well partly the Windows common dialog) behaves like Notepad and saves with .txt by default until you select All Files even if you type a file name that appears to have an extension.

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

No branches or pull requests

5 participants