Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

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

Message “package … does not exist” despite of a corresponding Java source file #4563

Closed
Markus-Elfring opened this issue Aug 29, 2022 · 7 comments
Labels
kind:bug Bug report or fix needs:triage Requires attention from one of the committers

Comments

@Markus-Elfring
Copy link

Apache NetBeans version

Apache NetBeans 14

What happened

The script “Apache-NetBeans-14-bin-linux-x64.sh” was successfully executed also on my development system.
I opened a test project a moment later.

I wondered then about the error message “package … does not exist”.

questionable_message-NetBeans-excerpt-20220829

How to reproduce

Please take another look at import specifications (also in known Java example source files).

Did this work correctly in an earlier version?

No / Don't know

Operating System

Linux 5.19.2-1.2 x86_64 - openSUSE Tumbleweed

JDK

OpenJDK 18.0.2.0 x86_64 - openSUSE Tumbleweed

Apache NetBeans packaging

Apache NetBeans provided installer

Anything else

The software “Eclipse IDE for Java Developers 2022-06 (4.24.0)” found the mentioned import statement usable.


Another example for a previous clarification attempt:
2016-08-11: "Package does not exist" but it does

Are you willing to submit a pull request?

No

Code of Conduct

Yes

@Markus-Elfring Markus-Elfring added kind:bug Bug report or fix needs:triage Requires attention from one of the committers labels Aug 29, 2022
@neilcsmith-net
Copy link
Member

That's not a valid project. The packages should be under src/main/java.

@Chris2011
Copy link
Contributor

Chris2011 commented Aug 29, 2022

That's not a valid project. The packages should be under src/main/java.

Does this really matters and does this really make a difference?

@Markus-Elfring
Copy link
Author

The packages should be under src/main/java.

💭 I suggest to reconsider such information a bit more also according to a required statement like “package picocli;” (for my test example).
Do development environments present differences in the desired storage locations?

@neilcsmith-net
Copy link
Member

Does this really matters and does this really make a difference?

Yes. @Chris2011 if it's not a valid project how do you expect NetBeans to work out where the root of Java packages is?

Do development environments present differences in the desired storage locations?

Well, build systems do, and unless the build system (eg. Maven) is configured correctly, then it's neither going to build or allow NetBeans to find the required information. I hadn't noticed initially, but it looks like the pom.xml file is incorrectly under src too. This might accidentally work in Eclipse because of the .classpath file, but it's not going to work elsewhere.

For help with Maven inside (or outside) NetBeans, I suggest you ask on the users@ mailing list or in the GitHub discussions.

@Markus-Elfring
Copy link
Author

I hadn't noticed initially, but it looks like the pom.xml file is incorrectly under src too.

The file “pom.xml” is stored in the root directory for my test project example.
💭 Do you expect a clearer graphical representation by the NetBeans IDE accordingly?

@Markus-Elfring
Copy link
Author

… where the root of Java packages is?

Does the shown screenshot excerpt indicate relevant information? 🤔

@neilcsmith-net
Copy link
Member

Moving this into discussions as suggested.

@apache apache locked and limited conversation to collaborators Aug 30, 2022
@neilcsmith-net neilcsmith-net converted this issue into discussion #4566 Aug 30, 2022

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Labels
kind:bug Bug report or fix needs:triage Requires attention from one of the committers
Projects
None yet
Development

No branches or pull requests

3 participants