IBM / zopeneditor-about

IBM Z Open Editor: File issues here!
https://ibm.github.io/zopeneditor-about
Apache License 2.0
47 stars 25 forks source link

Hover function not working #322

Closed Felix-Braun closed 1 year ago

Felix-Braun commented 1 year ago

Development environment

Problem Description

The Problem is, that the Hover- and go to declaration Function doesn't always work. We thought that it could be related to the size of the program. If the Declaration hover function doesn't work, neither does the peek definition , go to definition, find all references and jump to sections. Opening Copys or Includes works, but not from a Variable, only from the copy/include it self. The preview doesn't work either.

sdaimwood commented 1 year ago

Hi Felix, in the documents where the functionality is lost are there any errors present? As documented in https://github.com/IBM/zopeneditor-about/issues/300, this is a known issue with the COBOL parser where errors will cause language features to be disabled as the document is considered invalid and a full parse cannot complete.

paulobigas commented 1 year ago

Hello. I confirm that I have the same problem. If a copybook declared in a program have a ERRO_TOKEN problem (already identified in other issues) the hover and peek stops working.

Felix-Braun commented 1 year ago

Hello, but why does it only say "ERROR_TOKEN" unexpected tokens ignored when I have the copy in front of a Variable declaration, but when i move it above another copy it says: Copybook 'COPYBOOK A' contains the following error: "." expected after this token but when I open the copybook, there are no errors or problems showing

phaumer commented 1 year ago

@Felix-Braun @paulobigas thanks for reporting these. After discussion we believe that these will also be fixed with the fix for #300. So closing it as a dup for now. I will ping you when a fix is available in a comment for #300.

phaumer commented 1 year ago

@Felix-Braun @paulobigas please trying the new v3.1.0 and let us know if this fixes your issue.

Felix-Braun commented 1 year ago

Hello, I can't test it, because it can't find any of the copybooks, not those stored locally and not those in the changeman libaries. Do I have do modify the zapp.yaml file?

Felix-Braun commented 1 year ago

@phaumer I tried to modify the zapp.yaml file to version 3.1.0 but still doesn't find any of the copybooks. in zapp.yaml version: 3.1.0

paulobigas commented 1 year ago

@phaumer In my case I confirmed that it is working properly! The Error_Token error disappeared in all of my copybooks, and the hoovering is working as expected. Many thanks for you work.

Felix-Braun commented 1 year ago

Other people updated the extension and for them, it works fine and everythings works. but in my case it's unable to locate any of the copybook. I checked the property groups and all seems fine, I have no idea why it wouldn work

paulobigas commented 1 year ago

@Felix-Braun please check #320 . The zapp.yaml file must be in the root of the workspace directory. That was my problem.

Felix-Braun commented 1 year ago

@paulobigas I have the zapp.yaml file in the root directory of the workspace and it is searching for the copybooks in the propertygroups, but it doesn't find them. I've looked in the ".._D_\zosmf(propertygroup-location)" and the copybook is in there but i doesn't take it and says "member not found" in the Output console of IBM Z Open Editor (loggerlevel=debug) and in the program, the error message is "Unable to find copybook COPYBOOK"

Felix-Braun commented 1 year ago

With the previos version works for me (v3.0.1) but with the new version (v3.1.0) it doesn't. It found the copybook in one of the libaries, but it doesn't use them. in the log it says, 'Data set member "USER.COB.COPY(COPYBOOK)" was found and conten is being downloaded to "D\zosmf\library"' but then it searches another library and then there comes the error:

>>> z/OSMF REST API Error:
Rest API failure with HTTP(S) status 404
category: 6
rc:       8
reason:   524
message:  Member not found
details: 
  - USET.TSO.CPY(COPYBOOK)

in a totally different library

Felix-Braun commented 1 year ago

found the proble, in the user settings.json file, I had "zopeneditor.enforceCaseSensitiveIncludeFileNames": true, this was the error,

phaumer commented 1 year ago

Glad to hear that it worked for you. We are trying to convey as much troubleshooting info as we can in the logs. Let us know how we can improve.