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

@AssistedInject doesn't work after gradle update #4490

Open
turkovsky opened this issue Oct 24, 2024 · 0 comments
Open

@AssistedInject doesn't work after gradle update #4490

turkovsky opened this issue Oct 24, 2024 · 0 comments

Comments

@turkovsky
Copy link

After some dependency updates (incl. version of gradle and kotlin) old code isn't compile anymore in release build

There is error

error: [Dagger/MissingBinding] b.a cannot be provided without an @Inject constructor or an @Provides-annotated method.

Code:

@HiltWorker
class PeriodicReminderWorker @AssistedInject constructor(
    @Assisted context: Context,
    @Assisted workerParameters: WorkerParameters,
    private val reminderProcessor: ReminderProcessor
) : CoroutineWorker(context, workerParameters) {
    override suspend fun doWork(): Result {
        reminderProcessor.invoke(forceUpdateReminders = true)
        return Result.success()
    }
}

In old branch everything works as before
Gradle has been updated from 8.3.2 to 8.7.1
Kotlin - from 2.0.10 to 2.0.21
gradle wrapper - from 8.6 to 8.9

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant