Build.json Error: Package application for Android - visual-studio-cordova

Using Visual Studio RTM 2015 Blank Cordova (5.1.1) TypeScript project to test packaging applications for Android.
Following these instructions: https://github.com/Microsoft/cordova-docs/tree/master/tutorial-package-publish#android
Created the build.json and keystore.
When I publish (Release > Android > Device), I get the following error:
Reading build config file: D:\erase\BlankCordovaApp9\build.json
Command finished with error code 1: cmd /s /c "D:\erase\BlankCordovaApp9\platforms\android\cordova\build.bat --debug --buildConfig=D:\erase\BlankCordovaApp9\build.json"
ERROR building one of the platforms : error : cmd: Command failed with exit code 1
Are the instructions still accurate for 2015 RTM? Using the instructions I get Misssing a comma after an object member when using the suggested format in build.json.
Win 8.1

Related

Chutzpah 4.4.11 failing with exit code 2 when running with vstest

vstest.console.exe 16.10 works with Chutzpah 4.2.3. But upgraded to Chutzpah 4.4.11, and it fails with exit code of 2. chutzpah.console.exe also works by itself in 4.4.11, so I'm not sure if I'm missing something in the vstest command line. (I get the same results with vstest.console.exe when running from an Azure DevOps pipeline.)
Any suggestions?
> "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\IDE\Extensions\TestPlatform\vstest.console.exe"
"[path-to-test-file]\index-tests.js"
/TestAdapterPath:"C:\Users\TFSBuild\.nuget\packages\chutzpah\4.4.11\tools"
Microsoft (R) Test Execution Command Line Tool Version 16.10.0
Copyright (c) Microsoft Corporation. All rights reserved.
Starting test execution, please wait...
A total of 1 test files matched the specified pattern.
Error: Unknown error occurred when executing test file. Received exit code of 2
While Running:[path-to-test-file]\index-tests.js
No test is available in [path-to-test-file]\index-tests.js.
Make sure that test discoverer & executors are registered and platform & framework version settings are appropriate and try again.
Test Run Failed.
Found the solution. I'm using Engine: Chrome, and the newer version of Chutzpah was failing to find chrome.exe. Defining the path to the exe in Chutzpah.json resolved the issue.
"Engine": "Chrome",
"EngineOptions": {
"ChromeBrowserPath": "C:\\Program Files\\Google\\Chrome\\Application\\chrome.exe"
}

Spring Starter with with Dependencies 'Spring Web' for Java 15 reports 'Failed to execute'

i downloadet
from
https://start.spring.io/
with Dependencies
Spring Web and
choosen Java 15
run mvn install
and got this error:
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.8.1:compile (default-compile) on project java15dependnciesWeb: Fatal error compiling: error: invalid target release: 15 -> [Help 1]`
i surprized. I thought it should be able to be installed out of the box. I using Ubuntu.
Something similar errors:
This sound a bit like this error:
Failed to execute goal org.springframework.boot:spring-boot-maven-plugin:2.2.2.RELEASE:run
But this solution doesn't work for me:
https://stackoverflow.com/a/62742688/2891692
Tag name: version Description : The version of the parent project to inherit. Version : 4.0.0

MSBuild Error: Reading build config file results in cordova-build error : TypeError: undefined is not a function -Android

I ran in to this problem while performing Apache cordova build through visual studio-2015 i get this following error.
VS2015;
npm -v - 5.7.1
Node -v 8.8.0
Cordova tools 6.5.0
Android project created with cordova-android#6.4.0
Last few lines of error log
> Prepared android project successfully
> No scripts found for hook "after_prepare".
> Checking config.xml for saved plugins that haven't been added to the project
> ------ Copied C:\Project\Mobile\bin\Android\Debug\VSBuildInfo.xml to platforms\android\assets\www\VSBuildInfo.xml
> ------ Building platform: android
> Debug
> ------ Build configuration options: --debug
> No scripts found for hook "before_compile".
> ANDROID_HOME=C:\Users\<username>\AppData\Local\Android\sdk
> JAVA_HOME=C:\Program Files\Java\jdk1.8.0_144
> Reading build config file: C:\Project\Mobile\build.json
> MSBUILD : cordova-build error : TypeError: undefined is not a function
> TypeError undefined is not a function
Any help is appreciated.
I think is node version related issue.
After a few try to build with VS Cordova Tools and latest version of Cordova, i have encountred some issues on latest node versions.
Try to downgrade node to Node 4.8.7 LTS
https://nodejs.org/en/blog/release/v4.8.7/

Error to build a signed apk

i'm trying to build an signed apk with visual studio /Cordova template. But i'm receiving this error: ERROR building one of the platforms 1
And : Error MDAVSCLI 1
I´m following this tutorial:
http://taco.visualstudio.com/en-us/docs/tutorial-package-publish-readme/
and my Keystore is like image bellow:
-package-resources:
[aapt] Creating full resource package...
-package:
[apkbuilder] Current build type is different than previous build: forced apkbuilder run.
[apkbuilder] Creating MainActivity-release-unsigned.apk for release...
-post-package:
-release-prompt-for-password:
-release-nosign:
-release-sign:
[echo] Signing final apk...
BUILD FAILED
C:\Users\Leo\AppData\Local\Android\sdk1\tools\ant\build.xml:1135: The following error occurred while executing this line:
C:\Users\Leo\AppData\Local\Android\sdk1\tools\ant\build.xml:1147: C:\Users\Leo\Desktop\Mobile\Mobile\platforms\android\"my-release-key.Keystore" (The file name syntax, the name of the directory or volume label incorrect)
Total time: 52 seconds
Picked up _JAVA_OPTIONS: -Xmx512M
C:\Users\Leo\Desktop\Mobile\Mobile\platforms\android\cordova\node_modules\q\q.js:126
throw e;
^
Error code 1 for command: cmd with args: /s /c "ant release -f C:\Users\Leo\Desktop\Mobile\Mobile\platforms\android\build.xml -Dout.dir=ant-build -Dgen.absolute.dir=ant-gen"
Command finished with error code 1: C:\Users\Leo\Desktop\Mobile\Mobile\platforms\android\cordova\build.bat --release
ERROR building one of the platforms : error : C:\Users\Leo\Desktop\Mobile\Mobile\platforms\android\cordova\build.bat: Command failed with exit code 1
You may not have the required environment or OS to build this project
MDAVSCLI : error : C:\Users\Leo\Desktop\Mobile\Mooobile\platforms\android\c
I've found a way : removing the quotes in my ant.properties i can build.

v-play installation - Cant deploy on desktop and device

I’ve just installed v-play but when i compile to desktop i get error :-1: error: cannot find -lGL and exits.
Then if i compile to android it will compile and install but the it never successfully opens the app and it exits on deployment.
These are the warnings i get :
Warnings while parsing QML type information of /home/theguy/V-Play/5.5/android_armv5/qml/QtCanvas3D:
/home/theguy/V-Play/5.5/android_armv5/qml/QtCanvas3D/plugins.qmltypes:1:24: Reading only version 1.1 parts.
/home/theguy/V-Play/5.5/android_armv5/qml/QtCanvas3D/plugins.qmltypes:10:5: Expected only Component and ModuleApi object definitions.
Warnings while parsing QML type information of /home/theguy/V-Play/5.5/gcc_64/qml/QtWebSockets:
/home/theguy/V-Play/5.5/gcc_64/qml/QtWebSockets/plugins.qmltypes:1:24: Reading only version 1.1 parts.
/home/theguy/V-Play/5.5/gcc_64/qml/QtWebSockets/plugins.qmltypes:10:5: Expected only Component and ModuleApi object definitions.
Warnings while parsing QML type information of /home/theguy/V-Play/5.5/gcc_64/qml/QtCanvas3D:
/home/theguy/V-Play/5.5/gcc_64/qml/QtCanvas3D/plugins.qmltypes:1:24: Reading only version 1.1 parts.
/home/theguy/V-Play/5.5/gcc_64/qml/QtCanvas3D/plugins.qmltypes:10:5: Expected only Component and ModuleApi object definitions.
And these are the compile issues I get:
15:03:42: Packaging error: Command “/home/theguy/Android/Sdk/platform-tools/adb -s 9cc172fdedea pull /system/bin/sh: readlink: not found /home/theguy/Desktop/Projects/v-play/ConverseLanguages/build-ConverseLanguages-Android_for_armeabi_GCC_4_9_Qt_5_5_0-Release/app_process” failed.Exit code: 1
15:03:42: Package deploy: Failed to pull “/system/bin/sh: readlink: not found” to “/home/theguy/Desktop/Projects/v-play/ConverseLanguages/build-ConverseLanguages-Android_for_armeabi_GCC_4_9_Qt_5_5_0-Release/app_process”.
15:03:42: Package deploy: Running command “/home/theguy/Android/Sdk/platform-tools/adb -s 9cc172fdedea pull /system/lib/libc.so /home/theguy/Desktop/Projects/v-play/ConverseLanguages/build-ConverseLanguages-Android_for_armeabi_GCC_4_9_Qt_5_5_0-Release/libc.so”.
Error while building/deploying project ConverseLanguages (kit: Android for armeabi (GCC 4.9, Qt 5.5.0))
When executing step “Deploy to Android device”
please see here for a reply: https://v-play.net/developers/forums/t/installation-problem-error-cannot-find-lgl/
Cheers, Chris

Resources