You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cordova.apache.org by "Li, Jonathan" <jo...@sap.com> on 2014/03/12 15:46:49 UTC

Explicitly added plugin gets deleted as dependent of other plugin

When testing with cordova 3.4.0-0.1.3, if a plugin A is a dependent of plugin B, then running the following command will automatically delete plugin B from the project

cordova plugin add PluginB
cordova plugin add pluginA
cordova plugin rm pluginB

As pluginA is explicitly added into the project, unless it is explicated removed from project by using "cordova plugin rm pluginA" command, then it should not be deleted from the project when deleting pluginB.

The test is done on iOS platform.

Please let me know if this is a known issue, or whether I need to submit a bug for it

Thanks
Jonathan



Re: Explicitly added plugin gets deleted as dependent of other plugin

Posted by Michal Mocny <mm...@chromium.org>.
Okay thats a bug for sure then, I misunderstood the issue because the
original email had a misleading description (I think the terms "plugin A"
and "plugin B" got swapped a few places).


On Wed, Mar 12, 2014 at 1:57 PM, Shazron <sh...@gmail.com> wrote:

> Thinking from the user's  point of view... they might need File to do some
> caching stuff, not explicitly part of a plugin, just some js calls. Then
> they add FileTransfer thinking they might use it, then remove it later.
> Their existing File code is now broken. I thought we did some reference
> counting for this stuff somehow.
>
>
> On Wed, Mar 12, 2014 at 10:41 AM, Michal Mocny <mm...@chromium.org>
> wrote:
>
> > If its dependant is removed, it will stop working anyway -- so why is it
> a
> > bug to remove it?
> >
> > I think we should warn when this happens (if it happens silently, thats
> bad
> > experience), or better yet prompt for input to confirm removal, but I'm
> not
> > sure what it would mean to just leave pluginA installed when its
> dependant
> > is removed, regardless of if each plugin was explicitly installed.
> >
> > -Michal
> >
> >
> > On Wed, Mar 12, 2014 at 12:58 PM, Shazron <sh...@gmail.com> wrote:
> >
> > > Just tested it with File and File-Transfer - looks like a bug. Please
> > file
> > > it, thanks!
> > >
> > >
> > > On Wed, Mar 12, 2014 at 7:46 AM, Li, Jonathan <jo...@sap.com>
> > wrote:
> > >
> > > > When testing with cordova 3.4.0-0.1.3, if a plugin A is a dependent
> of
> > > > plugin B, then running the following command will automatically
> delete
> > > > plugin B from the project
> > > >
> > > > cordova plugin add PluginB
> > > > cordova plugin add pluginA
> > > > cordova plugin rm pluginB
> > > >
> > > > As pluginA is explicitly added into the project, unless it is
> > explicated
> > > > removed from project by using "cordova plugin rm pluginA" command,
> then
> > > it
> > > > should not be deleted from the project when deleting pluginB.
> > > >
> > > > The test is done on iOS platform.
> > > >
> > > > Please let me know if this is a known issue, or whether I need to
> > submit
> > > a
> > > > bug for it
> > > >
> > > > Thanks
> > > > Jonathan
> > > >
> > > >
> > > >
> > >
> >
>

Re: Explicitly added plugin gets deleted as dependent of other plugin

Posted by Shazron <sh...@gmail.com>.
Thinking from the user's  point of view... they might need File to do some
caching stuff, not explicitly part of a plugin, just some js calls. Then
they add FileTransfer thinking they might use it, then remove it later.
Their existing File code is now broken. I thought we did some reference
counting for this stuff somehow.


On Wed, Mar 12, 2014 at 10:41 AM, Michal Mocny <mm...@chromium.org> wrote:

> If its dependant is removed, it will stop working anyway -- so why is it a
> bug to remove it?
>
> I think we should warn when this happens (if it happens silently, thats bad
> experience), or better yet prompt for input to confirm removal, but I'm not
> sure what it would mean to just leave pluginA installed when its dependant
> is removed, regardless of if each plugin was explicitly installed.
>
> -Michal
>
>
> On Wed, Mar 12, 2014 at 12:58 PM, Shazron <sh...@gmail.com> wrote:
>
> > Just tested it with File and File-Transfer - looks like a bug. Please
> file
> > it, thanks!
> >
> >
> > On Wed, Mar 12, 2014 at 7:46 AM, Li, Jonathan <jo...@sap.com>
> wrote:
> >
> > > When testing with cordova 3.4.0-0.1.3, if a plugin A is a dependent of
> > > plugin B, then running the following command will automatically delete
> > > plugin B from the project
> > >
> > > cordova plugin add PluginB
> > > cordova plugin add pluginA
> > > cordova plugin rm pluginB
> > >
> > > As pluginA is explicitly added into the project, unless it is
> explicated
> > > removed from project by using "cordova plugin rm pluginA" command, then
> > it
> > > should not be deleted from the project when deleting pluginB.
> > >
> > > The test is done on iOS platform.
> > >
> > > Please let me know if this is a known issue, or whether I need to
> submit
> > a
> > > bug for it
> > >
> > > Thanks
> > > Jonathan
> > >
> > >
> > >
> >
>

Re: Explicitly added plugin gets deleted as dependent of other plugin

Posted by "Li, Jonathan" <jo...@sap.com>.
Only the parent pluginB (not the dependent pluginA) is removed.
However, the dependent plugin (PluginA) also gets removed along with
pluginB, even if pluginA has been explicitly added into the project.

Jonathan

On 3/12/14 1:41 PM, "Michal Mocny" <mm...@chromium.org> wrote:

>If its dependant is removed, it will stop working anyway -- so why is it a
>bug to remove it?
>
>I think we should warn when this happens (if it happens silently, thats
>bad
>experience), or better yet prompt for input to confirm removal, but I'm
>not
>sure what it would mean to just leave pluginA installed when its dependant
>is removed, regardless of if each plugin was explicitly installed.
>
>-Michal
>
>
>On Wed, Mar 12, 2014 at 12:58 PM, Shazron <sh...@gmail.com> wrote:
>
>> Just tested it with File and File-Transfer - looks like a bug. Please
>>file
>> it, thanks!
>>
>>
>> On Wed, Mar 12, 2014 at 7:46 AM, Li, Jonathan <jo...@sap.com>
>>wrote:
>>
>> > When testing with cordova 3.4.0-0.1.3, if a plugin A is a dependent of
>> > plugin B, then running the following command will automatically delete
>> > plugin B from the project
>> >
>> > cordova plugin add PluginB
>> > cordova plugin add pluginA
>> > cordova plugin rm pluginB
>> >
>> > As pluginA is explicitly added into the project, unless it is
>>explicated
>> > removed from project by using "cordova plugin rm pluginA" command,
>>then
>> it
>> > should not be deleted from the project when deleting pluginB.
>> >
>> > The test is done on iOS platform.
>> >
>> > Please let me know if this is a known issue, or whether I need to
>>submit
>> a
>> > bug for it
>> >
>> > Thanks
>> > Jonathan
>> >
>> >
>> >
>>


Re: Explicitly added plugin gets deleted as dependent of other plugin

Posted by Michal Mocny <mm...@chromium.org>.
If its dependant is removed, it will stop working anyway -- so why is it a
bug to remove it?

I think we should warn when this happens (if it happens silently, thats bad
experience), or better yet prompt for input to confirm removal, but I'm not
sure what it would mean to just leave pluginA installed when its dependant
is removed, regardless of if each plugin was explicitly installed.

-Michal


On Wed, Mar 12, 2014 at 12:58 PM, Shazron <sh...@gmail.com> wrote:

> Just tested it with File and File-Transfer - looks like a bug. Please file
> it, thanks!
>
>
> On Wed, Mar 12, 2014 at 7:46 AM, Li, Jonathan <jo...@sap.com> wrote:
>
> > When testing with cordova 3.4.0-0.1.3, if a plugin A is a dependent of
> > plugin B, then running the following command will automatically delete
> > plugin B from the project
> >
> > cordova plugin add PluginB
> > cordova plugin add pluginA
> > cordova plugin rm pluginB
> >
> > As pluginA is explicitly added into the project, unless it is explicated
> > removed from project by using "cordova plugin rm pluginA" command, then
> it
> > should not be deleted from the project when deleting pluginB.
> >
> > The test is done on iOS platform.
> >
> > Please let me know if this is a known issue, or whether I need to submit
> a
> > bug for it
> >
> > Thanks
> > Jonathan
> >
> >
> >
>

Re: Explicitly added plugin gets deleted as dependent of other plugin

Posted by "Li, Jonathan" <jo...@sap.com>.
Created.

https://issues.apache.org/jira/browse/CB-6237


On 3/12/14 12:58 PM, "Shazron" <sh...@gmail.com> wrote:

>Just tested it with File and File-Transfer - looks like a bug. Please file
>it, thanks!
>
>
>On Wed, Mar 12, 2014 at 7:46 AM, Li, Jonathan <jo...@sap.com> wrote:
>
>> When testing with cordova 3.4.0-0.1.3, if a plugin A is a dependent of
>> plugin B, then running the following command will automatically delete
>> plugin B from the project
>>
>> cordova plugin add PluginB
>> cordova plugin add pluginA
>> cordova plugin rm pluginB
>>
>> As pluginA is explicitly added into the project, unless it is explicated
>> removed from project by using "cordova plugin rm pluginA" command, then
>>it
>> should not be deleted from the project when deleting pluginB.
>>
>> The test is done on iOS platform.
>>
>> Please let me know if this is a known issue, or whether I need to
>>submit a
>> bug for it
>>
>> Thanks
>> Jonathan
>>
>>
>>


Re: Explicitly added plugin gets deleted as dependent of other plugin

Posted by Shazron <sh...@gmail.com>.
Just tested it with File and File-Transfer - looks like a bug. Please file
it, thanks!


On Wed, Mar 12, 2014 at 7:46 AM, Li, Jonathan <jo...@sap.com> wrote:

> When testing with cordova 3.4.0-0.1.3, if a plugin A is a dependent of
> plugin B, then running the following command will automatically delete
> plugin B from the project
>
> cordova plugin add PluginB
> cordova plugin add pluginA
> cordova plugin rm pluginB
>
> As pluginA is explicitly added into the project, unless it is explicated
> removed from project by using "cordova plugin rm pluginA" command, then it
> should not be deleted from the project when deleting pluginB.
>
> The test is done on iOS platform.
>
> Please let me know if this is a known issue, or whether I need to submit a
> bug for it
>
> Thanks
> Jonathan
>
>
>