Skip to content

Ignore unrelated property files #320

Closed

Description

@neekibo

The STS language-server is validating my message.properties (translation files) and it gives me useless/countless "unknown property" warnings. I also get errors like mentioned in #314

Was working correct with Spring Tool Suite 4 Version: 4.2.2
Wrong behavior occours since upgrade to Spring Tool Suite 4 Version: 4.3.0.RELEASE, Build Id: 201906200901

Is this intentional?
How does the language server knows which properties-file is a spring-configuration?
Can I configure this behavior and ignore my message.properties?

Thanks

Activity

  1. changed the title [-]Ignore message.properties[/-] [+]Ignore unrelated property files[/+] on Jul 11, 2019
  2. kdvolder commented on Jul 11, 2019

    @kdvolder
    Member

    I'll have to debug this to determine why this happens. I think it used to be a problem in the past and was caused by how lsp4e determines which files to validate, which is related to content-types assigned by Eclipse. Don't recall details, but I beleave it got fixed. Seems like it broke again :-(

  3. kdvolder commented on Jul 11, 2019

    @kdvolder
    Member

    And to be clear:

    Is this intentional?

    No, of course not. So thanks for reporting the poblem :-)

  4. kdvolder commented on Jul 11, 2019

    @kdvolder
    Member

    Can I configure this behavior and ignore my message.properties?

    You can try making some changes to Eclipse workspace 'content-type' configuration. Which you can access at "Preferences >> General >> Content Types". I have my doubds that you will be able to 'fix' this though by meddling with them. I suspect the content type is determined correctly, but some 'bug' in either our language server or the Eclipse lps4e infrastructure is handling this incorrectly and validating the file even though it is not classified as a 'Spring Properties File'.

  5. kdvolder commented on Jul 15, 2019

    @kdvolder
    Member

    Was able to easily reproduce the issue. I used STS 4.3.1.

    Steps:

    • created a boot project (don't think the starters matter but I used 'web' and 'actuator')
    • opened application.properties and edited a bit.
    • created a new file called 'whatever.properties'.
    • added some text like this bork=bark.

    => A warning appears that 'bork' is an unknown property. Which seems to be coming from our spring boot language server.

  6. kdvolder commented on Jul 16, 2019

    @kdvolder
    Member

    I think the underlying issue is really a bug in lsp4e, so I have reported it here:
    https://bugs.eclipse.org/bugs/show_bug.cgi?id=549321

    Fortunately we are able to work around/avoid hitting the bug by making sure we allways use base-type="org.eclipse.core.runtime.text" even when it might seem more logical to use a more specific base-type.

  7. added this to the 4.3.2.RELEASE milestone on Jul 29, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions