Elliot Murray
12/11/2023, 12:30 PMdebug
endpoint and a release
endpoint and have a service set up for each. Each schema is then downloaded to a separate source set location, and the queries are in the main
source set, so shared with both variants.
The idea here is the debug schema can be updated (e.g. a new field has been added) before the release schema, and I can update the queries to include this new field. Ideally then I'd like the debug version to still compile, but the release to fail due to the missing field, until that change is pushed to the release endpoint/the release schema is updated also.
The issue I'm seeing with this however, is when I build the debug version the generateReleaseApolloSources
task is also run, and that fails the build because the field doesn't exist yet in the release schema. Is there any way around this issue? I'm new to GraphQL so appreciate I may be aiming at the incorrect solution here! Thanks πmbonnin
12/11/2023, 12:33 PMwhen I build the debug version theWelp, that's unexpected π€ . Can you trytask is also rungenerateReleaseApolloSources
./gradlew assembleDebug -m
?Elliot Murray
12/11/2023, 12:37 PMmbonnin
12/11/2023, 12:38 PMmbonnin
12/11/2023, 12:40 PMmbonnin
12/11/2023, 12:40 PMmbonnin
12/11/2023, 12:40 PMElliot Murray
12/11/2023, 12:41 PMmbonnin
12/11/2023, 12:42 PMgenerateXyz()
task automatically, let me checkStylianos Gakis
12/11/2023, 12:43 PMgenerateSourcesDuringGradleSync.set(false)
help in this case?mbonnin
12/11/2023, 12:44 PMElliot Murray
12/11/2023, 12:45 PMmbonnin
12/11/2023, 12:45 PMgenerateSourcesDuringGradleSync
is removed in v4 though because the IDE plugin makes it automagically (and I don't think there's a proper solution there besides removing the IJ plugin altogether π€ )Elliot Murray
12/11/2023, 12:47 PMmbonnin
12/11/2023, 12:49 PMmbonnin
12/11/2023, 12:50 PMElliot Murray
12/11/2023, 12:57 PMgenerateSourcesDuringGradleSync
to false in v3?mbonnin
12/11/2023, 1:00 PMmbonnin
12/11/2023, 1:00 PMgenerateSources
by default IIRCmbonnin
12/11/2023, 1:01 PMElliot Murray
12/11/2023, 1:03 PMbod
12/11/2023, 2:31 PM