triniwiz / triniwiz/nativescript-plugins
SCA not working [Nativescript-Stripe]
Open
Nobody has claimed this yet.
- Dominant language
- C
- Stars
- 87
- Forks
- 57
- Avg merge
- 1h 36m
- Merged PRs (30d)
- 4
Description
When I call
new StripeStandardCustomerSession();
The app crashes with this log
====== Assertion failed ======
Native stack trace:
1 0x10bdec2bb tns::Assert(bool, v8::Isolate*) + 119
2 0x10bd714b7 tns::ArgConverter::CreateJsWrapper(v8::Local<v8::Context>, tns::BaseDataWrapper*, v8::Local<v8::Object>, bool, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) + 1677
3 0x10be0e547 tns::Interop::GetResult(v8::Local<v8::Context>, tns::TypeEncoding const*, tns::BaseCall*, bool, std::__1::shared_ptr<v8::Persistent<v8::Value, v8::NonCopyablePersistentTraits<v8::Value> > >, bool, bool, bool, bool) + 4137
4 0x10be0a234 tns::Interop::CallFunctionInternal(tns::MethodCall&) + 580
5 0x10bd70785 tns::ArgConverter::Invoke(v8::Local<v8::Context>, objc_class*, v8::Local<v8::Object>, tns::V8Args&, tns::MethodMeta const*, bool) + 731
6 0x10bdc5d5e tns::MetadataBuilder::InvokeMethod(v8::Local<v8::Context>, tns::MethodMeta const*, v8::Local<v8::Object>, tns::V8Args&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, bool) + 76
7 0x10bdc5635 tns::MetadataBuilder::MethodCallback(v8::FunctionCallbackInfo<v8::Value> const&) + 219
8 0x10bf0236e v8::internal::FunctionCallbackArguments::Call(v8::internal::CallHandlerInfo) + 606
9 0x10bf017f7 v8::internal::MaybeHandle<v8::internal::Object> v8::internal::(anonymous namespace)::HandleApiCallHelper<false>(v8::internal::Isolate*, v8::internal::Handle<v8::internal::HeapObject>, v8::internal::Handle<v8::internal::HeapObject>, v8::internal::Handle<v8::internal::FunctionTemplateInfo>, v8::internal::Handle<v8::internal::Object>, v8::internal::BuiltinArguments) + 727
10 0x10bf00d4f v8::internal::Builtin_Impl_HandleApiCall(v8::internal::BuiltinArguments, v8::internal::Isolate*) + 255
11 0x10c6bf3f9 Builtins_CEntry_Return1_DontSaveFPRegs_ArgvOnStack_BuiltinExit + 57
12 0x10c65816a Builtins_InterpreterEntryTrampoline + 202
13 0x10c65574b construct_stub_create_deopt_addr + 246
JavaScript stack trace:
at new StripeStandardCustomerSession (file: app/packages/nativescript-stripe/standard/index.ios.ts:69:43)
at <anonymous> (file: app/components/Checkout.vue:134:0)
at asyncGeneratorStep (file:///app/bundle.js:542:103)
at _next (file:///app/bundle.js:544:194)
at <anonymous> (file:///app/bundle.js:544:364)
at <anonymous> (VM)
at construct (VM)
at <anonymous> (file:///app/bundle.js:544:97)
at onApplePayTap (file: app/components/Checkout.vue:133:0)
at invokeWithErrorHandling (file: node_modules/nativescript-vue/dist/index.js:1862:25)
^C
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at app/packages/nativescript-stripe/standard/index.ios.ts:69, where StripeStandardCustomerSession is constructed, and reproduce the call from app/components/Checkout.vue:134. Use the assertion and JavaScript stack trace to trace the failing native interop result; done means the constructor no longer crashes when the SCA flow is invoked.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- ios, javascript, typescript
- Domain
- mobile-dev, payments
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100