Skip to content

Commit 6bb2c37

Browse files
authored
Merge branch 'master' into mila/multiple-inequality-support
2 parents 6ed594a + 56d5bb6 commit 6bb2c37

File tree

16 files changed

+53
-28
lines changed

16 files changed

+53
-28
lines changed

buildSrc/src/main/java/com/google/firebase/gradle/plugins/PublishingPlugin.kt

Lines changed: 24 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414

1515
package com.google.firebase.gradle.plugins
1616

17-
import com.google.common.collect.Sets
1817
import com.google.firebase.gradle.bomgenerator.BomGeneratorTask
1918
import com.google.firebase.gradle.plugins.PublishingPlugin.Companion.BUILD_BOM_ZIP_TASK
2019
import com.google.firebase.gradle.plugins.PublishingPlugin.Companion.BUILD_KOTLINDOC_ZIP_TASK
@@ -81,6 +80,8 @@ abstract class PublishingPlugin : Plugin<Project> {
8180
registerCheckHeadDependenciesTask(project, releasingFirebaseLibraries)
8281
val validateProjectsToPublish =
8382
registerValidateProjectsToPublishTask(project, releasingFirebaseLibraries)
83+
val validateLibraryGroupsToPublish =
84+
registerValidateLibraryGroupsToPublishTask(project, releasingFirebaseLibraries)
8485
val publishReleasingLibrariesToBuildDir =
8586
registerPublishReleasingLibrariesToBuildDirTask(project, releasingProjects)
8687
val generateKotlindocsForRelease =
@@ -128,6 +129,7 @@ abstract class PublishingPlugin : Plugin<Project> {
128129
project.tasks.register(FIREBASE_PUBLISH_TASK) {
129130
dependsOn(
130131
validateProjectsToPublish,
132+
validateLibraryGroupsToPublish,
131133
checkHeadDependencies,
132134
// validatePomForRelease, TODO(b/279466888) - Make GmavenHelper testable
133135
buildMavenZip,
@@ -287,13 +289,28 @@ abstract class PublishingPlugin : Plugin<Project> {
287289
"or have a valid $RELEASE_CONFIG_FILE file at the root directory."
288290
)
289291
}
290-
val libraryGroupProjects =
291-
releasinglibraries.flatMap { it.projectsToRelease }.filterNotNull().toSet()
292-
val releasingProjects = releasinglibraries.mapNotNull { it.project }.toSet()
293-
if (!libraryGroupProjects.equals(releasingProjects)) {
292+
}
293+
}
294+
295+
/**
296+
* Registers the [VALIDATE_LIBRARY_GROUPS_TO_PUBLISH_TASK] task.
297+
*
298+
* Validates that all library groups of all publishing projects are included in the release config
299+
*
300+
* @throws GradleException if a library is releasing without it's library group.
301+
*/
302+
private fun registerValidateLibraryGroupsToPublishTask(
303+
project: Project,
304+
releasinglibraries: List<FirebaseLibraryExtension>
305+
) =
306+
project.tasks.register(VALIDATE_LIBRARY_GROUPS_TO_PUBLISH_TASK) {
307+
doLast {
308+
val libraryGroupProjects = releasinglibraries.flatMap { it.librariesToRelease }
309+
val missingProjects = libraryGroupProjects - releasinglibraries
310+
if (missingProjects.isNotEmpty()) {
294311
throw GradleException(
295312
"Some libraries in library groups are not in the release: " +
296-
Sets.difference(libraryGroupProjects, releasingProjects).map { it.displayName }
313+
missingProjects.map { it.mavenName }.joinToString("\n")
297314
)
298315
}
299316
}
@@ -475,6 +492,7 @@ abstract class PublishingPlugin : Plugin<Project> {
475492

476493
const val GENERATE_BOM_TASK = "generateBom"
477494
const val VALIDATE_PROJECTS_TO_PUBLISH_TASK = "validateProjectsToPublish"
495+
const val VALIDATE_LIBRARY_GROUPS_TO_PUBLISH_TASK = "validateLibraryGroupsToPublish"
478496
const val SEMVER_CHECK_TASK = "semverCheckForRelease"
479497
const val RELEASE_GENEATOR_TASK = "generateReleaseConfig"
480498
const val VALIDATE_POM_TASK = "validatePomForRelease"

firebase-appdistribution-api/gradle.properties

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,5 +12,5 @@
1212
# See the License for the specific language governing permissions and
1313
# limitations under the License.
1414

15-
version=16.0.0-beta10
16-
latestReleasedVersion=16.0.0-beta09
15+
version=16.0.0-beta11
16+
latestReleasedVersion=16.0.0-beta10

firebase-appdistribution/CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
# Unreleased
2+
3+
# 16.0.0-beta10
24
* [fixed] Updated the third-party license file to include Dagger's license.
35

46
# 16.0.0-beta09

firebase-appdistribution/gradle.properties

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,5 +12,5 @@
1212
# See the License for the specific language governing permissions and
1313
# limitations under the License.
1414

15-
version=16.0.0-beta10
16-
latestReleasedVersion=16.0.0-beta09
15+
version=16.0.0-beta11
16+
latestReleasedVersion=16.0.0-beta10

firebase-firestore/src/test/java/com/google/firebase/firestore/local/SQLiteLocalStoreTest.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -444,9 +444,7 @@ public void testDoesNotAutoCreateIndexesWhenIndexLookUpIsExpensive() {
444444
applyRemoteEvent(
445445
addedRemoteEvent(doc("coll/e", 10, map("array", Arrays.asList(2, 0, 8))), targetId));
446446

447-
// First time query runs without indexes.
448-
// Based on current heuristic, collection document counts (5) > 2 * resultSize (2).
449-
// Full matched index should be created.
447+
// SDK will not create indexes since relative read cost is too large.
450448
executeQuery(query);
451449
assertRemoteDocumentsRead(/* byKey= */ 0, /* byCollection= */ 2);
452450
assertQueryReturned("coll/a", "coll/e");
@@ -479,7 +477,6 @@ public void testIndexAutoCreationWorksWhenBackfillerRunsHalfway() {
479477
// Based on current heuristic, collection document counts (5) > 2 * resultSize (2).
480478
// Full matched index should be created.
481479
executeQuery(query);
482-
// Only document a matches the result
483480
assertRemoteDocumentsRead(/* byKey= */ 0, /* byCollection= */ 2);
484481
assertQueryReturned("coll/a", "coll/e");
485482

firebase-inappmessaging-display/CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
# Unreleased
2+
3+
# 20.3.3
24
* [unchanged] Updated internal Dagger dependency.
35

46
# 20.3.2
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
version=20.3.3
2-
latestReleasedVersion=20.3.2
1+
version=20.3.4
2+
latestReleasedVersion=20.3.3

firebase-inappmessaging/CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
# Unreleased
2+
3+
# 20.3.3
24
* [unchanged] Updated internal Dagger dependency.
35

46
# 20.3.2
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
version=20.3.3
2-
latestReleasedVersion=20.3.2
1+
version=20.3.4
2+
latestReleasedVersion=20.3.3
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
version=17.1.4
2-
latestReleasedVersion=17.1.3
1+
version=17.1.5
2+
latestReleasedVersion=17.1.4
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
version=23.2.1
2-
latestReleasedVersion=23.2.0
1+
version=23.2.2
2+
latestReleasedVersion=23.2.1
33
android.enableUnitTestBinaryResources=true

firebase-messaging/CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
# Unreleased
2+
3+
# 23.2.1
24
* [changed] Changed to finish a background broadcast after the message has been
35
handled, subject to a timeout. This keeps the `FirebaseMessagingService`'s
46
process in an active state while it is handling an FCM message, up to the

firebase-messaging/gradle.properties

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
version=23.2.1
2-
latestReleasedVersion=23.2.0
1+
version=23.2.2
2+
latestReleasedVersion=23.2.2
33
android.enableUnitTestBinaryResources=true

firebase-ml-modeldownloader/CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
# Unreleased
2+
3+
# 24.1.3
24
* [unchanged] Updated internal Dagger dependency.
35
* [fixed] Updated the third-party license file to include Dagger's license.
46

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
version=24.1.3
2-
latestReleasedVersion=24.1.2
1+
version=24.1.4
2+
latestReleasedVersion=24.1.3

firebase-sessions/gradle.properties

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,5 +12,5 @@
1212
# See the License for the specific language governing permissions and
1313
# limitations under the License.
1414

15-
version=1.0.1
16-
latestReleasedVersion=1.0.0
15+
version=1.0.2
16+
latestReleasedVersion=1.0.1

0 commit comments

Comments
 (0)