Giter Site home page Giter Site logo

Comments (5)

arekkubaczkowski avatar arekkubaczkowski commented on August 10, 2024

If you are encountering such error while building the app probably means that you might have some issue on your local environment side. I have never seen such error in this project tbh, because of that it is hard to find some better solution than outlining it in troubleshooting section in the README file.

from stripe-terminal-react-native.

arekkubaczkowski avatar arekkubaczkowski commented on August 10, 2024

but after a small research, Android documentation doesn't recommend the solution that you suggested:
However, the ability to request a large heap is intended only for a small set of apps that can justify the need to consume more RAM (such as a large photo editing app). Never request a large heap simply because you've run out of memory and you need a quick fix—you should use it only when you know exactly where all your memory is being allocated and why it must be retained. Yet, even when you're confident your app can justify the large heap, you should avoid requesting it to whatever extent possible. Using the extra memory will increasingly be to the detriment of the overall user experience because garbage collection will take longer and system performance may be slower when task switching or performing other common operations.

Instead of that they recommend to find the root of this issue which might be difficult for react-native users. However, I don't think we should suggest it for stripe terminal users.

From my point of view we have two options:

  • we can try to find out if your issue is strictly related with the library, if so we need to fix it somehow (if it concerns RN environment - not Android library), otherwise this means there is something wrong with the example app or your local env.
  • Simply wait for user's feedback and then react accordingly

from stripe-terminal-react-native.

cscott-stripe avatar cscott-stripe commented on August 10, 2024

I was seeing this too in my own project (not the example) and setting the jvm args as noted in the RN template to use more RAM worked for me.

from stripe-terminal-react-native.

arekkubaczkowski avatar arekkubaczkowski commented on August 10, 2024

@cscott-stripe we have it already https://github.com/stripe/stripe-terminal-react-native/blob/main/example/android/gradle.properties#L13

from stripe-terminal-react-native.

dhenry-stripe avatar dhenry-stripe commented on August 10, 2024

Spoke with @jdivock-stripe offline: this was only occurring when building via Android Studio. Android Studio memory settings take precedence over those set in gradle.properties and should be set to something like:
Screen Shot 2022-03-03 at 5 34 44 PM

Closing for now, we can re-open if it occurs again.

from stripe-terminal-react-native.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.