Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

1010: Upgrade react native #1035

Merged

Conversation

steffenkleinle
Copy link
Member

@steffenkleinle steffenkleinle commented Oct 31, 2024

Short description

Upgrade react-native to v0.74.

Proposed changes

Side effects

  • Hopefully none

Testing

Please test the whole app, specifically the code scanner (under Lernbereiche verwalten), the camera, image picker from the gallery and the audio recording (under Eigene Vokablen

Resolved issues

Fixes: #1010, #890


Copy link
Contributor

@LeandraH LeandraH left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Amazing, thank you! Looks pretty good already, I could scan a QR code, I could use a picture from the gallery, and I could record a pronunciation when creating a new Vokabel, this all in real iOS 🥳

I unfortunately also got two errors:

When trying to create a new Vokabel with a picture that I took with the camera within the app, I could take the picture but when hitting "Speichern", I got the following error:

Sentry reported error: [Error: “65893640-A69A-479F-B510-1BEF31C1F5CA.jpg” couldn’t be moved to “Documents” because either the former doesn’t exist, or the folder containing the latter doesn’t exist.]

After adding my own Vokabel with a picture from the gallery (which all worked), I could not open the card from the Vokabelliste, and got the following error message:


Do you have a screen named 'UserVocabularyDetail'?

If you're trying to navigate to a screen in a nested navigator, see https://reactnavigation.org/docs/nesting-navigators#navigating-to-a-screen-in-a-nested-navigator.

This is a development-only warning and won't be shown in production.```

android/app/src/debug/AndroidManifest.xml Show resolved Hide resolved
ios/Lunes/AppDelegate.mm Outdated Show resolved Hide resolved
ios/Lunes/Info.plist Outdated Show resolved Hide resolved
@LeandraH
Copy link
Contributor

LeandraH commented Nov 4, 2024

Oh, I also started getting a bunch of these warnings in my console:

(ADVICE) View #1234 of type RCTView has a shadow set but cannot calculate shadow efficiently. Consider setting a solid background color to fix this, or apply the shadow to a more specific component

It might be related to this: https://stackoverflow.com/questions/75355104/view-has-a-shadow-set-but-cannot-calculate-shadow-efficiently-in-react-native

@steffenkleinle
Copy link
Member Author

steffenkleinle commented Nov 19, 2024

When trying to create a new Vokabel with a picture that I took with the camera within the app, I could take the picture but when hitting "Speichern", I got the following error:

Sentry reported error: [Error: “65893640-A69A-479F-B510-1BEF31C1F5CA.jpg” couldn’t be moved to “Documents” because either the former doesn’t exist, or the folder containing the latter doesn’t exist.]

This happens on iOS only, correct? Did you test in both simulator/real device? Also, does this always happen or just sometimes?

After adding my own Vokabel with a picture from the gallery (which all worked), I could not open the card from the Vokabelliste, and got the following error message:

Do you have a screen named 'UserVocabularyDetail'?
If you're trying to navigate to a screen in a nested navigator, see https://reactnavigation.org/docs/nesting-navigators#navigating-to-a-screen-in-a-nested-navigator.`

I just checked and it seems like the problem already exists on main. I'll create an issue: #1037

@steffenkleinle steffenkleinle marked this pull request as ready for review December 4, 2024 16:10
Copy link
Contributor

@LeandraH LeandraH left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Woohoo! Tested on real iOS

Copy link
Member

@ztefanie ztefanie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for taking care of this update ❤️

Tested on Android real device and found a few errors:

adding a new word: Could not add a audio record for a new custom word. Error "startRecorder has already been called".
Steps to reproduce: "Meine Wörter" -> "Vokabel erstellen" -> "Audio aufnehmen" -> click on mircophone-icon -> See error

Adding a new word -> then go to the list of my words -> click on the item -> Error: "the action "navigate" with payload was not handled"

Menu is shown when navigating back on home screen after settings. Steps to reproduce: open home screen -> go to menu -> open "Lernbereiche verwalten" -> click "back". See menu is open on homescreen. Would expect it to be closed

@steffenkleinle
Copy link
Member Author

steffenkleinle commented Dec 12, 2024

adding a new word: Could not add a audio record for a new custom word. Error "startRecorder has already been called". Steps to reproduce: "Meine Wörter" -> "Vokabel erstellen" -> "Audio aufnehmen" -> click on mircophone-icon -> See error

Hmm, I guess I'll have another look. I really thought I tested this thoroughly and there were no more errors :/

Adding a new word -> then go to the list of my words -> click on the item -> Error: "the action "navigate" with payload was not handled"

See #1037, already happens on main as well.

Menu is shown when navigating back on home screen after settings. Steps to reproduce: open home screen -> go to menu -> open "Lernbereiche verwalten" -> click "back". See menu is open on homescreen. Would expect it to be closed

This is the same behavior as on main, please open a new issue, I think this PR is big enough already :)

@ztefanie
Copy link
Member

Menu is shown when navigating back on home screen after settings. Steps to reproduce: open home screen -> go to menu -> open "Lernbereiche verwalten" -> click "back". See menu is open on homescreen. Would expect it to be closed

#1046

Copy link
Contributor

@f1sh1918 f1sh1918 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unfortunately i found one issue

  1. Create own vocabulary.
  2. Go to detail view on the created vocabulary leads to
 The action 'NAVIGATE' with payload {"name":"UserVocabularyDetail","params":{"vocabularyItem":{"id":1,"word":"Test","article":{"id":1,"value":"der"},"images":[{"id":0,"image":"file:////data/user/0/app.lunes/files/image-1-0-1736333899166.jpg"}],"audio":"file:////data/user/0/app.lunes/files/audio-1.mp4","alternatives":[],"type":"user-created"}}} was not handled by any navigator.

and nothing happens

@LeandraH
Copy link
Contributor

LeandraH commented Jan 8, 2025

Unfortunately i found one issue

1. Create own vocabulary.

2. Go to detail view on the created vocabulary leads to
 The action 'NAVIGATE' with payload {"name":"UserVocabularyDetail","params":{"vocabularyItem":{"id":1,"word":"Test","article":{"id":1,"value":"der"},"images":[{"id":0,"image":"file:////data/user/0/app.lunes/files/image-1-0-1736333899166.jpg"}],"audio":"file:////data/user/0/app.lunes/files/audio-1.mp4","alternatives":[],"type":"user-created"}}} was not handled by any navigator.

and nothing happens

That seems to be an issue on main, Steffen already opened #1037 for it

@f1sh1918 f1sh1918 self-requested a review January 8, 2025 11:12
@f1sh1918
Copy link
Contributor

f1sh1918 commented Jan 8, 2025

Unfortunately i found one issue

1. Create own vocabulary.

2. Go to detail view on the created vocabulary leads to
 The action 'NAVIGATE' with payload {"name":"UserVocabularyDetail","params":{"vocabularyItem":{"id":1,"word":"Test","article":{"id":1,"value":"der"},"images":[{"id":0,"image":"file:////data/user/0/app.lunes/files/image-1-0-1736333899166.jpg"}],"audio":"file:////data/user/0/app.lunes/files/audio-1.mp4","alternatives":[],"type":"user-created"}}} was not handled by any navigator.

and nothing happens

That seems to be an issue on main, Steffen already opened #1037 for it

ok sorry i didn't get this. i pushed a commit to fix that @steffenkleinle
So the mentioned issue should be fixed

Copy link
Contributor

@f1sh1918 f1sh1918 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested on android real device and ios simulator. works fine

@LeandraH
Copy link
Contributor

LeandraH commented Jan 8, 2025

Amazing!

@steffenkleinle
Copy link
Member Author

@LeandraH @f1sh1918 you are not experiencing this issue? I could also reproduce this... have to have another look at some point...

adding a new word: Could not add a audio record for a new custom word. Error "startRecorder has already been called".
Steps to reproduce: "Meine Wörter" -> "Vokabel erstellen" -> "Audio aufnehmen" -> click on mircophone-icon -> See error

@f1sh1918
Copy link
Contributor

f1sh1918 commented Jan 8, 2025

@LeandraH @f1sh1918 you are not experiencing this issue? I could also reproduce this... have to have another look at some point...

adding a new word: Could not add a audio record for a new custom word. Error "startRecorder has already been called".
Steps to reproduce: "Meine Wörter" -> "Vokabel erstellen" -> "Audio aufnehmen" -> click on mircophone-icon -> See error

i didn't test on ios real device but on android real device it worked for me (but android 11) @steffenkleinle

@LeandraH
Copy link
Contributor

LeandraH commented Jan 8, 2025

@LeandraH @f1sh1918 you are not experiencing this issue? I could also reproduce this... have to have another look at some point...

adding a new word: Could not add a audio record for a new custom word. Error "startRecorder has already been called".
Steps to reproduce: "Meine Wörter" -> "Vokabel erstellen" -> "Audio aufnehmen" -> click on mircophone-icon -> See error

i didn't test on ios real device but on android real device it worked for me (but android 11) @steffenkleinle

Tested on a real iOS device and I could not reproduce the issue. When I only tapped on the microphone instead of holding it, I got the following warning, though: "Sending rn-recordback with no listeners registered." but that looks different (and like not a big issue) to me.

Copy link
Contributor

@lunars97 lunars97 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have been trying to solve this issue #1043 and upgrading the react-native seems to solve it 👍

@lunars97
Copy link
Contributor

lunars97 commented Jan 9, 2025

I faced the error when I was viewing a vocabulary list words when I clicked on the button "Nächstes Wort" saying Warning: Error: Exception in HostFunction: Loss of precision during arithmetic conversion: (long long) 9.090909090909092 This error seems like because of the upgrade of the react-native-paper. The progress prop of ProgressBar component causing this issue. Changing it to animatedValue solves it 👍 as it is stated here facebook/react-native#47635 (comment)

@steffenkleinle
Copy link
Member Author

steffenkleinle commented Jan 10, 2025

Hmm if none of you can reproduce this we might also just merge this? Could you all please test this on iOS simulator AND real device if possible please? This might only be a ios simulator problem?

@LeandraH
Copy link
Contributor

LeandraH commented Jan 10, 2025

Hmm if none of you can reproduce this we might also just merge this? Could you all please test this on iOS simulator AND real device if possible please? This might only be a ios simulator problem?

I just tested it on an iOS simulator and couldn't reproduce the issue there either, nor yesterday on my iPhone. But Steffi said in her comment that she had the issue on a real Android device.

@LeandraH LeandraH dismissed ztefanie’s stale review January 16, 2025 11:12

😢

Steffen is checking if he can reproduce the issue Steffi mentioned.

@steffenkleinle
Copy link
Member Author

I faced the error when I was viewing a vocabulary list words when I clicked on the button "Nächstes Wort" saying Warning: Error: Exception in HostFunction: Loss of precision during arithmetic conversion: (long long) 9.090909090909092 This error seems like because of the upgrade of the react-native-paper. The progress prop of ProgressBar component causing this issue. Changing it to animatedValue solves it 👍 as it is stated here facebook/react-native#47635 (comment)

@lunars97 could you perhaps open a new PR for this fix please? You can base it on my PR. Sadly I don't have much time for this atm 🙈

@steffenkleinle
Copy link
Member Author

I think I fixed Steffis issue with stopping to fast. In edge cases it might still be possible to break it, but I don't have more time right now and this should only happen if users really try to break it :D So as long as we don't get complaints, I think this is good to merge :)

@steffenkleinle steffenkleinle merged commit 2cdfab3 into 873-react-native-vision-camera Jan 17, 2025
2 checks passed
@steffenkleinle steffenkleinle deleted the 1010-upgrade-react-native branch January 17, 2025 14:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Upgrade react-native LUN-458: Remove react-native-audio-record-player patch
5 participants