rive-app / rive-app/rive-react-native

Android app crashes in release build if I store Rive file locally in raw assets.

Open
#318 10 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
783
Forks
81
Avg merge
3d 6h
Merged PRs (30d)
3

Description

Description

Android app crashes in release build if I store Rive file locally in raw assets.

Provide a Repro

<--
<Rive
onPlay={onPlay}
resourceName={'file_name'}
style={{ width, height }}
onRiveEventReceived={onRiveEventReceived}
/>

-->

File path

android/app/src/main/res/raw/file_name.riv

Device & Versions (please complete the following information)
  • Device: Android device
  • OS: Android 14
  • NPM Version: npm --version - 10.7.0
Additional context

The rive is working fine on iOS and android emulator, but for android, it's causing crash in release build.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing a release Android build with the Rive component and the asset at android/app/src/main/res/raw/file_name.riv. Inspect the Android release handling for this local resource and compare it with the working emulator and iOS cases. Done means the app no longer crashes when the Rive file is loaded from raw assets.

Written by the indexing model from the issue text.

Assessment

Tech stack
android, react-native, typescript
Domain
mobile, mobile-dev
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.