Summary:
Device Id needs to be the same for multiple apps on the same device. This isn't true for this attribute, which is specific to the vendor of the app.
Apple has deprecated the API that gives you the device Id, so we can't discover it in the SDK alone.
However, this isn't a problem because we have a similar issue on android, and now Flipper desktop gives each device it's own deviceId during certificate exchange.
Removing this incorrect one so it's never used as a fallback, which would cause flipper to think the app is on a different device than the one it's running on.
Reviewed By: danielbuechele
Differential Revision: D9700552
fbshipit-source-id: 5467f6cb7d1f941af9df09fc6a03dbe34e6575e5
Summary:
Sonar was trying to convert folly dynamics containing NaN and Inf to json.
Folly doesn't allow this so we have to get rid of them before converting.
See https://fb.facebook.com/groups/230455004101832/permalink/483173632163300/ for more context.
`grep -r convertFollyDynamicToId fbsource/xplat/sonar` now returns results which all have `true` in the second parameter slot.
Reviewed By: danielbuechele
Differential Revision: D9570364
fbshipit-source-id: bf28b03e54b4987399e028a491d82451a8267d97
Summary:
V1 ios diagnostics complete.
This change adds a new section to the ios diagnostics screen that shows the current state of each step required to get sonar working.
The logs (transitions between states) are displayed below it.
SonarClient.mm is technically involved in the UI, by converting enums to emojis, I don't like this
but didn't get obj-C working with C enums so have left it like this for now.
Reviewed By: priteshrnandgaonkar
Differential Revision: D9378212
fbshipit-source-id: 091ce00e898a8038c680555123640b90d753fc09
Summary:
Some apps have a default background color, for example black, making the diagnostic screen fully black.
Fix this by making sure the bg is always white so the text is readable.
Reviewed By: passy
Differential Revision: D9400682
fbshipit-source-id: a45744f833cb7fe5ca7db4dcdacc09f304670032
Summary:
Adds an extremely barebones in-app screen for showing sonar diagnostics.
The UI is laughable, but it's wired up. Leaving proper design to a later commit.
Like in the android case, state is currently passed as a string, but will become something much more structured after this is in place.
Reviewed By: priteshrnandgaonkar
Differential Revision: D9218766
fbshipit-source-id: 4889ed79b928056a67b1e8cb8a40a9bd52e084f1
Summary:
This diff only moves the core of sonarkit to the xplat.
- This diff uses `fb_xplat_cxx_library` as a buck rule in xplat as it is the recommended way
- Updated few imports in the files which were not compiling with new buck function
- Due to the new way of import the OSS would break, so fixed it by changing the `podspec` file
Reviewed By: passy
Differential Revision: D8937414
fbshipit-source-id: 6e12cd049bedb496e7a6820be85b2535e70ba09b
Summary:
Fixing T31692652.
I couldn't reproduce this on my local tests - (tried non-utf chars, deleted memory, onverted vectors that are erased).
My guess - an illegal string cannot be converted to NSSString and thus we return nil when the folly::dynamic type is STRING.
See task for additional details.
Reviewed By: nubbel
Differential Revision: D8952714
fbshipit-source-id: c87af523efca1b96a4cf3d5d26fa5c16ed5cd773
Summary: The receiving callbacks are executed from a thread that doesn't have an autorelease pool. That results in autoreleased objects leaking
Reviewed By: schaitoff
Differential Revision: D8889915
fbshipit-source-id: 07e9129954e6f9afea56473b590125c63ecd7092
Summary:
We currently give sonar one event base from java / obj-c code to use for scheduling tasks.
This causes a problem, because we schedule reconnect tasks on the event base, and then these tasks interact with rsocket which schedules it's own tasks.
The problem is that we're passing rsocket the same event base. So the reconnect code executes and blocks waiting for rsocket to connect.
But rsocket can never connect because it never executes because that thread is blocked, so we get deadlock.
Fixing it by giving both processes their own event base / thread.
Reviewed By: danielbuechele
Differential Revision: D8748355
fbshipit-source-id: b0ad2172087f0103180677438f427c831db7f42c
Summary:
We currently give sonar one event base from java / obj-c code to use for scheduling tasks.
This causes a problem, because we schedule reconnect tasks on the event base, and then these tasks interact with rsocket which schedules it's own tasks.
The problem is that we're passing rsocket the same event base. So the reconnect code executes and blocks waiting for rsocket to connect.
But rsocket can never connect because it never executes because that thread is blocked, so we get deadlock.
This is the first step which just changes the interface to pass two event bases.
The consumers will be changed to pass in different threads next.
Reviewed By: danielbuechele
Differential Revision: D8748350
fbshipit-source-id: 481d6f23644f28fd0f1c786252605287019c999c
Summary:
There was an issue with syncing our internal files to github. A change was made in the utils that wasn't synced out, despite the sonar code using the new API.
This brings the util update to github, while I fix the syncing issue. After that there will be a single source of truth so no more sync issues like this can occur.
Reviewed By: priteshrnandgaonkar
Differential Revision: D8541128
fbshipit-source-id: d8509b65035569c4ee9707e5d7eab99fa325da88