Migration from 2.7 to 2.8 - Subcomponent scopes
See original GitHub issueI have a issue with subcomponent’s scopes when I try to upgrade from 2.7 to 2.8.0. Here’s my architecture:
Global App component
@PerApp
@Component(modules = {AppModule.class, DataModule.class, NetworkModule.class})
public interface AppComponent {
ActivityComponent with(ActivityModule activityModule);
}
Default Activity subcomponent
@PerActivity
@Subcomponent(modules = {ActivityModule.class})
public interface ActivityComponent {
PinComponent with(PinModule pinModule);
void inject(LoginActivity loginActivity);
void inject(MainActivity mainActivity);
//...
}
Subcomponent for a specific activity
@PerActivity
@Subcomponent(modules = {PinModule.class})
public interface PinComponent {
void inject(PinActivity pinActivity);
}
@Module
public class PinModule {
//...
@PerActivity
@Provides
PinItem provideMethods();
//...
}
This structure works perfectly on 2.7, but on 2.8 it returns compilation error:
Error:(12, 8) error: [package.PinComponent] package.PinComponent has conflicting scopes:
package.ActivityComponent also has @package.PerActivity
If I’m understanding this correctly, I would have to provide a separate scope annotation for PinComponent
?
Issue Analytics
- State:
- Created 7 years ago
- Reactions:1
- Comments:5
Top Results From Across the Web
Dagger Component has conflicting scopes - Stack Overflow
The solution to both errors is to give the subcomponent a different scope than the parent, or don't use a subcomponent at all...
Read more >Play 2.7 Migration Guide - Documentation
This is a guide for migrating from Play 2.6 to Play 2.7. If you need to migrate from an earlier version of Play...
Read more >Supported Versions and Interoperability for Confluent Platform
All services included in Confluent Platform are supported, including Apache Kafka® and its subcomponents: Kafka brokers, Apache ZooKeeper™, Java and Scala ...
Read more >HL7 Version 2.8.2 Chapter 2
The scope of HL7 is restricted to the specification of messages between application/ systems and the events triggering them.
Read more >Migrating 3scale Red Hat 3scale API Management 2.8
Red Hat Ecosystem Catalog · Migrating 3scale · Preface · 1. 3scale template-based upgrade guide: from 2.7 to 2.8 Expand section "1. ·...
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
Please discuss this on another forum, like stackoverflow, which is better suited for questions.
@Kiran89kumar I did, you have to create a seperate annotation for that component.