Software Archive
Read-only legacy content
17061 Discussions

Illegal invocation error

Davis__Andrew
Beginner
1,016 Views

When attempting to change a variable using the plugin manager, I am getting an 'Illegal Invocation' error.

I also receive the same error when attempting to remove the plugin using the plugin manager.

What are your suggestions?

Thank you

Andy

0 Kudos
13 Replies
Jerroyd_M_Intel
Employee
1,016 Views

What version of the Intel XDK are you using?

0 Kudos
Davis__Andrew
Beginner
1,016 Views

Hi Jerroyd - I am using version 3759

0 Kudos
Jerroyd_M_Intel
Employee
1,016 Views

Which plugin are you trying to use?

Which operating system are you running on? Mac? Windows? Ubuntu?

0 Kudos
Davis__Andrew
Beginner
1,016 Views

I see this illegal invocation error message when running a simulation for the first time.  It happens once and then the simulation will work as expected.

Re: Plugins - 

This error window first appeared for me on the cordova-plugin-calendar (both changing a variable or trying to delete the plugin).  Since your last reply, I also tried to change a variable on cordova-plugin-media-capture and received the same error.

Re: Operating System -

I am using MacOS Sierra version 10.12.1.  

Previous to version 3759 I was able to put the Intel XDK in my dock and start from there.  Since 3759, after shutdown and restart of my MacBook Pro, the Intel XDK icon has a '?' over it and I can then only open it from the Finder view.

0 Kudos
Shai_D_
Beginner
1,016 Views

i just upgraded to the newest version and get the same message

Version 3759

 

also on macos sierra

the xdk moved from the application folder to applications/intelxdk folder

0 Kudos
PaulF_IntelCorp
Employee
1,016 Views

Davis, Andrew wrote:

This error window first appeared for me on the cordova-plugin-calendar (both changing a variable or trying to delete the plugin).  Since your last reply, I also tried to change a variable on cordova-plugin-media-capture and received the same error.

What do you mean by "changing a variable"? There are no variables associated with either of those plugins. If I install either one of them I do not get prompted for any plugin variables, and I do not find any plugin variables inside the plugin.xml files.

Please clarify what you mean by "changing a variable."

0 Kudos
Davis__Andrew
Beginner
1,016 Views

Hi Paul - I've attached some images to help you understand what I mean.

Image 00 - Detail drop down view from plugin manager of cordova-plugin-calendar.  From this interface I clicked 'Change version or variables'.

Image 01 - This is the interface I am referring to changing a plugin variable.  In this case, I am trying to modify the variable 'CALENDAR_USAGE_DESCRIPTION'.

Image 02 - I added a value to 'CALENDAR_USAGE_DESCRIPTION' and clicked OK.

Image 03 - Illegal invocation error.

I see this same behavior with the other plugins (like cordova-plugin-media-capture and others).  I also get the illegal invocation error when I try removing a plugin from my project.

I did not experience this behavior prior to release and update to 3759.

Let me know if you need more detail or additional screenshots.

 

0 Kudos
Davis__Andrew
Beginner
1,016 Views

Hi Paul - I've replied to your private message.  Can you confirm that you have received it?

Thank you 

0 Kudos
PaulF_IntelCorp
Employee
1,016 Views

Andrew -- I'm not quite clear on what is going on, but, as far as I can tell, the problem is actually due to the phonegap-plugin-push plugin, not the calendar plugin.

  • I imported your project
  • selected calendar plugin change variables option
  • added a string to the calendar variable
  • clicked "okay" and the XDK immediately asked me to provide the SENDER_ID parameter for phonegap-plugin-push
  • was surprised to see that, because I did not see that plugin in the list of plugins on my plugin management page
  • provided a bogus SENDER_ID parameter
  • checked the calendar plugin parameter and it had not been updated
  • tried to set the calendar plugin parameter again, and this time it worked

However, in my imported project there is no phonegap-plugin-push plugin present, it appears to have been stripped by the XDK when the import happened, because it is present in the ZIP that you gave me and it is referenced in the project files you gave me. That plugin has a gradle file which cannot be used by our build system, but it appears that you have modified the plugin.xml to remove the reference to that gradle file, so it should work.

My suspicion is the "open project" process I was using does not handle importing a plugin that has an unsatisfied variable request and that somehow that prevented the push plugin from being properly added to my copy of your project (in fact, deleted). However, it appears to have not fully cleaned up after itself, causing the weird behavior I experienced.

My guess is to try the following:

  • set the variable in the push plugin, first, using the "change versions/variables" process
  • if that works, then do the same for the calendar plugin

If the above fails, try the following:

  • remove the push plugin from your project
  • set the variable for the calendar plugin
  • add back the push plugin (which you have to import locally to get the properly modified version)
  • set the variable in the push plugin

I've attached the dialog that popped up immediately after I tried to set the calendar variable the first time:

Screen Shot 2016-12-21 at 17.58.26 .png

After providing a bogus value it was happy and I was then able to try and set the calendar variable a second time, which worked. Oddly, there was no push plugin in my project, so I'm not sure what caused this prompt.

0 Kudos
Davis__Andrew
Beginner
1,016 Views

Thanks for the detailed reply.  I will try this out after the holiday season and let you know.

Happy Holidays to you and everyone at Intel.  The XDK is a great product and we are happy to use it.

0 Kudos
Danish_K_
Beginner
1,016 Views

i am using mac sierra version 10.12.2 

and xdk version 3759.

I am not able remove or add any plugin neither i am able to simulate or build an app. I just updated xdk last night, yesterday it was working fine.

 

0 Kudos
Davis__Andrew
Beginner
1,016 Views

We have tried the resolution presented by Paul F. on 12/21/2016 but are still getting the same issue as before.

We tested our project on a PC running 3759 and there are no illegal invocation errors. 

0 Kudos
PaulF_IntelCorp
Employee
1,016 Views

Andrew -- if you could provide an xdk.log file it would help. See this master thread > https://software.intel.com/en-us/forums/intel-xdk/topic/707314 < we are unable to reproduce this and, thus, need detailed info from users to resolve it.

0 Kudos
Reply