Hilt: Native function causing build fail: codeAttr must not be null
See original GitHub issueSimilar to #1955 having a native function inside a class marked with @AndroidEntryPoint
causes the build to fail with the same error message mentioned in that issue.
Execution failed for task ':app:transformClassesWithAndroidEntryPointTransformForDebug'.
> codeAttr must not be null
Issue Analytics
- State:
- Created 3 years ago
- Comments:7 (2 by maintainers)
Top Results From Across the Web
Dagger-hilt error while compiling project - Stack Overflow
I recommend using the latest stable version of Dagger. Mine is working with these versions:
Read more >Hold on Before you Dagger or Hilt! try this Simple DI.
Learn Pure Native Kotlin DI, which can be migrated to HILT or Dagger ... with some hilt scoped annotation you can do no-brainer...
Read more >View model has no zero arg constructor when using ...
When creating a view model using the navigation scope i get an error stating that ViewModel has no zero argument constructor.
Read more >How to use Hilt with Room Database ( Complete guide - Part 2)
In the previous video, I mentioned the fundamentals of the Hilt. In this article, I will teach you how to use Hilt in...
Read more >HILT Constructor Injection Problems - YouTube
The best android courses in the world: https://codingwithmitch.com/Watch the HILT course here (FREE): ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I can confirm that the error no longer occurs for me with version
2.29-alpha
.This is already fixed by https://github.com/google/dagger/commit/2099bade9a2d9ba0fd9fc9b8a31006ed7b13cf41, the next released version of Hilt will contain this fix. As workaround for now, you can move your native method from the
@AndroidEntryPoint
-annotated class.