Could not deploy to bb 10.2 and got a message saying "[ERROR]Error initializing Cordova: Extension Device not found". It is a brand new app created by using create new worklight project.
Tried many times. No idea what is wrong. Please help.
I tried to build my hybrid app for bb10. I got warning in console saying
[WARN] Failed to find feature with id: Battery
[WARN] Failed to find feature with id: Camera
[WARN] Failed to find feature with id: com.blackberry.utils
[WARN] Failed to find feature with id: org.apache.cordova.blackberry10.pimlib
[WARN] Failed to find feature with id: Contacts
[WARN] Failed to find feature with id: Device
I actually got warnings for most feature i got.
In my config.xml file, i got:
<!-- Start: Features -->
<!-- Cordova API -->
<feature id="Battery" name="Battery" value="Battery"/>
<feature id="Camera" name="Camera" value="Camera"/>
<feature id="com.blackberry.utils" name="com.blackberry.utils" value="com.blackberry.utils"/>
<feature id="org.apache.cordova.blackberry10.pimlib" name="org.apache.cordova.blackberry10.pimlib"
value="org.apache.cordova.blackberry10.pimlib"/>
<feature id="Contacts" name="Contacts" value="Contacts"/>
<feature id="Device" name="Device" value="Device"/>
I do not know why I got those warning. I asked people and it seems to be normal to get above messages. However, when I launch the bb10 app, I got a javascript alert message saying: "[ERROR]Error initializing Cordova: Extension Device not found".
I am building the project using worklight 6.1. My blackberry version is 10.2. Webworks SDK is the latest 1 point something from website. Steps to build exactly:
- Inside worklight, I chose to build for bb10 environment. Inside app folder/blackberry10 -> Run As -> Build for Blackberry 10 Environment.
- Then in the console, I go the bb10 sdk: use bbwp -o
- Then in the console, I sign the bar file.
- Then I deploy the file to device using BB10 App Manager.
Anyone knows what might be wrong? Thanks in advance.