redhat-developer / redhat-developer/vscode-java
Android project doesn't include generated files from aidl
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 2.3k
- Forks
- 546
- Avg merge
- 20h 1m
- Merged PRs (30d)
- 11
Description
When an Android project has aidl source files, the generated code is not included in source paths.
Environment
- Operating System: Windows 11
- JDK version: openjdk 11.0.12 2021-07-20
- Visual Studio Code version: 1.75.0-insider
- Java extension version: v1.14.2022122003
Steps To Reproduce
- Clone https://github.com/Genymobile/scrcpy
- Run
./gradlew assembleDebug, it builds successfully - Open
server/src/main/java/com/genymobile/scrcpy/wrappers/ClipboardManager.java
Current Result
The import android.content.IOnPrimaryClipChangedListener cannot be resolved Java(268435846)
Expected Result
No error
Additional Informations
The interface android.content.IOnPrimaryClipChangedListener is generated from server/src/main/aidl/android/content/IOnPrimaryClipChangedListener.aidl to server/build/generated/aidl_source_output_dir/debug/out/android/content/IOnPrimaryClipChangedListener.java
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with server/src/main/aidl/android/content/IOnPrimaryClipChangedListener.aidl and the generated server/build/generated/aidl_source_output_dir/debug/out/android/content/IOnPrimaryClipChangedListener.java path, then inspect how generated source paths are discovered when opening ClipboardManager.java. Reproduce with ./gradlew assembleDebug and verify that the unresolved-import error is gone.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, java
- Domain
- developer-experience, mobile-dev
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 52/100