apache / apache/netbeans

NetBeans renames classes only in declaring files, but not in client files

Open
#7,358 4 comments 0 reactions 0 assignees View on GitHub
Java kind:bug needs:triage
Dominant language
Java
Stars
3.1k
Forks
935
Avg merge
2d 3h
Merged PRs (30d)
17

Description

### Apache NetBeans version

Apache NetBeans 22 release candidate

### What happened

NetBeans sometimes renames classes/enum/iterfaces etc only in files, that declare them, but not in files, that use them. I see this problem for projects that use JPMS (have explicit module-info). This bug is linked to https://github.com/apache/netbeans/issues/3725 and was previously describe there.

```
Product Version: Apache NetBeans IDE 22-rc1
Java: 21.0.2; OpenJDK 64-Bit Server VM 21.0.2+13-58
Runtime: OpenJDK Runtime Environment 21.0.2+13-58
System: Linux version 5.15.0-88-generic running on amd64; UTF-8; en_US (nb)
```

### Language / Project Type / NetBeans Component

Java Maven Project using Java Modules (JPMS)

### How to reproduce

I don't have a solution to reproduce this bug. Earlier I used the steps described in https://github.com/apache/netbeans/issues/3725#issuecomment-1997195547 however they don't work any more.

### Did this work correctly in an earlier version?

No / Don't know

### Operating System

Ubuntu 20.04.3 LTS

### JDK

Java: 21.0.2; OpenJDK 64-Bit Server VM 21.0.2+13-58

### Apache NetBeans packaging

Apache NetBeans binary zip

### Anything else

_No response_

### Are you willing to submit a pull request?

No

Contributor guide

Open the contributing guide

Research direction

Start with linked issue #3725 and its reproduction comment, then investigate the Java Maven JPMS rename behavior described here. Done means reproducing the failure and confirming that class, enum, and interface renames update their client files.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
devtools
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.