Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

VSNetBeans: Check for source level java compatibility #7555

Merged
merged 1 commit into from
Jul 10, 2024

Conversation

petrovic-d
Copy link
Collaborator

This feature checks if source level java (from the project) is compatible with one used by extension
It ignores check when RH extension is installed
It also works with multi-module projects

@MartinBalin MartinBalin changed the title GCN-4643: Check for source level java compatibility VSNetBeans: Check for source level java compatibility Jul 9, 2024
@@ -184,6 +185,7 @@ function findJDK(onChange: (path : string | null) => void): void {
}

let currentJdk = find();
validateJDKCompatibility(currentJdk);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

note -- there's a pending PR #7497 that introduces projectJDK. Depending on which one will merge first, the other PR should change to validate the projectJDK

@sdedic sdedic added Java [ci] enable extra Java tests (java.completion, java.source.base, java.hints, refactoring.java, form) VSCode Extension [ci] enable VSCode Extension tests labels Jul 9, 2024
@sdedic sdedic added this to the NB23 milestone Jul 9, 2024
@sdedic sdedic requested a review from dbalek July 9, 2024 09:30
@dbalek
Copy link
Contributor

dbalek commented Jul 9, 2024

Do not forget to squash all the commits into a single one before merge.

@junichi11
Copy link
Member

Please add the license header.

@petrovic-d petrovic-d requested a review from sdedic July 10, 2024 06:40
@petrovic-d petrovic-d force-pushed the GCN-4643-java-source-level-check branch from bbf760e to c63fbbc Compare July 10, 2024 13:15
@sdedic sdedic added the do not merge Don't merge this PR, it is not ready or just demonstration purposes. label Jul 10, 2024
Get java version from Maven projects

Util for checking if extension command is available

Move file

Get java version from installation path

Project abstraction with methos to retreive java version

Initial position of breakpoints view is next to navigator

Always open expression evaluator view

PHP: removed built-in type real
  - deleted the built-in type real
    (php does not have a built-in real type: https://www.php.net/manual/en/language.types.intro.php
    Also see the warning under "Scalar Types": https://www.php.net/manual/en/language.types.declarations.php)
  - fixed broken tests
  - new tests added
  - fixes generation of return type real instead of float for a method when overriding a base class method with an autocomplete
  - fixes generation of return type real instead of float for a function in phpDoc

Fix "Fix Imports" [apacheGH-7546]

- apache#7546
- Compare segments of namespace names to avoid adding incorrect items
- Add a unit test

Reduce redundant cast warnings. These happen as a side result of code cleanup..

Reduce warnings that look like this:

   [repeat] /home/bwalker/src/netbeans/enterprise/tomcat5/src/org/netbeans/modules/tomcat5/util/LogManager.java:271: warning: [cast] redundant cast to LogViewer
   [repeat]         contextLog = (LogViewer)contextLogViewers.get(moduleID);
   [repeat]                      ^Cleanup redundant casts. These are a side effect of work done doing code cleanup.

Fix unit tests

- Use `checkCompletionOnlyDocumentation` test method because there are functions that have the same prefix

Micronaut: Clear symbol cache on ClasspathInfo changes.

Remove downloader from NBI

 - the download manager relied on suspend/resume/stop from
   java.lang.Thread which were deprecated since Java 1.2
 - JDK 23 removes suspend/resume, others are already no-ops
 - fixing this would require a completely different approach,
   and since NBI is no longer maintained and in the process
   to be replaced by nbpackage this is th easiest option

Remove redundant code

Remove new lines

Await on NbLanguageClient

Removed unused code

Reduce number of resolve(undefined)

Explicitly set xml2js parser to be sync

Shorten array element check

Recursively search for subprojects

Reference github issue inside comment

Use vscode.Uri.file

Modify regex to support whitespaces between identifiers, literals and symbols

Use vscode.Uri.parse

Removed explicit check for the command as no longer needed

Add licence header

NBI: disable update check again

 - Hide check-for-updates step from the (windows) installer again
   since it is a no-op with the current NB release model
 - reverts apache#1348 without changing codepaths outside the checkbox
   logic to reduce risks of other side effects
 - can be re-enabled using a property

Docker - Load images

Docker images don't load because `VirtualSize` attribute was removed from Docker Engine in v1.44.

---

Using `getOrDefault` for the `Created`, `Size` and `VirtualSize` attributes.

Using `Size` as default value to `VirtualSize`.

Annotating the `VirtualSize` attribute as deprecated

CI: start testing on 23-ea

 - move from 22 to 23-ea (all except java hints which would require
   nb-javac 23)
 - merge APISupport job into another job

JDK 23 related test fixes

 - '-proc:full' is now required for annotation processing
 - java.lang.Thread finally lost a few methods

Improving multistep infrastructure, command for uploading cloud assets to config map
@petrovic-d petrovic-d force-pushed the GCN-4643-java-source-level-check branch from c63fbbc to 8b31dac Compare July 10, 2024 13:45
@mbien
Copy link
Member

mbien commented Jul 10, 2024

was about to say that something went wrong during squashing, but this looks better now :)

@sdedic sdedic removed the do not merge Don't merge this PR, it is not ready or just demonstration purposes. label Jul 10, 2024
@sdedic sdedic merged commit 2b85175 into apache:master Jul 10, 2024
37 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Java [ci] enable extra Java tests (java.completion, java.source.base, java.hints, refactoring.java, form) VSCode Extension [ci] enable VSCode Extension tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants