Merge tag 'v1.5.18' into sc

Change-Id: I4730268dc4327fb16756e73d4dcb428a8c262ec3
This commit is contained in:
SpiritCroc 2023-01-02 17:57:49 +01:00
commit dadeadcad4
7 changed files with 34 additions and 17 deletions

View file

@ -1,4 +1,16 @@
Changes in Element v.5.16 (2022-12-29)
Changes in Element v1.5.18 (2023-01-02)
=======================================
This release fixes a bunch of recent regressions. Most of them were not pushed to production hopefully. Current production version is 1.5.11.
Threads are now enabled by default, and this may let the application perform an initial sync.
Testers on the PlayStore may have experimented some issues like empty room list, or incomplete room state (room name missing, etc.), or even crashing due to initial sync not using lazy loading of room members. All those issues have been fixed, but to fix your current state, please clear cache once you get the release 1.5.18.
Bugfixes 🐛
----------
- Start DM will create a deadlock if user profile was never loaded ([#7870](https://github.com/vector-im/element-android/issues/7870))
Changes in Element v1.5.16 (2022-12-29)
======================================
Features ✨

View file

@ -0,0 +1,2 @@
Main changes in this version: Thread are now enabled by default.
Full changelog: https://github.com/vector-im/element-android/releases

View file

@ -62,7 +62,7 @@ android {
// that the app's state is completely cleared between tests.
testInstrumentationRunnerArguments clearPackageData: 'true'
buildConfigField "String", "SDK_VERSION", "\"1.5.16\""
buildConfigField "String", "SDK_VERSION", "\"1.5.18\""
buildConfigField "String", "GIT_SDK_REVISION", "\"${gitRevision()}\""
buildConfigField "String", "GIT_SDK_REVISION_UNIX_DATE", "\"${gitRevisionUnixDate()}\""

View file

@ -21,7 +21,7 @@ import io.realm.Realm
import io.realm.RealmConfiguration
import io.realm.kotlin.createObject
import kotlinx.coroutines.TimeoutCancellationException
import kotlinx.coroutines.runBlocking
import org.matrix.android.sdk.api.session.events.model.Event
import org.matrix.android.sdk.api.session.events.model.EventType
import org.matrix.android.sdk.api.session.room.failure.CreateRoomFailure
import org.matrix.android.sdk.api.session.room.model.Membership
@ -73,8 +73,9 @@ internal class DefaultCreateLocalRoomTask @Inject constructor(
override suspend fun execute(params: CreateRoomParams): String {
val createRoomBody = createRoomBodyBuilder.build(params)
val roomId = RoomLocalEcho.createLocalEchoId()
val eventList = createLocalRoomStateEventsTask.execute(CreateLocalRoomStateEventsTask.Params(createRoomBody))
monarchy.awaitTransaction { realm ->
createLocalRoomEntity(realm, roomId, createRoomBody)
createLocalRoomEntity(realm, roomId, eventList)
createLocalRoomSummaryEntity(realm, roomId, params, createRoomBody)
}
@ -96,10 +97,10 @@ internal class DefaultCreateLocalRoomTask @Inject constructor(
* Create a local room entity from the given room creation params.
* This will also generate and store in database the chunk and the events related to the room params in order to retrieve and display the local room.
*/
private fun createLocalRoomEntity(realm: Realm, roomId: String, createRoomBody: CreateRoomBody) {
private fun createLocalRoomEntity(realm: Realm, roomId: String, localStateEventList: List<Event>) {
RoomEntity.getOrCreate(realm, roomId).apply {
membership = Membership.JOIN
chunks.add(createLocalRoomChunk(realm, roomId, createRoomBody))
chunks.add(createLocalRoomChunk(realm, roomId, localStateEventList))
membersLoadStatus = RoomMembersLoadStatusType.LOADED
}
}
@ -145,23 +146,19 @@ internal class DefaultCreateLocalRoomTask @Inject constructor(
*
* @param realm the current instance of realm
* @param roomId the id of the local room
* @param createRoomBody the room creation params
* @param localStateEventList list of local state events for that room
*
* @return a chunk entity
*/
private fun createLocalRoomChunk(realm: Realm, roomId: String, createRoomBody: CreateRoomBody): ChunkEntity {
private fun createLocalRoomChunk(realm: Realm, roomId: String, localStateEventList: List<Event>): ChunkEntity {
val chunkEntity = realm.createObject<ChunkEntity>().apply {
isLastBackward = true
isLastForward = true
}
// Can't suspend when using realm as it could jump thread
val eventList = runBlocking {
createLocalRoomStateEventsTask.execute(CreateLocalRoomStateEventsTask.Params(createRoomBody))
}
val roomMemberContentsByUser = HashMap<String, RoomMemberContent?>()
for (event in eventList) {
for (event in localStateEventList) {
if (event.eventId == null || event.senderId == null || event.type == null) {
continue
}

View file

@ -14362,7 +14362,11 @@
"plant",
"nature",
"branch",
"summer"
"summer",
"bamboo",
"wish",
"star_festival",
"tanzaku"
]
},
"pine-decoration": {
@ -14373,10 +14377,12 @@
"celebration",
"Japanese",
"pine",
"japanese",
"plant",
"nature",
"vegetable",
"panda"
"panda",
"new_years"
]
},
"japanese-dolls": {

View file

@ -37,7 +37,7 @@ ext.versionMinor = 5
// Note: even values are reserved for regular release, odd values for hotfix release.
// When creating a hotfix, you should decrease the value, since the current value
// is the value for the next regular release.
ext.versionPatch = 16
ext.versionPatch = 18
ext.scVersion = 62

File diff suppressed because one or more lines are too long