thomasnordquist / MQTT-Explorer

An all-round MQTT client that provides a structured topic overview
https://mqtt-explorer.com
Other
3k stars 286 forks source link

Add option to disable app telemetry #52

Open thomasnordquist opened 5 years ago

thomasnordquist commented 5 years ago

App telemetry is used to automatically detect bugs and measure acceptance. One should be able to disable the telemetry.

See: https://github.com/thomasnordquist/MQTT-Explorer#telemetry

thomasnordquist commented 5 years ago

Moved example telemetry from readme:

{ system: { arch: 'x64', platform: 'darwin' },
  appVersion: '0.0.7',
  events: { HELLO_EVENT: [ 1547714886134 ] },
  now: 1547714886135,
  transactionId: '1767d251-f492-4f2c-aa62-88add3acc26b' }
{ errors:
   [ { time: 1547714887921,
       message: 'He\'s dead Jim!',
       stack:
        'Error: He\'s dead Jim!\n    at ./src/tracking.ts.exports.default (./mqtt-explorer/app/build/bundle.js:142765:11)\n    at new Promise (<anonymous>)\n    at Object../src/tracking.ts (./mqtt-explorer/app/build/bundle.js:142764:1)\n    at __webpack_require__ (./mqtt-explorer/app/build/bundle.js:20:30)\n    at Object../src/index.tsx (./mqtt-explorer/app/build/bundle.js:142618:1)\n    at __webpack_require__ (./mqtt-explorer/app/build/bundle.js:20:30)\n    at ../backend/node_modules/charenc/charenc.js.charenc.utf8.stringToBytes (./mqtt-explorer/app/build/bundle.js:84:18)\n    at ./mqtt-explorer/app/build/bundle.js:87:10' } ],
  now: 1547714887921,
  transactionId: '53bf9aac-e695-40cc-9a81-b1cf3398843d' }
GregoryEAllen commented 5 years ago

I attempted to run this on a machine that has no internet access. The application prints an error and then hangs. It appears related to this. This is an abridged version:

14:27:56.298 › Checking for update 14:27:56.424 › Error: Error: net::ERR_CONNECTION_REFUSED could not update due to error [Error: net::ERR_CONNECTION_REFUSED] { stack: 'Error: net::ERR_CONNECTION_REFUSED', message: 'net::ERR_CONNECTION_REFUSED', name: 'Error', source: 'main' } { Error: getaddrinfo ENOTFOUND app-telemetry.t7n.de at GetAddrInfoReqWrap.onlookup [as oncomplete] (dns.js:58:26) errno: 'ENOTFOUND', code: 'ENOTFOUND', syscall: 'getaddrinfo', hostname: 'app-telemetry.t7n.de', request: Writable { _currentUrl: 'https://app-telemetry.t7n.de/app/9b0c8ca04a361eb8160d98c5' }, response: undefined }

thomasnordquist commented 5 years ago

Hello @GregoryEAllen this "error" is to be expected if there is no internet, but I am fairly certain it is not the reason for the crash.

Can you give me more details: which operating system, which software channel (microsoft store / portable exe / snap store / OSX app store / AppImage / AUR) ?

GregoryEAllen commented 5 years ago

AppImage on CentOS 7.5.1804

thomasnordquist commented 5 years ago

I tried to launch the app in a VM without a network card: I used this base image https://www.osboxes.org/centos/#centos-7-1804-info and it did start successfully (with a load of net::ERR_CONNECTION_REFUSED error messages). I am not entirely sure if I used the correct cent-os image.

Bildschirmfoto 2019-07-23 um 23 17 28

Is there anything special about your setup?

You could try executing export ELECTRON_ENABLE_LOGGING=true (in the same terminal session) before launching the AppImage file.

GregoryEAllen commented 5 years ago

I apologize for hijacking this issue. I thought it was related to the networking issue because that was the only output.

It runs fine on the desktop of my (normally headless) CentOS7 box. That's running the default GNOME3 on X11.

Where I was having trouble was with remote ssh to that machine. I was ssh'd in from a MacOS box with XQuartz (my normal method for using that normally headless box). Setting ELECTRON_ENABLE_LOGGING doesn't add any output.

I was running the Linux version instead of the Mac version because my internet-denied network doesn't have access to the Mac App Store. I later saw that you also provide a dmg. I'm running that and it's working fine.

I don't know why it's not working over remote ssh, but I also don't feel the need to investigate further. Again, I apologize for hijacking this issue with something unrelated. Maybe my comments should be deleted.

thomasnordquist commented 5 years ago

@GregoryEAllen no worries, I'm always happy to get error reports. It helps tremendously maintaining good software quality.

I just remove the whole conversation in a few minutes 😇

pintman commented 5 years ago

It would be great to have telemetry turned off by default or at least ask the user which option to choose. Having telemetry turned on by default may cause a GDPR violation in europe. Maybe you can reconsider the default behavior.

aniston commented 3 years ago

Hello @thomasnordquist , lovely APP, but as @pintman pointed out using Telemetry without users consent will go against the EU GDPR rules even if there is a clear mention that telemetry will be taken (although no mention if only in Error cases or even thru normal usage?).

So the question as the OP dated back end of Jan 2019, is this option implemented as of Nov 2020 ? might be better to keep it off as default and let users turn it on

1RandomDev commented 2 years ago

What MQTT Explorer has telemetry by default and there's no option to turn it off?! Would be great if someone would have told me that before I downloaded it.

epichub commented 1 year ago

the above readme link to #telemetry is not working - the docs does not cover how to turn it off..

aniston commented 1 year ago

the above readme link to #telemetry is not working - the docs does not cover how to turn it off..

@epichub , build it yourself from the source if you have nodejs on your machine, get the source and in src/registerCrashReporter.ts:

hth !