getsentry / sentry-cordova

The official Sentry SDK for Cordova
https://sentry.io/
MIT License
68 stars 53 forks source link

Unable to remove the plugin !! #85

Closed seme1 closed 2 years ago

seme1 commented 6 years ago

I've wasted over two hours attempting to remove the plugin from my Android project with no success. The project is hosted on a Windows 10 machine. There also seems to be a hook running every time I attempt to remove the plugin.

`C:\project>cordova plugin rm sentry-cordova --save --froce
Sentry: running before_plugin_rm - set SENTRY_SKIP_WIZARD=true to skip this
no URL provided, fallback to https://sentry.io/
Running Sentry Wizard...
version: 0.10.3 | sentry-cli version: 1.35.5

😢  Successfully removed Sentry from your project 😢

C:\project>cordova plugin ls
cordova-plugin-x-socialsharing 5.4.1 "SocialSharing"
cordova-plugin-zip 3.1.0 "cordova-plugin-zip"
cordova.plugins.diagnostic 4.0.8 "Diagnostic"
es6-promise-plugin 4.2.2 "Promise"
onesignal-cordova-plugin 2.2.5 "OneSignal Push Notifications"
sentry-cordova 0.12.3 "Sentry"

C:\project>cordova platform -v
8.0.0

C:\project>cordova platform version android
Installed platforms:
  android 6.3.0
HazAT commented 6 years ago

can you try this: SENTRY_SKIP_WIZARD=true cordova plugin rm sentry-cordova --save --force

neilbo commented 5 years ago

I have the same issue running the below command does not solve the issue SENTRY_SKIP_WIZARD=true cordova plugin rm sentry-cordova --save --force

neilbo commented 5 years ago

For my Ionic 3 project:

  1. Make sure you completely shutdown XCode / Android Studio

  2. Remove the plugin: ionic cordova plugin rm sentry-cordova

  3. Remove the platforms: ionic cordova platform rm android ionic cordova platform rm ios ionic cordova platform rm browser

if that failed then: I had to go the plugins folder,

  1. delete the sentry-cordova directory,
  2. files remove all references to sentry-cordova in the:
    • android.json
    • browser.json
    • fetch.json
    • ios.json
jamesdixon commented 5 years ago

I basically had to blow everything away (platforms, plugins, node_modules) to get this thing removed. Terrible uninstall process... 👎

mgrubinger commented 5 years ago

+1 cordova plugin rm sentry-cordova won't actually remove the plugin :(

boynet commented 5 years ago

+1? for me I get "Using "requireCordovaModule" to load non-cordova module "fs" is not supported. Instead, add this module to your dependencies and use regular "require" to load it."

miladmeidanshahi commented 5 years ago

the same issue still I have problem

richardshergold commented 5 years ago

We use raven.js in our Ionic project so I was looking to upgrade to the Cordova Plugin but if issues like this (over a year old) are still open does that suggest I should wait? I don't want to add a plugin that (from the evidence here) is difficult to remove. Is this still an issue?

PowerMogli commented 5 years ago

We still have the same problems as mentioned by @boynet

+1? for me I get "Using "requireCordovaModule" to load non-cordova module "fs" is not supported. Instead, add this module to your dependencies and use regular "require" to load it."

dhandarbeit-tk commented 5 years ago

This is disgusting. I couldnt get the package running in development so i tried to remove it. Obviously sentry uses a couple of techniques that are not standard for the cordova boilerplate. But this is the most annoying issue. Please fix this as soon as possible.

HazAT commented 5 years ago

Hey sorry about the issue this is not intended if you are still running into: "Using "requireCordovaModule" to load non-cordova module "fs" is not supported. This has been fixed in march already: (after version > 0.14) https://github.com/getsentry/sentry-cordova/commit/8e5eb67b22d6dfc0996d9f9c9ac7efb70ce93866#diff-c7f37af3816a5a9970457d017658c9f5

Please change the line in your plugin folder to just require instead of requireCordovaModule. After that removing the plugin like SENTRY_SKIP_WIZARD=true cordova plugin rm sentry-cordova has to work.

boost-app commented 5 years ago

Still having the same problem when uninstalling the plugin. References and files remain cluttered all over the app (despite the fact, that i couldn't get it to run).

I switched to the browser version but the remains of the cordova plugin kept screwing my build process...

sebj54 commented 4 years ago

I struggled with this plugin but after reading a few docs, I made it work!

Add a .env at the root of your project with this content:

SENTRY_SKIP_WIZARD=true

Try deleting again!

slothentic commented 4 years ago

ENTRY_SKIP_WIZARD=true cordova plugin rm sentry-cordova

This does not work. Super disappointed this plugin is wasting my time by referencing a broken plugin.

Do not install verison sentry-cordova@0.12.3 as their documentation tells you to, this version will screw your cordova install like mine is.

Thanks for wasting my time.

rastilin commented 4 years ago

I can confirm that...

cordova plugin add sentry-cordova

..does work, though it's probably a good idea to update the documentation.

Anuj-logiciel commented 4 years ago

Anyone found proper way of it?

github-actions[bot] commented 2 years ago

This issue has gone three weeks without activity. In another week, I will close it.

But! If you comment or otherwise update it, I will reset the clock, and if you label it Status: Backlog or Status: In Progress, I will leave it alone ... forever!


"A weed is but an unloved flower." ― Ella Wheeler Wilcox 🥀