Releases: realm/realm-js
Releases · realm/realm-js
Realm JavaScript v12.13.2
Fixed
- Fixed build error on React Native Android when used with React Native 0.76, due to the merge of dynamic libraries. (#6908 since React Native v0.76.0).
- Filtering notifications with backlink columns as last element could sometimes give wrong results (realm/realm-core#7530, since Realm JS v10.6.2-beta.1)
- Fix crash during client app shutdown when Logger log level is set higher than Info. (realm/realm-core#7969, since Realm JS v12.3.1)
- If File::rw_lock() fails to open a file the exception message does not contain the filename (realm/realm-core#7999, since Realm JS v6.1.0)
- Fallback to hashed filename will fail if length of basename is between 240 and 250 (realm/realm-core#8007, since Realm JS v10.0.0)
- Having a query with a number of predicates ORed together may result in a crash on some platforms (strict weak ordering check failing on iphone) (realm/realm-core#8028, since Realm JS v12.8.0)
- The events library would attempt to upload backup files created as part of file format upgrades, causing backup copies of those backups to be made, looping until the maximum file name size was reached (realm/realm-core#8040, since Realm JS v10.18.0).
Compatibility
- React Native >= v0.71.4
- Realm Studio v15.0.0.
- File format: generates Realms with format v24 (reads and upgrades file format v10).
Internal
- Upgraded Realm Core from v14.12.0 to v14.13.1.
Realm React v0.11.0
Enhancements
- Add more additional overload to
useQuery
to allow the react-hooks/exhaustive-deps eslint rule to work (#6819)
Fixed
- None
Compatibility
- React Native >= v0.71.4
- Realm Studio v15.0.0.
- File format: generates Realms with format v24 (reads and upgrades file format v10).
Realm JavaScript v20.0.0
Breaking Changes
- Removed all functionality related to Atlas Device Services / Device Sync.
Compatibility
- React Native >= v0.71.4
- Realm Studio v20.0.0.
- File format: generates Realms with format v24 (reads and upgrades file format v10).
Internal
- Upgraded Realm Core from v14.12.0 to v20.0.1
Realm React v0.10.1
Fixed
- Fixing the
RealmProvider
component when context is created without passing neither aRealm
instance nor aRealm.Configuration
to avoid unnecessary recreation of the provider, which was causing "Cannot access realm that has been closed" errors. (#6842, since v0.8.0)
Compatibility
- React Native >= v0.71.4
- Realm Studio v15.0.0.
- File format: generates Realms with format v24 (reads and upgrades file format v10).
Realm JavaScript v12.13.1
Fixed
- Fixed a build error on React Native iOS and Android from a change in the
CallInvoker
'sinvokeAsync
call signature. (#6851 since v12.12.0 in combination with React Native >= v0.75.0).
Compatibility
- React Native >= v0.71.4
- Realm Studio v15.0.0.
- File format: generates Realms with format v24 (reads and upgrades file format v10).
Realm React v0.10.0
Enhancements
- Added
useProgress
hook which provides a convenient way to access Realm's progress information. It works in a similar way asrealm.addProgressNotification
. (#6797)
import { RealmProvider, ProgressDirection, ProgressMode } from "@realm/react";
const ProgressText = () => {
const progress = useProgress({ direction: ProgressDirection.Download, mode: ProgressMode.ReportIndefinitely });
return <Text>Loading: {(100 * progress).toFixed()}%</Text>;
}
const MyApp() = () => {
return (
<RealmProvider sync={...}>
<ProgressText />
</RealmProvider>
);
}
- Added the ability to get
progress
information infallback
component ofRealmProvider
when opening a synced Realm. (#6785)
import { RealmProvider, RealmProviderFallback } from "@realm/react";
const Fallback: RealmProviderFallback = ({ progress }) => {
return <Text>Loading:{(100 * progress).toFixed()}%</Text>;
}
const MyApp() = () => {
return (
<RealmProvider sync={...} fallback={Fallback}>
...
</RealmProvider>
);
}
Compatibility
- Realm JavaScript >= v12.12.0.
- React Native >= v0.71.4
- Realm Studio v15.0.0.
- File format: generates Realms with format v24 (reads and upgrades file format v10).
Realm JavaScript v12.13.0
Warning
This release is confirmed broken in combination with React Native v0.75.0 and upward.
Please upgrade to v12.13.1 to fix any issues regarding call signatures of the CallInvoker API.
Enhancements
- Improved sync bootstrap performance. (realm/realm-core#7945 and realm/realm-core#7946)
- Client reset cycle detection now checks if the previous recovery attempt was made by the same core version, and if not attempts recovery again. (realm/realm-core#7944)
- Updated bundled OpenSSL version to 3.3.1. (realm/realm-core#7947)
- Sync log statements now include the app services connection ID in their prefix (e.g
Connection[1:<connection id>] Session[1]: log message
). (realm/realm-core#7849)
Fixed
- Fixed an
Invalid column key
exception when using an RQL "BETWEEN" query on an int or timestamp property across links. (realm/realm-core#7935, since v12.12.0) - Fixed conflict resolution bug which could sometimes cause an
Invalid prior_size
exception to prevent synchronization (realm/realm-core#7893, since v12.10.0) - Fixed bug which would prevent eventual consistency during conflict resolution. Affected clients would experience data divergence and potentially consistency errors as a result. (realm/realm-core#7955, since v12.10.0)
- Fixed issues loading the native Realm libraries on Linux ARMv7 systems when they linked against our bundled OpenSSL resulting in errors like
unexpected reloc type 0x03
. (realm/realm-core#7947, since v12.7.0) - Sync client may report duplicate compensating write errors. (realm/realm-core#7708, since v12.10.0)
- String serialization of timestamps with a sufficiently large timestamp value could overflow an int causing undefined behavior, causing potentially bad values for the month/day/year values in stringified dates. (realm/realm-core#7934)
- App subscription callback was getting fired before the user profile was retrieved on login, leading to an empty user profile when using the callback. (realm/realm-core#7889, since v12.9.0)
Compatibility
- React Native >= v0.71.4
- Realm Studio v15.0.0.
- File format: generates Realms with format v24 (reads and upgrades file format v10).
Internal
- Upgraded Realm Core from v14.11.0 to v14.12.0.
Realm JavaScript v12.12.1
Warning
This release is confirmed broken in combination with React Native v0.75.0 and upward.
Please upgrade to v12.13.1 to fix any issues regarding call signatures of the CallInvoker API.
Fixed
- Fixed compiler error when building binding for React Native iOS: "'React-featureflags/react/featureflags/ReactNativeFeatureFlags.h' file not found" (#6808, since v12.12.0)
Compatibility
- React Native >= v0.71.4
- Realm Studio v15.0.0.
- File format: generates Realms with format v24 (reads and upgrades file format v10).
Internal
- Removed an unused import in the binding for React Native Android. (#6808, since v12.12.0)
Realm JavaScript v12.12.0
Warning
This release is confirmed broken in combination with React Native v0.75.0 and upward.
Please upgrade to v12.13.1 to fix any issues regarding call signatures of the CallInvoker API.
Deprecations
- The callback for
SyncSession.addProgressNotification
takingtransferred
andtransferable
arguments is deprecated and will be removed. See Enhancements below for the new callback supporting both Flexible Sync and Partition-Based Sync. (#6743) AppConfiguration.app
is no longer used by Atlas Device Sync. It will be removed in future SDK releases and should not be used. (#6785)
Enhancements
- Added support for "bridgeless" React Native on iOS and Android, a part of the "new architecture". (#6737)
- Added progress notifications support for Flexible Sync using an
estimate
as the new callback argument. Theestimate
is roughly equivalent to an estimated value oftransferred / transferable
in the deprecated Partition-Based Sync callback. (#6743)
realm.syncSession?.addProgressNotification(
ProgressDirection.Upload,
ProgressMode.ReportIndefinitely,
(estimate) => console.log(`progress: ${estimate}/1.0`)
);
- It is no longer an error to set a base url for an App with a trailing slash - for example,
https://services.cloud.mongodb.com/
instead ofhttps://services.cloud.mongodb.com
- before this change that would result in a 404 error from the server. (realm/realm-core#7791) - Performance has been improved for range queries on integers and timestamps when using the
BETWEEN
operator. (realm/realm-core#7785) - On Windows devices Device Sync will additionally look up SSL certificates in the Windows Trusted Root Certification Authorities certificate store when establishing a connection. (realm/realm-core#7882)
- Role and permissions changes no longer require a client reset to update the Realm on-device. (realm/realm-core#7440)
Fixed
- Opening an Flexible Sync Realm asynchronously may not wait to download all data. (realm/realm-core#7720, since v10.12.0)
- Clearing a list of
mixed
in an upgraded file would lead to an assertion failing. (realm/realm-core#7771, since 12.7.0-rc.0) - Sync client can crash if a session is resumed while the session is being suspended. (realm/realm-core#7860, since v10.18.0)
- If a sync session is interrupted by a disconnect or restart while downloading a bootstrap, stale data from the previous bootstrap may be included when the session reconnects and downloads the bootstrap. This can lead to objects stored in the database that do not match the actual state of the server and potentially leading to compensating writes. (realm/realm-core#7827, since v10.18.0)
- Fixed unnecessary server roundtrips when there is no download to acknowledge. (realm/realm-core#2129, since v12.10.0)
Realm.App.Sync.SyncSession#uploadAllLocalChanges()
was inconsistent in how it handled commits which did not produce any changesets to upload. Previously it would sometimes complete immediately if all commits waiting to be uploaded were empty, and at other times it would wait for a server roundtrip. It will now always complete immediately. (realm/realm-core#7796)Realm#writeCopyTo()
on an encrypted Realm without explicitly specifying a new encryption key would only work if the old key happened to be a valid nul-terminated string. (realm/realm-core#7842, since v12.10.0).- You could get unexpected merge results when assigning to a nested collection. (realm/realm-core#7809, since v12.7.0-rc.0)
- When
mapTo
is used to have an alias for a property name,Realm.Results#sorted()
doesn't recognize the alias leading to errors likeCannot sort on key path 'NAME': property 'PersonObject.NAME' does not exist
. (#6779, since v11.2.0) - A
mixed
property with a collection could sometimes end up with a combination of values assigned by different clients. (realm/realm-core#7809, since v12.9.0) - Fixed removing backlinks from the wrong objects if the link came from a nested list, nested dictionary, top-level dictionary, or list of mixed, and the source table had more than 256 objects. This could manifest as
array_backlink.cpp:112: Assertion failed: int64_t(value >> 1) == key.value
when removing an object. (realm/realm-core#7594, since v10.6.0) - Fixed a bug when removing an object from a nested collection could lead to an assert with the message
array.cpp:319: Array::move() Assertion failed: begin <= end [2, 1]
. (realm/realm-core#7839, since v12.9.0)
Compatibility
- React Native >= v0.71.4
- Realm Studio v15.0.0.
- File format: generates Realms with format v24 (reads and upgrades file format v10).
Internal
Realm React v0.9.0
Enhancements
- Added the ability to pass an existing
Realm.App
instance inAppProvider
with theapp
prop. (#6785)
import { AppProvider } from "@realm/react";
const app = new Realm.App(...);
function MyApp() {
return (
<AppProvider app={app}>
...
</AppProvider>
);
}
Fixed
- Fixed listener that was not being removed during unmounting of
useObject
anduseQuery
if the listener was added in a write transaction. (#6552) Thanks @bimusiek! - The
app
prop inAppProvider
meant forLocalAppConfiguration
was not being used by Atlas Device Sync and has been removed.app
is now only used to pass an existingRealm.App
to the provider. (#6785)
Compatibility
- React Native >= v0.71.4
- See "Compatibility" for a specific Realm version in Realm's CHANGELOG.