Peter Steiwer · Apr 9, 2021

VSCode "Go To Definition" opens in Read Only mode

As the title says, when I use the "Go To Definition (F12)" option, it opens the definition in read only mode. Is there some way to either directly make the go to option editable or can i turn the read only version into an editable version? I end up needing to open the file directly and then manually going to the method definition myself.

1 0 4 82
Log in or sign up to continue


The issue is probably in export settings, which used to find a real file for resources on server. You can check it by opening ObjectScript Explorer, when you dive to your classes/routines, it should show an icon next to the name, the same as in File Explorer. So, it's mean that it's linked correctly. If not. you have to look at "objectscript.export" settings, you may find some useful info about this here.

Another possible issue is that it comes from the Language Server, you may temporarily disable that extension if it's installed and active to see if it's changed (reload is required). And if the issue disappears I would suggest installing the latest beta version of Language Server. And fill the issue in the repo, if it's still happens.

I looked into these suggestions, but I still can't make it work. I see that when I am editing a file and I hover over the name on the tab at the top, it says "C:\Users\....\PivotSubscriptions\Subscription.cls". After using "Go To Definition", the new class opens with the path of "/PivotSubscriptions/EventLog.cls"

Sounds like you are using the client-side editing paradigm. As Dmitry says, unless you haven't installed Language Server it will be LS that initially handles your "Go to Definition" request. But I think LS then calls an API entrypoint named serverDocumentUriForUri in the main ObjectScript extension (OS) to find out where the target document should be fetched from. As the API name indicates, this returns a uri (a document reference) that always fetches code from the server. And since you are using the client-side editing paradigm the fetched code cannot be edited.

Please open an issue on the repo at where it can be tracked and managed better than in this DC post.