Giter VIP home page Giter VIP logo

Comments (9)

siddarthkay avatar siddarthkay commented on June 13, 2024 1

have you tried re-generate?

yes I did and the generated file was quite small and missed many functions.
After speaking with @cammellos : I found out that we have long abandoned that tool and we edit this file manually.

I will remove this comment in my next PR.

from status-mobile.

siddarthkay avatar siddarthkay commented on June 13, 2024

Indeed the failure is due to upgrading golang to 1.20.12

One key thing worth noting is that when I update my overlay.nix to point go and buildGoModule to 1_19 Integration tests start working on MacOS.

This weird failure of contract tests with golang version 1.20 happens only on MacOS which is very annoying and we know this does not happen on Linux else it would also be reproducible on CI hosts.

from status-mobile.

siddarthkay avatar siddarthkay commented on June 13, 2024

The key error message to focus on from the stack trace is this

dyld[30877]: missing symbol called

and this happens right after

2024-05-08T14:02:24.489Z DEBUG [utils.re-frame:25] - Handling re-frame event:  :wallet/get-wallet-token

My initial guess was that :wallet/get-wallet-token triggers the failure.

I then commented out this reframe event and that the contract tests would run for longer but eventually fail with the same error message, so :wallet/get-wallet-token reframe event was not the root cause.

from status-mobile.

siddarthkay avatar siddarthkay commented on June 13, 2024

dyld[70658]: missing symbol called typically indicates a problem with dynamic linking in a macOS application.

dyld stands for "dynamic linker/loader". It is the component of the macOS operating system responsible for loading and linking dynamic libraries required by an application at runtime.

So at some point in the test run a "symbol" is not found. If we know which symbol is not found that would help us to narrow down the root cause further.

from status-mobile.

siddarthkay avatar siddarthkay commented on June 13, 2024

I assume that the source of missing symbols for integration tests could be status.cpp file located here -> https://github.com/status-im/status-mobile/blob/497c95fd2682653472722f7fcc13ec74e244318e/modules/react-native-status/nodejs/status.cpp

I tried to regenerate this file by using this tool https://github.com/divan/go2nodebinding/tree/master on https://github.com/status-im/status-go/blob/6b5315b1fde8edfd7268eaef41af3ea24412f644/mobile/status.go

But the file contained fewer functions than what we already have.. it could be possible that this file was later on modified by hand rather than being auto generated.

Perhaps @cammellos can assist more since he seems to have some experience with this file.
Maybe @qfrank as well.
Would love to see if we can add some debug statements in this cpp file or in the integration test mechanism itself to figure out why its failing this way and only on MacOS.

from status-mobile.

siddarthkay avatar siddarthkay commented on June 13, 2024

aha

"MACOSX_DEPLOYMENT_TARGET": "10.7"

could be interesting

from status-mobile.

siddarthkay avatar siddarthkay commented on June 13, 2024

As per golang 1.20 changelog : https://go.dev/doc/go1.20#darwin

Go 1.20 is the last release that will run on macOS 10.13 High Sierra or 10.14 Mojave. Go 1.21 will require macOS 10.15 Catalina or later.

from status-mobile.

siddarthkay avatar siddarthkay commented on June 13, 2024

I tried this change in status-mobile/binding.gyp

diff --git a/binding.gyp b/binding.gyp
index f161b3299..a0419d0ba 100644
--- a/binding.gyp
+++ b/binding.gyp
@@ -8,9 +8,6 @@
     "sources": [
       "./modules/react-native-status/nodejs/status.cpp"
     ],
-    "xcode_settings": {
-      "MACOSX_DEPLOYMENT_TARGET": "10.7"
-    },
     "libraries": [
       "<!(pwd)/result/libstatus.a"
     ],
@@ -21,7 +18,13 @@
           "-framework CoreFoundation",
           "-framework CoreServices",
           "-framework Security"
-        ]
+        ],
+        "xcode_settings": {
+           "GCC_ENABLE_CPP_EXCEPTIONS": "YES",
+           "GCC_ENABLE_CPP_RTTI": "YES",
+           "MACOSX_DEPLOYMENT_TARGET": "11.0",
+           "CLANG_CXX_LANGUAGE_STANDARD": "c++20"
+        },
       }]
     ]
   }, {

but the error is still reproducible and I do not get any additional information on the exception.

from status-mobile.

qfrank avatar qfrank commented on June 13, 2024

it could be possible that this file was later on modified by hand rather than being auto generated.

well guessed, I just noticed that comment "DO NOT EDIT:..." , have you tried re-generate? @siddarthkay

from status-mobile.

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.