Description
Description:
Incorrect examples in the default configuration of the LSP server cause errors that are difficult to detect. Removing them for a person with little experience in Apache NetBeans can cause a lot of frustration.
Steps to reproduce the behavior:
- Make a fresh installation of netbeansPython;
- Set the right margin to 120 characters, Options/Editor/Formatting/RightMargin [120];
- Make a fresh project e.g. PythonProject1;
- Edit main.py;
- Add "Lorem ipsum dolor … est laborum." in line 7, print function;
- Check the line length configurations in the LSP server:
Unfortunately, we have two different forms and three different values. The inscriptions representing the number prevail.
- I set the desired length by selecting the majority form:
- The effect in the editor seems to be correct, the warnings disappear:
- Just to be sure, I check if a warning appears if I exceed the new length, which is 120 characters:
And here is the problem, the setting is not correct. We are looking for an error message.
- Unfortunately, the error window of the LSP server environment is empty:
- Fortunately, a log and the cause of the error can be found in the configuration directory of the LSP server:
- We correct the string "120" to the number 120:
- And eventually we achieve the desired effect:
Expected behavior:
Numeric values in the default LSP configuration should be stored as numbers. Ideally, a validation of this configuration should be done before closing the dialog and informing the user of any errors. The LSP server logs should be visible in the corresponding IDE output window.
Desktop:
- OS: Linux Fedora 37 ppc64le 6.5.12-100
- JDK Version: OpenJDK 17.0.8+7
- Netbeans Version: 19
- Python Plugin Version: 1.5