Skip to main content



      Home
Home » Modeling » TMF (Xtext) » IFeatureScopeTracker.Provider lsp 2.12
IFeatureScopeTracker.Provider lsp 2.12 [message #1764203] Fri, 26 May 2017 11:47 Go to next message
Eclipse UserFriend
Hi all,

I updated my project to 2.12 and now it throws below exception when doing content assist:

Caused by: java.lang.UnsupportedOperationException: The resource 'file:///home/capacman/programlama/xtext-workspace/henkan.dsl.parent/vscode-hdsl-ext/exampleproject/example.hl' has been loaded without tracking the feature scope. Please check the implementation of IFeatureScopeTracker.Provider.
at org.eclipse.xtext.xbase.typesystem.internal.IFeatureScopeTracker$1.getExpressionScope(IFeatureScopeTracker.java:63)
at org.eclipse.xtext.xbase.typesystem.internal.ResolvedTypes.getExpressionScope(ResolvedTypes.java:1507)
at org.eclipse.xtext.xbase.typesystem.internal.CompoundReentrantTypeResolver.getExpressionScope(CompoundReentrantTypeResolver.java:180)
at org.eclipse.xtext.xbase.typesystem.internal.ForwardingResolvedTypes.getExpressionScope(ForwardingResolvedTypes.java:134)
at org.eclipse.xtext.xbase.ide.contentassist.XbaseIdeContentProposalProvider.createReceiverProposals(XbaseIdeContentProposalProvider.java:606)
at org.eclipse.xtext.xbase.ide.contentassist.XbaseIdeContentProposalProvider.completeBinaryOperation(XbaseIdeContentProposalProvider.java:535)
at org.eclipse.xtext.xbase.ide.contentassist.XbaseIdeContentProposalProvider._createProposals(XbaseIdeContentProposalProvider.java:377)
at org.eclipse.xtext.xbase.ide.contentassist.XbaseIdeContentProposalProvider.createProposals(XbaseIdeContentProposalProvider.java:641)
at org.eclipse.xtext.ide.editor.contentassist.IdeContentProposalProvider.createProposals(IdeContentProposalProvider.java:94)
at org.eclipse.xtext.ide.server.contentassist.ContentAssistService.createProposals(ContentAssistService.java:108)
at org.eclipse.xtext.ide.server.contentassist.ContentAssistService.createCompletionList(ContentAssistService.java:73)
at org.eclipse.xtext.ide.server.LanguageServerImpl.lambda$completion$14(LanguageServerImpl.java:425)
at org.eclipse.xtext.ide.server.WorkspaceManager.doRead(WorkspaceManager.java:234)
at org.eclipse.xtext.ide.server.LanguageServerImpl.completion(LanguageServerImpl.java:427)
at org.eclipse.xtext.ide.server.LanguageServerImpl.lambda$completion$13(LanguageServerImpl.java:406)
at org.eclipse.xtext.ide.server.concurrent.RequestManager.lambda$runRead$2(RequestManager.java:116)
at java.util.concurrent.CompletableFuture.uniApply(CompletableFuture.java:602)
... 5 more

any idea how to fix it?
Re: IFeatureScopeTracker.Provider lsp 2.12 [message #1764207 is a reply to message #1764203] Fri, 26 May 2017 12:25 Go to previous messageGo to next message
Eclipse UserFriend
Does your ide module inherit from defaultxbaseIdeModule?
Re: IFeatureScopeTracker.Provider lsp 2.12 [message #1764335 is a reply to message #1764207] Sun, 28 May 2017 08:32 Go to previous messageGo to next message
Eclipse UserFriend
Hello Christian,

Yes i did. HDslIdeModule -> AbstractHDslIdeModule -> DefaultXbaseIdeModule is like this.
Re: IFeatureScopeTracker.Provider lsp 2.12 [message #1764337 is a reply to message #1764335] Sun, 28 May 2017 09:01 Go to previous messageGo to next message
Eclipse UserFriend
Hi,

can you share a reproducible example? or some more hints
org.eclipse.xtext.xbase.typesystem.internal.OptimizingFeatureScopeTrackerProvider.track(EObject)
on which path is the NULL instance returned?

i assume the content assist will be called with isPrimaryResource = true
and thus "new FeatureScopeTracker" should be returned
Re: IFeatureScopeTracker.Provider lsp 2.12 [message #1764338 is a reply to message #1764337] Sun, 28 May 2017 09:18 Go to previous messageGo to next message
Eclipse UserFriend
(thus the content of the load options would be interesting)
Re: IFeatureScopeTracker.Provider lsp 2.12 [message #1764339 is a reply to message #1764338] Sun, 28 May 2017 10:24 Go to previous messageGo to next message
Eclipse UserFriend
Hi Christian,

isLiveScope and isPrimaryResource returns false so in this path it returns NULL instance. Also i checked that resource is the last element in resourceSet not the first one. Is it a bug?
if (!isLiveScope(loadOptions) && !isPrimaryResource(resourceSet, resource)) {
					return IFeatureScopeTracker.NULL;
				}
Re: IFeatureScopeTracker.Provider lsp 2.12 [message #1764340 is a reply to message #1764339] Sun, 28 May 2017 10:29 Go to previous messageGo to next message
Eclipse UserFriend
Can you please file a bug at xtext-extras with everything needed to reproduce
Re: IFeatureScopeTracker.Provider lsp 2.12 [message #1764342 is a reply to message #1764340] Sun, 28 May 2017 11:03 Go to previous messageGo to next message
Eclipse UserFriend
Christian,
Here it is https://github.com/eclipse/xtext-extras/issues/144. I uploaded my project tarball as well
Re: IFeatureScopeTracker.Provider lsp 2.12 [message #1764355 is a reply to message #1764342] Mon, 29 May 2017 03:00 Go to previous message
Eclipse UserFriend
Seems to be a bug with Xbase content assist, assuming to be executed on the first resource only (which is not the case when running Xtext as a language server).
Previous Topic:How to export Xtext project referencing to UML for support the Xtext Editor
Next Topic:Xtext newbie - ID with array declaration
Goto Forum:
  


Current Time: Mon May 12 15:44:21 EDT 2025

Powered by FUDForum. Page generated in 0.03743 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top