mirror of
https://github.com/Novaloop-AG/element-x-android.git
synced 2026-11-03 16:10:00 +00:00
Update Matrix Rust SDK to 26.10.05-nightly (#7844)
* Update Matrix Rust SDK to 26.10.01-nightly * Add ivy repository for nightly SDK binding versions * Fix API breaks * Make sure we can't release a version with a `-nightly` SDK version * Fix typo Co-authored-by: Benoit Marty <benoitm@element.io> * Update Matrix Rust SDK to 26.10.05-nightly --------- Co-authored-by: github-actions <github-actions@github.com> Co-authored-by: Jorge Martín <jorgem@element.io> Co-authored-by: Benoit Marty <benoitm@element.io>
This commit is contained in:
@@ -37,6 +37,8 @@ jobs:
|
|||||||
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
||||||
with:
|
with:
|
||||||
persist-credentials: false
|
persist-credentials: false
|
||||||
|
- name: Check Matrix Rust SDK is not a nightly version
|
||||||
|
run: ./tools/release/check_no_nightly_sdk.sh
|
||||||
- name: Use JDK 21
|
- name: Use JDK 21
|
||||||
uses: actions/setup-java@de7274f081f381c8f8158605e0321c36c376e2e6 # v6.0.1
|
uses: actions/setup-java@de7274f081f381c8f8158605e0321c36c376e2e6 # v6.0.1
|
||||||
with:
|
with:
|
||||||
@@ -87,6 +89,8 @@ jobs:
|
|||||||
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
||||||
with:
|
with:
|
||||||
persist-credentials: false
|
persist-credentials: false
|
||||||
|
- name: Check Matrix Rust SDK is not a nightly version
|
||||||
|
run: ./tools/release/check_no_nightly_sdk.sh
|
||||||
- name: Use JDK 21
|
- name: Use JDK 21
|
||||||
uses: actions/setup-java@de7274f081f381c8f8158605e0321c36c376e2e6 # v6.0.1
|
uses: actions/setup-java@de7274f081f381c8f8158605e0321c36c376e2e6 # v6.0.1
|
||||||
with:
|
with:
|
||||||
|
|||||||
@@ -186,7 +186,7 @@ test_detekt_test = { module = "io.gitlab.arturbosch.detekt:detekt-test", version
|
|||||||
# it as a plain `require`: without this, a library built against a newer SDK would silently drag this app
|
# it as a plain `require`: without this, a library built against a newer SDK would silently drag this app
|
||||||
# onto it. With it, this pin always wins, and a library that needs something newer fails at configuration
|
# onto it. With it, this pin always wins, and a library that needs something newer fails at configuration
|
||||||
# time naming both versions instead of at runtime with NoSuchMethodError.
|
# time naming both versions instead of at runtime with NoSuchMethodError.
|
||||||
matrix_sdk = { module = "org.matrix.rustcomponents:sdk-android", version = { strictly = "26.09.28" } }
|
matrix_sdk = { module = "org.matrix.rustcomponents:sdk-android", version = { strictly = "26.10.05-nightly" } }
|
||||||
rustls_platform_verifier = "org.rustls:rustls-platform-verifier:0.2.0"
|
rustls_platform_verifier = "org.rustls:rustls-platform-verifier:0.2.0"
|
||||||
|
|
||||||
# Others
|
# Others
|
||||||
|
|||||||
+4
@@ -125,6 +125,10 @@ fun RustEventSendState?.map(): LocalEventSendState? {
|
|||||||
is QueueWedgeError.MissingMediaContent -> {
|
is QueueWedgeError.MissingMediaContent -> {
|
||||||
LocalEventSendState.Failed.MissingMediaContent
|
LocalEventSendState.Failed.MissingMediaContent
|
||||||
}
|
}
|
||||||
|
is QueueWedgeError.ExpiredAccessToken -> {
|
||||||
|
// This will automatically recover, so map it to the sending state
|
||||||
|
LocalEventSendState.Sending.Event
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
is RustEventSendState.Sent -> LocalEventSendState.Sent(EventId(eventId))
|
is RustEventSendState.Sent -> LocalEventSendState.Sent(EventId(eventId))
|
||||||
|
|||||||
@@ -57,6 +57,18 @@ dependencyResolutionManagement {
|
|||||||
flatDir {
|
flatDir {
|
||||||
dirs("libraries/matrix/libs")
|
dirs("libraries/matrix/libs")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Add ivy repository for nightly builds of the SDK bindings for Android, which are published as GitHub release assets.
|
||||||
|
ivy {
|
||||||
|
url = uri("https://github.com/matrix-org/matrix-rust-components-kotlin/releases/download")
|
||||||
|
patternLayout { artifact("sdk-[revision]/[artifact]-[revision](-[classifier])(.[ext])") }
|
||||||
|
metadataSources { gradleMetadata() }
|
||||||
|
content {
|
||||||
|
// The nightly versions of the SDK bindings for Android
|
||||||
|
includeModule("org.matrix.rustcomponents", "sdk-android")
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Temporary: the native call component and the matrix-rust-rtc core publish as GitHub release
|
// Temporary: the native call component and the matrix-rust-rtc core publish as GitHub release
|
||||||
// assets, which carry full Maven metadata. Both blocks go once they reach Maven Central.
|
// assets, which carry full Maven metadata. Both blocks go once they reach Maven Central.
|
||||||
ivy {
|
ivy {
|
||||||
|
|||||||
Executable
+24
@@ -0,0 +1,24 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# Copyright (c) 2026 Element Creations Ltd.
|
||||||
|
#
|
||||||
|
# SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial.
|
||||||
|
# Please see LICENSE files in the repository root for full details.
|
||||||
|
|
||||||
|
# Fails if the matrix_sdk dependency uses a "-nightly" version, which must never be released.
|
||||||
|
|
||||||
|
versionsFile="$(dirname "$0")/../../gradle/libs.versions.toml"
|
||||||
|
|
||||||
|
sdkLine=$(grep -E '^matrix_sdk[[:space:]]*=' "${versionsFile}")
|
||||||
|
if [[ -z "${sdkLine}" ]]; then
|
||||||
|
echo "Fatal: could not find the matrix_sdk dependency in ${versionsFile}"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ "${sdkLine}" == *-nightly* ]]; then
|
||||||
|
echo "Fatal: the matrix_sdk dependency uses a nightly version, which cannot be released:"
|
||||||
|
echo " ${sdkLine}"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "matrix_sdk dependency is not a nightly version."
|
||||||
@@ -74,6 +74,9 @@ if [[ ! -d ${buildToolsPath} ]]; then
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Check that the Matrix Rust SDK is not a nightly version
|
||||||
|
./tools/release/check_no_nightly_sdk.sh || exit 1
|
||||||
|
|
||||||
# Check if git flow is enabled
|
# Check if git flow is enabled
|
||||||
gitFlowDevelop=$(git config gitflow.branch.develop)
|
gitFlowDevelop=$(git config gitflow.branch.develop)
|
||||||
if [[ ${gitFlowDevelop} != "" ]]
|
if [[ ${gitFlowDevelop} != "" ]]
|
||||||
|
|||||||
@@ -94,6 +94,9 @@ if [[ ! -d ${buildToolsPath} ]]; then
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Check that the Matrix Rust SDK is not a nightly version
|
||||||
|
./tools/release/check_no_nightly_sdk.sh || exit 1
|
||||||
|
|
||||||
# Check that there is no unmerged PR with the label "Z-NextRelease", else exit
|
# Check that there is no unmerged PR with the label "Z-NextRelease", else exit
|
||||||
unmergedPrs=$(gh pr list --repo element-hq/element-x-android --label "Z-NextRelease" --state open --json title,url -q '.[] | "\(.url): \(.title)"')
|
unmergedPrs=$(gh pr list --repo element-hq/element-x-android --label "Z-NextRelease" --state open --json title,url -q '.[] | "\(.url): \(.title)"')
|
||||||
if [[ ${unmergedPrs} != "" ]]; then
|
if [[ ${unmergedPrs} != "" ]]; then
|
||||||
|
|||||||
Reference in New Issue
Block a user