apache / cordova-windows Goto Github PK
View Code? Open in Web Editor NEW[DEPRECATED] Apache Cordova Windows
License: Apache License 2.0
[DEPRECATED] Apache Cordova Windows
License: Apache License 2.0
During testing on how to get Paramedic to run on Appveyor CI for Windows, so we can properly test the Windows parts of the plugins in CI, this code blocks running apps:
cordova-windows/template/cordova/lib/run.js
Lines 34 to 39 in b950b25
It was added back in 2015 by @muratsu with this commit: b34a5f1
The JIRA issue was https://issues.apache.org/jira/browse/CB-9097 which mentions that "cordova run
will fail for windows if invoked from admin prompt. Currently we will wait until ActivateApplication stage and fail afterwards." but unfortunately does not contain a sample of such an error.
(https://issues.apache.org/jira/browse/CB-10266 is a related JIRA issue, but only has the last bits of an error message - the end result being that ActivateApplication
doesn't work, but the cause is missing as well)
I manually tried disabling this check (see https://github.com/apache/cordova-windows/tree/janpio-admin), and surprisingly had no problem building, deploying and running a Cordova Windows app from an admin prompt.
Are you still around @muratsu and maybe remember why this was added?
Did Microsoft maybe change things around so it now works? Or am I maybe doing something different that makes this work?
@knight9999 You helped me debug similar problems in the past, could you maybe try my branch https://github.com/apache/cordova-windows/tree/janpio-admin and see if you can add that to a new Cordova project (cordova platform add https://github.com/apache/cordova-windows#janpio-admin
) and see if you can build and run the app in an elevated/admin prompt? That would be awesome.
If targetImg is null it blows up and fails the prepare action. it should just return.
By default a new project created with Cordova Windows has a missing splashscreen:
E:\Projects\throwaway
λ cordova create cordovaWindowsMissingSplash
Creating a new cordova project.
E:\Projects\throwaway
λ cd cordovaWindowsMissingSplash\
E:\Projects\throwaway\cordovaWindowsMissingSplash ([email protected])
λ cordova platform add https://github.com/apache/cordova-windows
Using cordova-fetch for https://github.com/apache/cordova-windows
Warning: using prerelease platform [email protected].
Use 'cordova platform add windows@latest' to add the latest published version instead.
Adding windows project...
Creating Cordova Windows Project:
Path: platforms\windows
Namespace: io.cordova.hellocordova
Name: HelloCordova
Windows project created with [email protected]
Plugin 'cordova-plugin-whitelist' found in config.xml... Migrating it to package.json
Discovered saved plugin "cordova-plugin-whitelist". Adding it to the project
Installing "cordova-plugin-whitelist" for windows
Adding cordova-plugin-whitelist to package.json
E:\Projects\throwaway\cordovaWindowsMissingSplash ([email protected])
λ cordova run windows
ENV var MSBUILDDIR is set C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin
Building project: E:\Projects\throwaway\cordovaWindowsMissingSplash\platforms\windows\CordovaApp.Windows10.jsproj
Configuration : debug
Platform : anycpu
Buildflags : /p:AppxBundle=Never
MSBuildTools : C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin
buildProject spawn: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\msbuild [
'E:\\Projects\\throwaway\\cordovaWindowsMissingSplash\\platforms\\windows\\CordovaApp.Windows10.jsproj',
'/clp:NoSummary;NoItemAndPropertyList;Verbosity=minimal',
'/nologo',
'/p:Configuration=debug',
'/p:Platform=anycpu',
'/p:AppxBundle=Never'
] { stdio: 'inherit' }
prebuild.js: Patching platform `10`
- Injected `base.js` reference to `/www/index.html`
- Removing /( *)(<script\s+(?:type="text\/javascript"\s+)?src="\/\/Microsoft.WinJS.2.0\/js\/base.js">\s*<\/script>)(\s*)/ from /www/index.html
- Removing /( *)(<script\s+(?:type="text\/javascript"\s+)?src="\/\/Microsoft.Phone.WinJS.2.1\/js\/base.js">\s*<\/script>)(\s*)/ from /www/index.html
CordovaApp.Windows10 -> E:\Projects\throwaway\cordovaWindowsMissingSplash\platforms\windows\AppPackages\CordovaApp.Windows10_1.0.0.0_anycpu_debug_Test\Cor
dovaApp.Windows10_1.0.0.0_anycpu_debug.appx
Deploying windows10 package to device:
E:\Projects\throwaway\cordovaWindowsMissingSplash\platforms\windows\AppPackages\CordovaApp.Windows10_1.0.0.0_anycpu_debug_Test\CordovaApp.Windows10_1.0.0.0_anycpu_debug.appx
Attempting to uninstall previous application version...
Attempting to install application...
Found package: E:\Projects\throwaway\cordovaWindowsMissingSplash\platforms\windows\AppPackages\CordovaApp.Windows10_1.0.0.0_anycpu_debug_Test\CordovaApp.Windows10_1.0.0.0_anycpu_debug.appx
Installing app...
Success: Your app was successfully installed.
Starting application...
ActivateApplication: io.cordova.hellocordova_h35559jr9hy9m!io.cordova.hellocordova
Hi,
I was suggested to open issue here [source] the issue i'm facing is that I can't make windows app and i get this error
ENV var MSBUILDDIR is set C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin
Building project: C:\laragon\www\ionic\WinApp\platforms\windows\CordovaApp.Windows10.jsproj
Configuration : debug
Platform : anycpu
Buildflags : /p:AppxBundle=Never
MSBuildTools : C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin
buildProject spawn: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\msbuild [ 'C:\\laragon\\www\\ionic\\WinApp\\platforms\\windows\\CordovaApp.Windows10.jsproj',
'/clp:NoSummary;NoItemAndPropertyList;Verbosity=minimal',
'/nologo',
'/p:Configuration=debug',
'/p:Platform=anycpu',
'/p:AppxBundle=Never' ] { stdio: 'inherit' }
C:\laragon\www\ionic\WinApp\platforms\windows\CordovaApp.Windows10.jsproj(61,13): error MSB4226: The imported project "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\Microsoft\VisualStudio\v15.0\JavaScript\Microsoft.VisualStudio.WJProject.Default.props" was not found. Also, tried to find "Microsoft\VisualStudio\v15.0\JavaScript\Microsoft.VisualStudio.WJProject.Default.props" in the fallback search path(s) for $(MSBuildExtensionsPath32) - "C:\Program Files (x86)\MSBuild" . These search paths are defined in "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\msbuild.exe.Config". Confirm that the path in the <Import> declaration is correct, and that the file exists on disk in one of the search paths.
No valid MSBuild was detected for the selected target: Error: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\msbuild: Command failed with exit code 1
IDE: Visual studio 2017
Cordova 9
cordova-windows 7.0.0
BuildTools 15
OS: Windows 10
Ionic 5
Added MSBUILDDIR in system environments
Added VSINSTALLDIR in system environments
Added path of MSBuild in system environments
Yet I'm getting error above.
Any idea what might be wrong?
my project is running [email protected]. Everything works fine on all platforms, apart from on one Windows phone that is running 10.0.15254.248. The other windows phone I have, which is running: 10.0.14393.2068, runs it perfectly fine.
Whenever you click on an input, and then type a key, it instantly crashes the app, with the following exception:
JavaScript runtime error: Unable to get property 'handleEvent' of undefined or null reference
The program '[7608] WWAHost.exe' has exited with code -1073741819 (0xc0000005) 'Access violation'.
A previous version of the app installed on the same phone works fine, however this is an old build and I have no access to this code. I have tried reverting to the last code I have and the issue still persists, and have updated and reverted versions as best I can to try and find a working combination.
Has anyone come across this before? Below is the offending HTML - just a standard input.
<label for="x" class="y">Input your z</label>
When these were created it was only VS2013 and VS2015, Windows 10 also was not a thing. Because of this the error message of the requirement checks in multiple places output quite confusing instruction on what to do or install.
Unfortunately what to actually do is really complicated and so not easy to fix.
CI started failing when #329 was merged:
95401b3
https://ci.appveyor.com/project/Humbedooh/cordova-windows/builds/24305931
Example:
.Creating Cordova Windows Project:
Path: temp\platforms\testcreate 応用
Namespace: com.test.app
Name: 応用
Windows project created with [email protected]
Building project: C:\projects\cordova-windows\temp\platforms\testcreate 応用\CordovaApp.Windows.jsproj
Configuration : debug
Platform : anycpu
Buildflags : /p:AppxBundle=Never
MSBuildTools : C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin
buildProject spawn: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\msbuild [ 'C:\\projects\\cordova-windows\\temp\\platforms\\testcreate 応用\\CordovaApp.Windows.jsproj',
'/clp:NoSummary;NoItemAndPropertyList;Verbosity=minimal',
'/nologo',
'/p:Configuration=debug',
'/p:Platform=anycpu',
'/p:AppxBundle=Never' ] { stdio: 'inherit' }
prebuild.js: Patching platform `8.1`
- Injected `base.js` reference to `www/index.html`
- Removing /( *)(<script\s+(?:type="text\/javascript"\s+)?src="\/www\/WinJS\/js\/base.js">\s*<\/script>)(\s*)/ from www/index.html
- Removing /( *)(<script\s+(?:type="text\/javascript"\s+)?src="\/\/Microsoft.Phone.WinJS.2.1\/js\/base.js">\s*<\/script>)(\s*)/ from www/index.html
C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\Microsoft\VisualStudio\v15.0\AppxPackage\Microsoft.AppXPackage.Targets(828,5): error APPX3217: SDK folder containing 'Windows.props' for 'Windows 8.1' cannot be located. See http://go.microsoft.com/fwlink/?LinkID=798187 for more information. [C:\projects\cordova-windows\temp\platforms\testcreate ??\CordovaApp.Windows.jsproj]
C:\projects\cordova-windows\temp\platforms\testcreate 応用\cordova\node_modules\q\q.js:155
throw e;
^
CordovaError: No valid MSBuild was detected for the selected target: Error: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\msbuild: Command failed with exit code 1
at C:\projects\cordova-windows\temp\platforms\testcreate 応用\cordova\lib\build.js:83:29
at _rejected (C:\projects\cordova-windows\temp\platforms\testcreate 応用\cordova\node_modules\q\q.js:864:24)
at C:\projects\cordova-windows\temp\platforms\testcreate 応用\cordova\node_modules\q\q.js:890:30
at Promise.when (C:\projects\cordova-windows\temp\platforms\testcreate 応用\cordova\node_modules\q\q.js:1142:31)
at Promise.promise.promiseDispatch (C:\projects\cordova-windows\temp\platforms\testcreate 応用\cordova\node_modules\q\q.js:808:41)
at C:\projects\cordova-windows\temp\platforms\testcreate 応用\cordova\node_modules\q\q.js:624:44
at runSingle (C:\projects\cordova-windows\temp\platforms\testcreate 応用\cordova\node_modules\q\q.js:137:13)
at flush (C:\projects\cordova-windows\temp\platforms\testcreate 応用\cordova\node_modules\q\q.js:125:13)
at _combinedTickCallback (internal/process/next_tick.js:73:7)
at process._tickCallback (internal/process/next_tick.js:104:9)
ls: no such file or directory: C:\projects\cordova-windows\temp\platforms\testcreate 応用\AppPackages
(CordovaError: No valid MSBuild was detected for the selected target:
is a known red herring here: #266)
Difference between working and broken build is this:
Before:
MSBuildTools : C:\Program Files (x86)\MSBuild\14.0\bin\
buildProject spawn: C:\Program Files (x86)\MSBuild\14.0\bin\msbuild [ 'C:\\projects\\cordova-windows\\temp\\platforms\\testcreate 応用\\CordovaApp.Windows10.jsproj',
After:
MSBuildTools : C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin
buildProject spawn: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\msbuild [ 'C:\\projects\\cordova-windows\\temp\\platforms\\testcreate 応用\\CordovaApp.Windows10.jsproj',
So improving the VS detector breaks on AppVeyor :/
I want to dev windows mobile in mac os. So I create windows platform with command 'cordova platform add windows', but when I try to build or run with command 'cordova build/run windows', It will failed with error 'No valid MSBuild was detected for the selected target.'
Visual studio 2017 for mac is installed and added dotnet and msbuild to environment path.
Cordova (Cordova CLI) : 8.0.0
Cordova Platforms : ios 4.5.4 windows 6.0.0
OS: macOS High Sierra
Xcode : Xcode 9.4.1 Build version 9F2000
[Originally reported in https://issues.apache.org/jira/browse/CB-13917 ]
In config.xml, the minimum Windows 10 version preference must be set with both:
uap-target-min-version
Windows.Universal-MinVersion
Setting uap-target-min-versio
results in the value being copied to CordovaApp.Windows10.jsproj
.
Setting Windows.Universal-MinVersion
results in the value being copied to package.windows10.appxmanifest
.
If uap-target-min-version
is not set, the minimum version of the app in the Microsoft Store is incorrect.
Development of Windows 10 apps would be simplified by only having to set the minimum version in one place.
Is there any CI service that can install and run Cordova Windows apps?
I tried these:
cordova run windows
(and if you disable that check, you get Error: The package or bundle is not digitally signed or its signature is corrupted.
)APPX0105: Cannot import the key file 'CordovaApp_TemporaryKey.pfx'. The key file may be password protected. To correct this, try to import the certificate manually into the current user’s personal certificate store.
, Running command: powershell -ExecutionPolicy RemoteSigned Import-Module "D:\a\1\s\platforms\windows\cordova\lib\WindowsStoreAppUtils.ps1"; Install-App "D:\a\1\s\platforms\windows\AppPackages\CordovaApp.Windows10_1.0.0.0_anycpu_debug_Test\Add-AppDevPackage.ps1"
Found package: D:\a\1\s\platforms\windows\AppPackages\CordovaApp.Windows10_1.0.0.0_anycpu_debug_Test\CordovaApp.Windows10_1.0.0.0_anycpu_debug.appx
Found certificate: D:\a\1\s\platforms\windows\AppPackages\CordovaApp.Windows10_1.0.0.0_anycpu_debug_Test\CordovaApp.Windows10_1.0.0.0_anycpu_debug.cer
Before installing this app, you need to do the following:
- Install the signing certificate
Administrator credentials are required to continue. Please accept the UAC prompt and provide your administrator password if asked.
and actually prompt you for Admin permissions.Cordova Windows projects no longer function in the latest Visual Studio release (2019).
Cordova Windows Visual Studio solutions open, compile, and deploy successfully using the latest Visual Studio release.
None of the above.
cordova run windows
The official Visual Studio 2019 release drops all support for JavaScript UWP projects. Per it’s release notes:
UWP JavaScript apps are no longer supported in Visual Studio 2019. You cannot create or open JavaScript UWP projects (files with extension jsproj).
As best as I can tell, the only two paths forward for Cordova apps using .NET plugins are 1) Cordova-Electron + Edge.js, or 2) writing a custom UWP host with a full-screen WebView (perhaps using WebView.Interop.
WinJS is not copied when adding windows platform to cordova application.
The winjs\js\base.js should be copied correctly.
The winjs\js\base.js is not copied, and the console prints the error log:
cp: no such file or directory: C:\Users\i062893\cordova-workspace\attachmenttest\node_modules\cordova-windows\node_modules\winjs\js\base.js
I use following commands:
C:\Users\i062893\cordova-workspace>cordova --version
9.0.0 ([email protected])
C:\Users\i062893\cordova-workspace>cordova create attachmenttest
Creating a new cordova project.
C:\Users\i062893\cordova-workspace>cd attachmenttest
C:\Users\i062893\cordova-workspace\attachmenttest>cordova platforms add windows
Using cordova-fetch for cordova-windows@^7.0.0
Adding windows project...
Creating Cordova Windows Project:
Path: platforms\windows
Namespace: io.cordova.hellocordova
Name: HelloCordova
cp: no such file or directory: C:\Users\i062893\cordova-workspace\attachmenttest\node_modules\cordova-windows\node_modules\winjs\js\base.js
cp: no such file or directory: C:\Users\i062893\cordova-workspace\attachmenttest\node_modules\cordova-windows\node_modules\winjs\js\base.js
Windows project created with [email protected]
Plugin 'cordova-plugin-whitelist' found in config.xml... Migrating it to package.json
Discovered saved plugin "cordova-plugin-whitelist". Adding it to the project
Installing "cordova-plugin-whitelist" for windows
Adding cordova-plugin-whitelist to package.json
Cordova: 9.0.0
cordova-windows: 7.0.0
Hello there,
I stumbled over an issues with Ionic 4 and the cordova build. In debug mode, the js module filenames are getting, depending on your project setup, quiet big. In Prod releases, they get uglified. So there will be less of a problem.
C:\develop\BuildTools\MSBuild\Microsoft\VisualStudio\v15.0\AppxPackage\Microsoft.AppXPackage.Targets(3704,5): error MSB3021: Unable to copy file "C:\swarm\workspace\very-long-directory-path\platforms\windows\www\default~features-path-to-module-file-and-module-name~c9a3cc5b.js" to "build\windows\bld\PackageLayout\www\default~path-to-module-file-and-module-name~c9a3cc5b.js". The specified path, file name, or both are too long. The fully qualified file name must be less than 260 characters, and the directory name must be less than 248 characters. [C:\swarm\workspace\very-long-directory-path\platforms\windows\CordovaApp.Windows10.jsproj]
So to fix that, we addressed the issue with the long dir name. My Jenkins generates the dir automatically and uses the last git hash with about 50 characters. We removed that, and were under that Windows limit.
So I guess, this is more or less a workaround for the problem itself. I'm not really sure how Windows long path thing works, but here is a link to the official docu. Maybe this could help to eliminate any error in that direction.
Best regards,
Fabiryn
Continuation of apache/cordova-discuss#106 which is now closed:
cordova-windows has suffered from the following issues with template/Properties/Default.rd.xml
that was introduced in GH-228 (CB-12499):
--release --bundle --archs="x64 x86 arm"
on AppVeyor CI which remains unsolvedcoho audit-license-headers -r windows
gives a message that template/Properties/Default.rd.xml
is missing the license headerIt is clear from CB-12499 that Default.rd.xml
was introduced to solve a problem but it is unfortunately the actual circumstances are not so clear to me. The following observations indicate to me that Default.rd.xml
should only be needed in case of a project using C# which I think is not always the case:
Properties/Default.rd.xml
in case of C#.Default.rd.xml
in a cs
directory (Microsoft / Windows-universal-samples / SharedContent / cs / Default.rd.xmlGiven the observed troubles and what I think are limited circumstances of need I would like to propose that we remove template/Properties/Default.rd.xml
at some point in the future, as a major release item, and support it in a plugin if needed.
Although the build process is done by MSBuild and needs some SDKs installed, in lots of places this is represented by "Visual Studio". Yes, Visual Studio comes with MSBuild and the SDKs can be installed there, but still this is not correct. By mixing these, it can become confusing what is missing and why.
The Windows platform should be added without errors.
The following error is logged (twice):
cp: no such file or directory: C:\Temp\test\node_modules\cordova-windows\node_modules\winjs\js\base.js
If you create a new cordova project and then try to add the windows platform version 7.0.0
the following output is logged:
Using cordova-fetch for [email protected]
Adding windows project...
Creating Cordova Windows Project:
Path: platforms\windows
Namespace: io.cordova.hellocordova
Name: HelloCordova
cp: no such file or directory: C:\Temp\test\node_modules\cordova-windows\node_modules\winjs\js\base.js
cp: no such file or directory: C:\Temp\test\node_modules\cordova-windows\node_modules\winjs\js\base.js
Windows project created with [email protected]
Discovered plugin "cordova-plugin-whitelist" in config.xml. Adding it to the project
Installing "cordova-plugin-whitelist" for windows
Adding cordova-plugin-whitelist to package.json
Saved plugin info for "cordova-plugin-whitelist" to config.xml
--save flag or autosave detected
Saving windows@~7.0.0 into config.xml file ...
It seems as if the paths to the base.js
file are not resolved properly. They should be C:\Temp\test\node_modules\winjs\js\base.js instead of C:\Temp\test\node_modules\cordova-windows\node_modules\winjs\js\base.js
cordova create test
cd test
cordova platform add [email protected]
Windows 10 Enterprise Version 1809 Build 17763.379
Cordova 8.1.2 ([email protected])
I have already made ionic app and it works on android/ios
I just wanted to add windows platform and it added successfully .
but when I call
C:\ionic2>cordova requirements
I got this
Requirements check results for windows:
Windows OS: not installed
Error: getConfig(...).getWindowsTargetVersion is not a function
(node:932) UnhandledPromiseRejectionWarning: CordovaError: Some of requirements
check failed
I don't know where is the problem ,because I build the app but it doesn't instaled in the phone.
https://github.com/apache/cordova-windows/blob/master/cordova-windows10.md
This document contains information about an experimental branch of cordova-windows with support for
Windows 10 Technical Preview 2 released at the Build conference in April 2015. Information is subject
to change with later revisions of the software.
This is definitely not true any more. The file should be removed and the information in it, if still relevant, moved to the docs.
Microsoft added vswhere
to the default install of Visual Studio 2017:
https://github.com/Microsoft/vswhere
https://github.com/Microsoft/vswhere/wiki/Find-MSBuild
https://docs.microsoft.com/en-us/visualstudio/install/tools-for-managing-visual-studio-instances
https://blogs.msdn.microsoft.com/heaths/2017/04/21/vswhere-is-now-installed-with-visual-studio-2017/
We already use it in appveyor.yml
to debug output these paths for the CI environment. It would be handy to also use this simple command in MSBuildTools.js
and similar code instead of what is currently there (which is really confusing and party bad).
I'm trying to recover being able to build from my main repo and not having to open the solution in the platform every time.
When trying to run my (default) build I keep getting this error:
MakeAppx : error : You can't add both "C:\Users\dennis\Source\Repos\showman-ionic\platforms\windows\build\windows\debug\x86\win10\Upload\AppxManifest.xml" and "C:\Users\dennis\Source\Repos\showman-ionic\platforms\windows\build\windows\debug\x86\win10\ilc\AppxManifest.xml" to the output file as "AppxManifest.xml". [C:\Users\dennis\Source\Repos\showman-ionic\platforms\windows\CordovaApp.Windows10.jsproj]
I deleted the entire build folder, it add's the files and does it every time. No Idea how to stop it or where it's configured...
Hi , Is there plans to have the new predictive text working inside cordova for Windows 10 1803 ? Or has been it added already?
Removing a <config-file>
element from the config.xml should be reflected in the AppxManifest.xml / package.*.appxmanifest file after running the build command.
Having for example this configuration in the main config.xml:
<platform name="windows">
<config-file parent="/Package/Capabilities" target="package.appxmanifest">
<Capability Name="allJoyn" />
</config-file>
</platform>
And then removing this element and building the application with cordova build windows -- --archs="x64"
will:
Windows 10
Cordova 8.1.2
Cordova-windows 6.0.1 and 7.0.0
Might be related to #336.
Not sure if this is a bug or if I am expected to readd the platform after making changes to the config.xml file... in case of the latter, feel free to close these two issues...
Can cordova be compiled to generate window 'exe' file ?
I would like to use cordova compile project to window exe.
Does it support it ?
I have Ionic app which so far i made android app and app is working just fine in fact it's released to google store as well, so everything is really fine with my app until I added Cordova Windows Platform
in order to have another version of my app and now when I open my project on VS17 and run the app this is what I get:
Blank window.
OS: Windows 10
IDE: VS17
Installed Windows 10 SDK
Installed MSbuild
Installed UWP
Note: if I run command
ionic cordova build windows
I get:
ENV var MSBUILDDIR is set C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin
rm: could not remove directory (code ENOTEMPTY): C:\laragon\www\ionic\xxxx\platforms\windows\build/windows
rm: could not remove directory (code ENOTEMPTY): C:\laragon\www\ionic\xxxx\platforms\windows\build/windows
rm: could not remove directory (code ENOTEMPTY): C:\laragon\www\ionic\xxxx\platforms\windows\build
Building project: C:\laragon\www\ionic\xxxx\platforms\windows\CordovaApp.Windows10.jsproj
Configuration : debug
Platform : anycpu
Buildflags : /p:AppxBundle=Never
MSBuildTools : C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin
buildProject spawn: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\msbuild [ 'C:\\laragon\\www\\ionic\\xxxx\\platforms\\windows\\CordovaApp.Windows10.jsproj',
'/clp:NoSummary;NoItemAndPropertyList;Verbosity=minimal',
'/nologo',
'/p:Configuration=debug',
'/p:Platform=anycpu',
'/p:AppxBundle=Never' ] { stdio: 'inherit' }
prebuild.js: Patching platform `10`
- Injected `base.js` reference to `/www/index.html`
- Removing /( *)(<script\s+(?:type="text\/javascript"\s+)?src="\/\/Microsoft.WinJS.2.0\/js\/base.js">\s*<\/script>)(\s*)/ from /www/index.html
- Removing /( *)(<script\s+(?:type="text\/javascript"\s+)?src="\/\/Microsoft.Phone.WinJS.2.1\/js\/base.js">\s*<\/script>)(\s*)/ from /www/index.html
C:\laragon\www\ionic\xxxx\platforms\windows\CordovaApp.Windows10.jsproj(86,9): error : The following component requires .NET Native compilation which is not available when targeting 'Windows10' and 'AnyCPU'. Consider changing the targeted processor architecture to one of the following: 'x86, x64, ARM' (if you are using command line this could be done by adding '--archs' parameter, for example: 'cordova build windows --archs=x64'). C:\laragon\www\ionic\xxxx\platforms\windows\plugins\onesignal-cordova-plugin\OneSignalSDK_WP_WNS_WRTC.winmdNo valid MSBuild was detected for the selected target: Error: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\msbuild: Command failed with exit code 1
And If I use VS17 I get blank screen.
Any idea what might be wrong?
I had a problem with the MSBuild Tool for building an ionic project for windows.
The reason for the problem might be that I have installed both, Visual Studio Professional 2017 and Visual Studio Community 2017.
After adding the windows platform with cordova platform add [email protected]
I got the following output when trying to compile with ionic cordova build windows
:
Building project: C:\Users\Lukas\Desktop\Schulapp\Schulapp\platforms\windows\CordovaApp.Windows10.jsproj
Configuration : debug
Platform : anycpu
Buildflags : /p:AppxBundle=Never
MSBuildTools : C:\Program Files (x86)\MSBuild\14.0\bin
buildProject spawn: C:\Program Files (x86)\MSBuild\14.0\bin\msbuild [ 'C:\\Users\\Lukas\\Desktop\\Schulapp\\Schulapp\\platforms\\windows\\CordovaApp.Windows10.jsproj',
'/clp:NoSummary;NoItemAndPropertyList;Verbosity=minimal',
'/nologo',
'/p:Configuration=debug',
'/p:Platform=anycpu',
'/p:AppxBundle=Never' ] { stdio: 'inherit' }
C:\Users\Lukas\Desktop\Schulapp\Schulapp\platforms\windows\CordovaApp.Windows10.jsproj(61,5): error MSB4019: Das importierte Projekt "C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v14.0\Micr
osoft.VisualStudio..Default.props" wurde nicht gefunden. Vergewissern Sie sich, dass der Pfad in der <Import>-Deklaration korrekt und die Datei auf dem Datenträger vorhanden ist.
(node:9196) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): code: Error: C:\Program Files (x86)\MSBuild\14.0\bin\msbuild.exe: Command failed with exit code 1 No valid MSBuild was detected for the selected target: Error: C:\Program Files (x86)\MSBuild\14.0\bin\msbuild.exe: Command failed with exit code 1
This line 61 says:
<Import Project="$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\$(WMSJSProjectDirectory)\Microsoft.VisualStudio.$(WMSJSProject).Default.props" />
Ionic info
says:
cli packages: (C:\Users\Lukas\AppData\Roaming\npm\node_modules)
@ionic/cli-utils : 1.19.2
ionic (Ionic CLI) : 3.20.0
global packages:
cordova (Cordova CLI) : 8.0.0
local packages:
@ionic/app-scripts : 3.1.8
Cordova Platforms : windows 6.0.0
Ionic Framework : ionic-angular 3.9.2
System:
Node : v6.11.5
npm : 3.10.10
OS : Windows 10
Environment Variables:
ANDROID_HOME : not set
Misc:
backend : pro
cordova platform list
says:
Installed platforms:
windows 6.0.0
Available platforms:
android ~7.0.0
browser ~5.0.1
ios ~4.5.4
osx ~4.0.1
www ^3.12.0
After adding the environment variable MSBUILDDIR to C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin
it worked.
For additional information and the complete solution path please look at https://forum.ionicframework.com/t/windows-10-sdk-missing/126215/12
After code restructuring this Exception is triggered a bit too often.
E.g. if just the build
process in MSBuild fails:
CordovaError: No valid MSBuild was detected for the selected target: Error: C:\Program Files (x86)\MSBuild\14.0\bin\msbuild.exe: Command failed with exit code 1
This issue refers to a problem in the way the code is structured - returning an exception that is not 100% correct all the times.
My project works fine on Android and Windows 10
But I've an issue with Win10 for accessing to the FileSystem
The project is configured with [email protected] and [email protected]
When I try to use window.requestFileSystem, it is always undefined.
Is there something specific to configure in config.xml or something like that ?
This test fails, although it shouldn't:
Failures:
1) Cordova create and build spec.6a should generate appxupload and appxbundle for Windows 10 project bundle release build
Message:
Expected 1 to be 3.
Stack:
Error: Expected 1 to be 3.
at _expectExist (C:\projects\cordova-windows\spec\e2e\endtoend.spec.js:53:97)
at UserContext.<anonymous> (C:\projects\cordova-windows\spec\e2e\endtoend.spec.js:243:9)
Message:
Expected 0 to be 1.
Stack:
Error: Expected 0 to be 1.
at verifySubDirContainsFile (C:\projects\cordova-windows\spec\e2e\endtoend.spec.js:46:90)
at _expectSubdirAndFileExist (C:\projects\cordova-windows\spec\e2e\endtoend.spec.js:60:9)
at UserContext.<anonymous> (C:\projects\cordova-windows\spec\e2e\endtoend.spec.js:244:9)
19 specs, 1 failure
Finished in 271.36 seconds
Only happens on AppVeyor.
When you run npm run test-unit
you get loads of unrelated and distracting output:
> [email protected] test-unit E:\Projects\Cordova\cordova-windows
> jasmine
Started
...........................*.*.*............................Deployment completed successfully.
Deployment completed successfully.
Deployment completed successfully.
.Deployment completed successfully.
Deployment completed successfully.
Deployment completed successfully.
......................................................................................................................The following Capabilities were declared and are restricted:
documentsLibrary
You will be unable to on-board your app to the public Windows Store with these capabilities and access rules permitting access to remote URIs.The following Capabilities were declared and are restricted:
documentsLibrary
You will be unable to on-board your app to the public Windows Store with these capabilities and access rules permitting access to remote URIs.The following Capabilities were declared and are restricted:
documentsLibrary
You will be unable to on-board your app to the public Windows Store with these capabilities and access rules permitting access to remote URIs....Access rules must begin with "https://", the following rule will be ignored: http://www.contoso.com
Access rules must begin with "https://", the following rule will be ignored: http://www.contoso.com
Access rules must begin with "https://", the following rule will be ignored: http://www.contoso.com
........The following image was skipped because it has an unsupported size (999x999): res/Windows/UnknownImage.png
The following image was skipped because it has an unsupported size (999x999): res/Windows/UnknownImage.png
The following image was skipped because it has an unsupported size (999x999): res/Windows/UnknownImage.png
.."res\Windows\splashscreen.png" file size exceeds the limit of 204800 bytes, skipping.
"res\Windows\splashscreen.png" file size exceeds the limit of 204800 bytes, skipping.
"res\Windows\splashscreen.png" file size exceeds the limit of 204800 bytes, skipping.
"res\Windows\splashscreen.scale-200.png" file size exceeds the limit of 204800 bytes, skipping.
"res\Windows\splashscreen.scale-200.png" file size exceeds the limit of 204800 bytes, skipping.
"res\Windows\splashscreen.scale-200.png" file size exceeds the limit of 204800 bytes, skipping.
"res\Windows\splashscreen.scale-400.png" file size exceeds the limit of 204800 bytes, skipping.
"res\Windows\splashscreen.scale-400.png" file size exceeds the limit of 204800 bytes, skipping.
"res\Windows\splashscreen.scale-400.png" file size exceeds the limit of 204800 bytes, skipping.
"res/Windows/splashscreen.scale-200.png" file size exceeds the limit of 204800 bytes, skipping.
"res/Windows/splashscreen.scale-200.png" file size exceeds the limit of 204800 bytes, skipping.
"res/Windows/splashscreen.scale-200.png" file size exceeds the limit of 204800 bytes, skipping.
"res/Windows/splashscreen.scale-400.png" file size exceeds the limit of 204800 bytes, skipping.
"res/Windows/splashscreen.scale-400.png" file size exceeds the limit of 204800 bytes, skipping.
"res/Windows/splashscreen.scale-400.png" file size exceeds the limit of 204800 bytes, skipping.
.".gif" extension is not supported, skipping. Supported image extensions are [".png",".jpg",".jpeg"]
".gif" extension is not supported, skipping. Supported image extensions are [".png",".jpg",".jpeg"]
".gif" extension is not supported, skipping. Supported image extensions are [".png",".jpg",".jpeg"]
".bmp" extension is not supported, skipping. Supported image extensions are [".png",".jpg",".jpeg"]
".bmp" extension is not supported, skipping. Supported image extensions are [".png",".jpg",".jpeg"]
".bmp" extension is not supported, skipping. Supported image extensions are [".png",".jpg",".jpeg"]
".tga" extension is not supported, skipping. Supported image extensions are [".png",".jpg",".jpeg"]
".tga" extension is not supported, skipping. Supported image extensions are [".png",".jpg",".jpeg"]
".tga" extension is not supported, skipping. Supported image extensions are [".png",".jpg",".jpeg"]
."SplashScreen" splash screens have mixed file extensions which is not supported. Some of the images will not be used.
"SplashScreen" splash screens have mixed file extensions which is not supported. Some of the images will not be used.
"SplashScreen" splash screens have mixed file extensions which is not supported. Some of the images will not be used.
"SplashScreenPhone" splash screens have mixed file extensions which is not supported. Some of the images will not be used.
"SplashScreenPhone" splash screens have mixed file extensions which is not supported. Some of the images will not be used.
"SplashScreenPhone" splash screens have mixed file extensions which is not supported. Some of the images will not be used.
......Deploying phone package to device:
testfile
Deploying phone package to device:
testfile
Deploying phone package to device:
testfile
.Deploying windows package to device:
testfile
Deploying windows package to device:
testfile
Deploying windows package to device:
testfile
.Deploying windows package to device:
undefined
Deploying windows package to device:
undefined
Deploying windows package to device:
undefined
.Deploying undefined package to device:
undefined
Deploying undefined package to device:
undefined
Deploying undefined package to device:
undefined
Deploying undefined package to device:
undefined
Deploying undefined package to device:
undefined
Deploying undefined package to device:
undefined
.Deploying undefined package to device:
undefined
Deploying undefined package to device:
undefined
Deploying undefined package to device:
undefined
.............
Pending:
1) run method spec.8 should fail buildProject if built with MSBuildTools version 4.0
Temporarily disabled with xit
2) run method spec.10 should throw an error if windows-target-version has unsupported value
Temporarily disabled with xit
3) run method spec.12 should throw an error if windows-phone-target-version has unsupported value
Temporarily disabled with xit
217 specs, 0 failures, 3 pending specs
Finished in 11.912 seconds
Most of this could probably be avoided.
The Windows 10 Manifest uses the uap namespace for UAP/UWP tags. The following tag name for UWP in confighelper.js does not match the SplashScreen tag in that manifest, a modified uap:SplashScreen tag name does.
cordova-windows/template/www/cordova.js
Line 848 in 8cc627b
Results in undefined access when retrieving splash screen image path etc. which causes a bunch of other issues ...
Don't know what the reason behind the differing behavior is, maybe the Windows 10 build version. Version 10.0.17736 requires the uap namespace, version 10.0.17134 is only ok without the namespace, same app build.
Hello, looking through the open issues I think we're all facing somewhat similar versions of the same problem with MSBuildTool. #266, #267, #272, #273 are all versions of problems finding the correct MSBuild path.
I'm running Ionic 3.20.0
Cordova 8.0.0
and Cordova-Windows 6.0.0
as well as a fresh install of Windows 10 pro and Visual Studio Community 2017
When I run cordova windows build
or cordova windows run
I get essentially the same issue:
C:\Users\dennis\Source\Repos\showman-ionic>cordova build windows
Skip!
MSBuild v4.0 is not supported, aborting.
(node:2108) UnhandledPromiseRejectionWarning: CordovaError: No valid MSBuild was detected for the selected target: Package with specified parameters not found in AppPackages folder
at C:\Users\dennis\Source\Repos\showman-ionic\platforms\windows\cordova\lib\build.js:83:29
at _rejected (C:\Users\dennis\Source\Repos\showman-ionic\platforms\windows\cordova\node_modules\q\q.js:864:24)
at C:\Users\dennis\Source\Repos\showman-ionic\platforms\windows\cordova\node_modules\q\q.js:890:30
at Promise.when (C:\Users\dennis\Source\Repos\showman-ionic\platforms\windows\cordova\node_modules\q\q.js:1142:31)
at Promise.promise.promiseDispatch (C:\Users\dennis\Source\Repos\showman-ionic\platforms\windows\cordova\node_modules\q\q.js:808:41)
at C:\Users\dennis\Source\Repos\showman-ionic\platforms\windows\cordova\node_modules\q\q.js:624:44
at runSingle (C:\Users\dennis\Source\Repos\showman-ionic\platforms\windows\cordova\node_modules\q\q.js:137:13)
at flush (C:\Users\dennis\Source\Repos\showman-ionic\platforms\windows\cordova\node_modules\q\q.js:125:13)
at _combinedTickCallback (internal/process/next_tick.js:131:7)
at process._tickCallback (internal/process/next_tick.js:180:9)
(node:2108) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:2108) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
I read through everyones issues (even some in german) and #267 is correct that any failure will throw the error either in the CLI or using visual studio, BUT when run inside Visual Studio it doesn't have the errors related to missing or unsupported MSBuild.
When I run cordova build windows --verbose
C:\Users\dennis\Source\Repos\showman-ionic>cordova build windows --verbose
No scripts found for hook "before_build".
No scripts found for hook "before_prepare".
Checking config.xml and package.json for saved platforms that haven't been added to the project
Config.xml and package.json platforms are the same. No pkg.json modification.
Package.json and config.xml platforms are different. Updating config.xml with most current list of platforms.
PlatformApi successfully found for platform windows
Checking config.xml for saved plugins that haven't been added to the project
Checking for any plugins added to the project that have not been installed in windows platform
No differences found between plugins added to project and installed in windows platform. Continuing...
Generating platform-specific config.xml from defaults for windows at C:\Users\dennis\Source\Repos\showman-ionic\platforms\windows\config.xml
Merging project's config.xml into platform-specific windows config.xml
Merging and updating files from [www, platforms\windows\platform_www] to platforms\windows\www
copy www\assets\base\base.css platforms\windows\www\assets\base\base.css (updated file)
//
// *** Copying truncated for clarity ***///
//
copy www\service-worker.js platforms\windows\www\service-worker.js (updated file)
Updating icons and splash screens at platforms\windows\images
Prepared windows project successfully
No scripts found for hook "pre_package".
Executing script found in plugin com-intel-security-cordova-plugin for hook "after_prepare": plugins\com-intel-security-cordova-plugin\src\windows\ChooseArch_Windows.js
No scripts found for hook "before_compile".
Reading build config file: C:\Users\dennis\Source\Repos\showman-ionic\build.json
getLatestMatchingMSBuild
getLatestMSBuild
Searching for available MSBuild versions...
Running command: C:\WINDOWS\system32\reg.exe query HKLM\SOFTWARE\Microsoft\MSBuild\ToolsVersions\15.5 /v MSBuildToolsPath
Running command: C:\WINDOWS\system32\reg.exe query HKLM\SOFTWARE\Microsoft\MSBuild\ToolsVersions\15.0 /v MSBuildToolsPath
Running command: C:\WINDOWS\system32\reg.exe query HKLM\SOFTWARE\Microsoft\MSBuild\ToolsVersions\14.0 /v MSBuildToolsPath
Running command: C:\WINDOWS\system32\reg.exe query HKLM\SOFTWARE\Microsoft\MSBuild\ToolsVersions\12.0 /v MSBuildToolsPath
Running command: C:\WINDOWS\system32\reg.exe query HKLM\SOFTWARE\Microsoft\MSBuild\ToolsVersions\4.0 /v MSBuildToolsPath
Skip!
Command finished with error code 1: C:\WINDOWS\system32\reg.exe query,HKLM\SOFTWARE\Microsoft\MSBuild\ToolsVersions\15.0,/v,MSBuildToolsPath
Command finished with error code 1: C:\WINDOWS\system32\reg.exe query,HKLM\SOFTWARE\Microsoft\MSBuild\ToolsVersions\15.5,/v,MSBuildToolsPath
Command finished with error code 1: C:\WINDOWS\system32\reg.exe query,HKLM\SOFTWARE\Microsoft\MSBuild\ToolsVersions\14.0,/v,MSBuildToolsPath
Command finished with error code 1: C:\WINDOWS\system32\reg.exe query,HKLM\SOFTWARE\Microsoft\MSBuild\ToolsVersions\12.0,/v,MSBuildToolsPath
Command finished with error code 0: C:\WINDOWS\system32\reg.exe query,HKLM\SOFTWARE\Microsoft\MSBuild\ToolsVersions\4.0,/v,MSBuildToolsPath
Found MSBuild v4.0 at C:\Windows\Microsoft.NET\Framework64\v4.0.30319\
Using MSBuild v4.0 from C:\Windows\Microsoft.NET\Framework64\v4.0.30319\
MSBuild v4.0 is not supported, aborting.
(node:9592) UnhandledPromiseRejectionWarning: CordovaError: No valid MSBuild was detected for the selected target: Package with specified parameters not found in AppPackages folder
at C:\Users\dennis\Source\Repos\showman-ionic\platforms\windows\cordova\lib\build.js:83:29
at _rejected (C:\Users\dennis\Source\Repos\showman-ionic\platforms\windows\cordova\node_modules\q\q.js:864:24)
at C:\Users\dennis\Source\Repos\showman-ionic\platforms\windows\cordova\node_modules\q\q.js:890:30
at Promise.when (C:\Users\dennis\Source\Repos\showman-ionic\platforms\windows\cordova\node_modules\q\q.js:1142:31)
at Promise.promise.promiseDispatch (C:\Users\dennis\Source\Repos\showman-ionic\platforms\windows\cordova\node_modules\q\q.js:808:41)
at C:\Users\dennis\Source\Repos\showman-ionic\platforms\windows\cordova\node_modules\q\q.js:624:44
at runSingle (C:\Users\dennis\Source\Repos\showman-ionic\platforms\windows\cordova\node_modules\q\q.js:137:13)
at flush (C:\Users\dennis\Source\Repos\showman-ionic\platforms\windows\cordova\node_modules\q\q.js:125:13)
at _combinedTickCallback (internal/process/next_tick.js:131:7)
at process._tickCallback (internal/process/next_tick.js:180:9)
(node:9592) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:9592) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
So it seems it can't find my MSBuild info at all. That got me looking around and I found:
VS 2017 Does not put items into the registry
which is the method cordova-windows
uses to look for the path. (at least on my machine)
So it goes down the registry list and then finds the MSBuild for .NET which is way old I guess and it bails.
When run inside VS, VS I guess handles this or I'm not exactly sure what's happening. I'm 3 days into Windows Build Voodoo.
Other folks are on fresh machines too, and only install 2017, which NEVER places any info in the registry so it'll likely show as failed...
I have one thing left to try solution wise but I'm at my limit skillset wise on going much deeper on my own. Let me know what you need / suggest I try and I'll for sure do it..
Probably unrelated but I also saw my CordovaApp.Windows10.jsproj
is still targeting v14:
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
Which Seems it could be bumped to 15 if 2017 is the new Req
Sometimes the keyboard makes the app crashes
The keyboard normally appears when you select an input to be filled
The keyboard NOT appears and the entire app crashes
Related to issue #269
n.d.
Tablet Samsung Galaxy Book SM-W728NZKAITV, Windows
Cordova 6.3.1
Cordova Windows 4.4.2
Ionic 1.3.2
Hey everyone ,
Currently i have a Cordova plugin and a UWP Class library. The library is using native UIElements for different UI workflows. Is there a way to display those UIElements? I read, that XAML views can't be displayed. Is there a workaround somehow?
Maybe we can put the WebView in the background in fire up a native View. If yes, how do we get the current page, like in Android (cordova.getActivity())?
Thanks in advance!
Hello everyone,
Installed [email protected] + VS 2017 v15.5: MSBuild v4.0 is not supported, aborting.
Updated to [email protected]: Working fine.
Updated VS2017 to v15.7: the same error again (MSBuild v4.0 is not supported, aborting).
**Cordova platform add windows@^7.0.0 command not copying the node_modules into node_modules\cordova-windows\node_modules **
Instead all the node_modules are present directly inside \node_modules.
Might be the side effect of #317
When I build for windows using the CLI I get the following messages
λ cordova build windows
ENV var MSBUILDDIR is set C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin
Building project: D:\M - AEROMETRIX\E - ProductDesign\G - Tablet\Cordova\AexPAD\platforms\windows\CordovaApp.Windows10.jsproj
Configuration : debug
Platform : anycpu
Buildflags : /p:AppxBundle=Never
MSBuildTools : C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin
buildProject spawn: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\msbuild [ 'D:\M - AEROMETRIX\E - ProductDesign\G - Tablet\Cordova\AexPAD\platforms\windows\CordovaApp.Windows10.jsproj',
'/clp:NoSummary;NoItemAndPropertyList;Verbosity=minimal',
'/nologo',
'/p:Configuration=debug',
'/p:Platform=anycpu',
'/p:AppxBundle=Never' ] { stdio: 'inherit' }
prebuild.js: Patching platform10
**
How can I change the Configuration:debug; Paltform:anycpu and /nologo options ?
Thanks
The <description>
tag is set to a default value instead of the in the config.xml defined value. This is is a regression from cordova-windows 5.0.0.
macOS host machine
cordova-lib: 8.1.0
cordova-windows 6.0.0
A description is correctly set in config.xml:
config.xml
<description>
Demo
</description>
when running on a mac (or windows):
cordova prepare
platforms/windows/config.xml contains an additional description tag (with default content), in addition to the customized description tag
<description>
A sample Apache Cordova application that responds to the deviceready event.
</description>
[...]
<description>
Demo
</description>
The appxmanifest files contain only the default value instead of the set custom value:
platforms/windows/package.phone.appxmanifest
platforms/windows/package.windows.appxmanifest
platforms/windows/package.windows10.appxmanifest
- <Description>Demo</Description>
+ <Description>A sample Apache Cordova application that responds to the deviceready event.</Description>
- <m2:VisualElements Description="Demo" DisplayName="Demo">
+ <m2:VisualElements Description="A sample Apache Cordova application that responds to the deviceready event." DisplayName="Demo">
the correctly set description tag gets propagated.
happens only with cordova-windows 6.0.0 - doesn't happen when using cordova-windows 5.0.0 with an otherwise unchanged setup
happens on mac & windows - however this a serious problem, as the generated code could be committed by mistake
probable cause: in 6.0.0 the platforms/windows/cordova/defaults.xml
contains a default value for the desciption tag for the first time.
The wrong description value comes form the defaults.xml, however the <name>
and <author>
tags get processed correctly:
platforms/windows/cordova/defaults.xml
<description>
A sample Apache Cordova application that responds to the deviceready event.
</description>
On a system with no correct Visual Studio installed or path variables for MSBuild
discovery set, the build often stops with MSBuild v4.0 is not supported, aborting.
. It seems this is just an output, not a real error. This causes Paramedic not to fail properly although the build did not work as expected.
cordova platform list
Installed platforms: browser 5.0.3, ios 4.5.4, osx 4.0.1, windows 5.0.0
Available platforms: amazon-fireos, android, blackberry10, firefoxos, webos
cordova -v
5.4.0
I have tried this on Mac High Sierra as well as Windows 10
I want to be able to run an app with a pipe in its name for Windows similar like I can for Android.
During "Installing app" step I get this:
Add-AppxPackage : Deployment failed with HRESULT: 0x80073CF6, Package could not be registered. (Exception from HRESULT: 0x80073CF6)
NOTE: For additional information, look for [ActivityId] d145f98e-1c83-0003-9e62-50d1831cd501 in the Event Log or use the command line Get-AppPackageLog -ActivityI
d145f98e-1c83-0003-9e62-50d1831cd501
At E:\Projects\throwaway\cordovaPipeName\platforms\windows\AppPackages\CordovaApp.Windows10_1.0.0.0_anycpu_debug_Test\Add-AppDevPackage.ps1:396 char:13
+ Add-AppxPackage -Path $DeveloperPackagePath.FullName -For ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : WriteError: (E:\Projects\thr...ycpu_debug.appx:String) [Add-AppxPackage], IOException
+ FullyQualifiedErrorId : DeploymentError,Microsoft.Windows.Appx.PackageManager.Commands.AddAppxPackageCommand
Error: Could not install the app.
Starting application...
Get-AppxPackageManifest : Cannot process argument transformation on parameter 'Package'. Object reference not set to an instance of an object.
At E:\Projects\throwaway\cordovaPipeName\platforms\windows\cordova\lib\WindowsStoreAppUtils.ps1:157 char:41
+ $manifest = Get-appxpackagemanifest $package
+ ~~~~~~~~
+ CategoryInfo : InvalidData: (:) [Get-AppxPackageManifest], ParameterBindingArgumentTransformationException
+ FullyQualifiedErrorId : ParameterArgumentTransformationError,Microsoft.Windows.Appx.PackageManager.Commands.GetAppxPackageManifestCommand
ActivateApplication: !
Exception calling "ActivateApplication" with "4" argument(s): "Value does not fall within the expected range."
At E:\Projects\throwaway\cordovaPipeName\platforms\windows\cordova\lib\WindowsStoreAppUtils.ps1:164 char:5
+ $appActivator.ActivateApplication($applicationUserModelId,$null,[ ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [], MethodInvocationException
+ FullyQualifiedErrorId : ArgumentException
E:\Projects\throwaway\cordovaPipeName ([email protected])
λ cordova platform list
Installed platforms:
android 8.0.0
windows 7.0.0
Available platforms:
browser ^6.0.0
electron ^1.0.0
ios ^5.0.0
osx ^5.0.0
E:\Projects\throwaway\cordovaPipeName ([email protected])
λ cat config.xml
<?xml version='1.0' encoding='utf-8'?>
<widget id="io.cordova.hellocordova" version="1.0.0" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0">
<name>Hello|Cordova</name>
<description>
A sample Apache Cordova application that responds to the deviceready event.
</description>
<author email="[email protected]" href="http://cordova.io">
Apache Cordova Team
</author>
<content src="index.html" />
<plugin name="cordova-plugin-whitelist" spec="1" />
<access origin="*" />
<allow-intent href="http://*/*" />
<allow-intent href="https://*/*" />
<allow-intent href="tel:*" />
<allow-intent href="sms:*" />
<allow-intent href="mailto:*" />
<allow-intent href="geo:*" />
<platform name="android">
<allow-intent href="market:*" />
</platform>
<platform name="ios">
<allow-intent href="itms:*" />
<allow-intent href="itms-apps:*" />
</platform>
</widget>
λ cordova run android
Checking Java JDK and Android SDK versions
ANDROID_SDK_ROOT=undefined (recommended setting)
ANDROID_HOME=C:\Users\Jan\AppData\Local\Android\sdk (DEPRECATED)
Subproject Path: CordovaLib
Subproject Path: app
> Task :app:preBuild UP-TO-DATE
> Task :CordovaLib:preBuild UP-TO-DATE
> Task :CordovaLib:preDebugBuild UP-TO-DATE
> Task :CordovaLib:checkDebugManifest UP-TO-DATE
> Task :CordovaLib:processDebugManifest UP-TO-DATE
> Task :app:preDebugBuild UP-TO-DATE
> Task :CordovaLib:compileDebugAidl NO-SOURCE
> Task :app:compileDebugAidl NO-SOURCE
> Task :CordovaLib:packageDebugRenderscript NO-SOURCE
> Task :app:compileDebugRenderscript UP-TO-DATE
> Task :app:checkDebugManifest UP-TO-DATE
> Task :app:generateDebugBuildConfig UP-TO-DATE
> Task :app:prepareLintJar UP-TO-DATE
> Task :app:generateDebugSources UP-TO-DATE
> Task :CordovaLib:compileDebugRenderscript UP-TO-DATE
> Task :CordovaLib:generateDebugBuildConfig UP-TO-DATE
> Task :CordovaLib:generateDebugResValues UP-TO-DATE
> Task :CordovaLib:generateDebugResources UP-TO-DATE
> Task :CordovaLib:packageDebugResources UP-TO-DATE
> Task :CordovaLib:generateDebugRFile UP-TO-DATE
> Task :CordovaLib:prepareLintJar UP-TO-DATE
> Task :CordovaLib:generateDebugSources UP-TO-DATE
> Task :CordovaLib:javaPreCompileDebug UP-TO-DATE
> Task :CordovaLib:compileDebugJavaWithJavac UP-TO-DATE
> Task :CordovaLib:processDebugJavaRes NO-SOURCE
> Task :CordovaLib:transformClassesAndResourcesWithPrepareIntermediateJarsForDebug UP-TO-DATE
> Task :app:javaPreCompileDebug UP-TO-DATE
> Task :app:mainApkListPersistenceDebug UP-TO-DATE
> Task :app:generateDebugResValues UP-TO-DATE
> Task :app:generateDebugResources UP-TO-DATE
> Task :app:mergeDebugResources UP-TO-DATE
> Task :app:createDebugCompatibleScreenManifests UP-TO-DATE
> Task :app:processDebugManifest UP-TO-DATE
> Task :app:processDebugResources UP-TO-DATE
> Task :app:compileDebugJavaWithJavac UP-TO-DATE
> Task :app:compileDebugNdk NO-SOURCE
> Task :app:compileDebugSources UP-TO-DATE
> Task :app:mergeDebugShaders UP-TO-DATE
> Task :app:compileDebugShaders UP-TO-DATE
> Task :app:generateDebugAssets UP-TO-DATE
> Task :CordovaLib:mergeDebugShaders UP-TO-DATE
> Task :CordovaLib:compileDebugShaders UP-TO-DATE
> Task :CordovaLib:generateDebugAssets UP-TO-DATE
> Task :CordovaLib:packageDebugAssets UP-TO-DATE
> Task :app:mergeDebugAssets UP-TO-DATE
> Task :app:validateSigningDebug UP-TO-DATE
> Task :app:signingConfigWriterDebug UP-TO-DATE
> Task :app:transformClassesWithDexBuilderForDebug UP-TO-DATE
> Task :app:transformDexArchiveWithExternalLibsDexMergerForDebug UP-TO-DATE
> Task :app:transformDexArchiveWithDexMergerForDebug UP-TO-DATE
> Task :app:mergeDebugJniLibFolders UP-TO-DATE
> Task :CordovaLib:compileDebugNdk NO-SOURCE
> Task :CordovaLib:mergeDebugJniLibFolders UP-TO-DATE
> Task :CordovaLib:transformNativeLibsWithMergeJniLibsForDebug UP-TO-DATE
> Task :CordovaLib:transformNativeLibsWithIntermediateJniLibsForDebug UP-TO-DATE
> Task :app:transformNativeLibsWithMergeJniLibsForDebug UP-TO-DATE
> Task :app:processDebugJavaRes NO-SOURCE
> Task :app:transformResourcesWithMergeJavaResForDebug UP-TO-DATE
> Task :app:packageDebug UP-TO-DATE
> Task :app:assembleDebug UP-TO-DATE
> Task :app:cdvBuildDebug UP-TO-DATE
BUILD SUCCESSFUL in 6s
42 actionable tasks: 42 up-to-date
Built the following apk(s):
E:\Projects\throwaway\cordovaPipeName\platforms\android\app\build\outputs\apk\debug\app-debug.apk
Checking Java JDK and Android SDK versions
ANDROID_SDK_ROOT=undefined (recommended setting)
ANDROID_HOME=C:\Users\Jan\AppData\Local\Android\sdk (DEPRECATED)
No target specified, deploying to device '02e7f7e9215da7f8'.
Using apk: E:\Projects\throwaway\cordovaPipeName\platforms\android\app\build\outputs\apk\debug\app-debug.apk
Package name: io.cordova.hellocordova
LAUNCH SUCCESS
E:\Projects\throwaway\cordovaPipeName ([email protected])
λ cordova run windows
ENV var MSBUILDDIR is set C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin
Building project: E:\Projects\throwaway\cordovaPipeName\platforms\windows\CordovaApp.Windows10.jsproj
Configuration : debug
Platform : anycpu
Buildflags : /p:AppxBundle=Never
MSBuildTools : C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin
buildProject spawn: C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\msbuild [
'E:\\Projects\\throwaway\\cordovaPipeName\\platforms\\windows\\CordovaApp.Windows10.jsproj',
'/clp:NoSummary;NoItemAndPropertyList;Verbosity=minimal',
'/nologo',
'/p:Configuration=debug',
'/p:Platform=anycpu',
'/p:AppxBundle=Never'
] { stdio: 'inherit' }
prebuild.js: Patching platform `10`
- Injected `base.js` reference to `/www/index.html`
- Removing /( *)(<script\s+(?:type="text\/javascript"\s+)?src="\/\/Microsoft.WinJS.2.0\/js\/base.js">\s*<\/script>)(\s*)/ from /www/index.html
- Removing /( *)(<script\s+(?:type="text\/javascript"\s+)?src="\/\/Microsoft.Phone.WinJS.2.1\/js\/base.js">\s*<\/script>)(\s*)/ from /www/index.html
CordovaApp.Windows10 -> E:\Projects\throwaway\cordovaPipeName\platforms\windows\AppPackages\CordovaApp.Windows10_1.0.0.0_anycpu_debug_Test\CordovaApp.Windows10_1.0.0.0_anycpu
_debug.appx
Deploying windows10 package to device:
E:\Projects\throwaway\cordovaPipeName\platforms\windows\AppPackages\CordovaApp.Windows10_1.0.0.0_anycpu_debug_Test\CordovaApp.Windows10_1.0.0.0_anycpu_debug.appx
Attempting to uninstall previous application version...
Attempting to install application...
Found package: E:\Projects\throwaway\cordovaPipeName\platforms\windows\AppPackages\CordovaApp.Windows10_1.0.0.0_anycpu_debug_Test\CordovaApp.Windows10_1.0.0.0_anycpu_debug.appx
Installing app...
Add-AppxPackage : Deployment failed with HRESULT: 0x80073CF6, Package could not be registered. (Exception from HRESULT: 0x80073CF6)
NOTE: For additional information, look for [ActivityId] d145f98e-1c83-0003-9e62-50d1831cd501 in the Event Log or use the command line Get-AppPackageLog -ActivityID
d145f98e-1c83-0003-9e62-50d1831cd501
At E:\Projects\throwaway\cordovaPipeName\platforms\windows\AppPackages\CordovaApp.Windows10_1.0.0.0_anycpu_debug_Test\Add-AppDevPackage.ps1:396 char:13
+ Add-AppxPackage -Path $DeveloperPackagePath.FullName -For ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : WriteError: (E:\Projects\thr...ycpu_debug.appx:String) [Add-AppxPackage], IOException
+ FullyQualifiedErrorId : DeploymentError,Microsoft.Windows.Appx.PackageManager.Commands.AddAppxPackageCommand
Error: Could not install the app.
Starting application...
Get-AppxPackageManifest : Cannot process argument transformation on parameter 'Package'. Object reference not set to an instance of an object.
At E:\Projects\throwaway\cordovaPipeName\platforms\windows\cordova\lib\WindowsStoreAppUtils.ps1:157 char:41
+ $manifest = Get-appxpackagemanifest $package
+ ~~~~~~~~
+ CategoryInfo : InvalidData: (:) [Get-AppxPackageManifest], ParameterBindingArgumentTransformationException
+ FullyQualifiedErrorId : ParameterArgumentTransformationError,Microsoft.Windows.Appx.PackageManager.Commands.GetAppxPackageManifestCommand
ActivateApplication: !
Exception calling "ActivateApplication" with "4" argument(s): "Value does not fall within the expected range."
At E:\Projects\throwaway\cordovaPipeName\platforms\windows\cordova\lib\WindowsStoreAppUtils.ps1:164 char:5
+ $appActivator.ActivateApplication($applicationUserModelId,$null,[ ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [], MethodInvocationException
+ FullyQualifiedErrorId : ArgumentException
The CordovaApp.Windows10.jsproj
template file has a hard-coded TargetPlatformVersion
, which currently seems to be set to 10.0.10240.0
:
<PropertyGroup>
<TargetPlatformIdentifier>UAP</TargetPlatformIdentifier>
<TargetPlatformVersion>10.0.10240.0</TargetPlatformVersion>
<TargetPlatformMinVersion>10.0.10240.0</TargetPlatformMinVersion>
<MinimumVisualStudioVersion>14.0</MinimumVisualStudioVersion>
<UapDefaultAssetScale>100</UapDefaultAssetScale>
</PropertyGroup>
However, when I try to build my project, which should target 10.0.15063.0
, I get build failures as the wrong platform version is targeted and the SDK for this version is not available to Visual Studio:
D:\MyApp>cordova build windows --arch=x86
ENV var VSINSTALLDIR is set C:\Program Files (x86)\Programming\Microsoft Visual Studio 2017
Building project: D:\MyApp\platforms\windows\CordovaApp.Windows10.jsproj
Configuration : debug
Platform : x86
Buildflags : /p:AppxBundle=Never
MSBuildTools : C:\Program Files (x86)\Programming\Microsoft Visual Studio 2017\MSBuild\15.0\Bin
buildProject spawn: C:\Program Files (x86)\Programming\Microsoft Visual Studio 2017\MSBuild\15.0\Bin\msbuild [ 'D:\\MyApp\\platforms\\windows\\CordovaApp.Windows10.jsproj',
'/clp:NoSummary;NoItemAndPropertyList;Verbosity=minimal',
'/nologo',
'/p:Configuration=debug',
'/p:Platform=x86',
'/p:AppxBundle=Never' ] { stdio: 'inherit' }
C:\Program Files (x86)\Programming\Microsoft Visual Studio 2017\MSBuild\Microsoft\VisualStudio\v15.0\JavaScript\Microsoft.VisualStudio.JavaScript.UAP.targets(84,3): error : "
10.0.10240.0" is not a supported value for TargetPlatformVersion. Please change it on the Project Property page. [D:\MyApp\platforms\windows\CordovaApp.Windows10.jsproj]
No valid MSBuild was detected for the selected target: Error: C:\Program Files (x86)\Programming\Microsoft Visual Studio 2017\MSBuild\15.0\Bin\msbuild.exe: Command failed with
exit code 1
I can fix this by manually editing platforms\windows\CordovaApp.Windows10.jsproj
to change this line, but I was under the impression that anything in the 'platforms' folder shouldn't be touched, as it may get replaced when building/cleaning/updating.
There are various settings that can be added to config.xml
that look like they should influence this, but none of them seem to resolve the issue:
<preference name="windows-target-version" value="10.0" />
<preference name="windows-appx-target" value="uap" />
<preference name="windows-phone-target-version" value="10.0" />
<preference name="windows-phone-target-platform-version" value="10.0.15063.0" />
<preference name="Windows.Universal-MinVersion" value="10.0.15063.0" />
<preference name="Windows.Mobile-MinVersion" value="10.0.15063.0" />
I would expect that using one of these settings, or a new setting for this specific purpose, would ensure the correct build is performed.
I have been able to fix this by manually editing the file, but this doesn't appear to be a sustainable solution for the reasons given.
I have logged this as a feature request, but it might actually be considered a bug.
The basic issue is to provide a way to tell Visual Studio to build using the correct SDK, and as there appear to be settings to control this that aren't being applied in this instance. If the existing settings are not working as intended, this is a bug. If this is not currently intended to be configurable, then this is a feature request.
Or, if there is already some way to achieve this that I have been unable to find via the online documentation 1, 2, then perhaps this is a documentation bug.
The below link for 'Windows Platform Guide' in README.md is leading to Page Not Found (404),
http://cordova.apache.org/docs/en/latest/guide/platforms/win8/index.html
cordova build windows
and cordova run windows
do not report an error even when the build clearly failed:
https://travis-ci.org/janpio/cordova-windows-ci/builds/555130991
...
Running command: reg query HKLM\SOFTWARE\Microsoft\Microsoft SDKs\Windows /s /v InstallationFolder /reg:32
Command finished with error code 0: reg query,HKLM\SOFTWARE\Microsoft\Microsoft SDKs\Windows,/s,/v,InstallationFolder,/reg:32
buildProject spawn: C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin\msbuild [ 'C:\\Users\\travis\\build\\janpio\\cordova-windows-ci\\platforms\\windows\\CordovaApp.Windows10.jsproj',
'/clp:NoSummary;NoItemAndPropertyList;Verbosity=minimal',
'/nologo',
'/p:Configuration=debug',
'/p:Platform=anycpu',
'/p:AppxBundle=Never' ] { stdio: 'inherit' }
Running command: C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin\msbuild C:\Users\travis\build\janpio\cordova-windows-ci\platforms\windows\CordovaApp.Windows10.jsproj /clp:NoSummary;NoItemAndPropertyList;Verbosity=minimal /nologo /p:Configuration=debug /p:Platform=anycpu /p:AppxBundle=Never
Command finished with error code 1: C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin\msbuild C:\Users\travis\build\janpio\cordova-windows-ci\platforms\windows\CordovaApp.Windows10.jsproj,/clp:NoSummary;NoItemAndPropertyList;Verbosity=minimal,/nologo,/p:Configuration=debug,/p:Platform=anycpu,/p:AppxBundle=Never
CordovaError: No valid MSBuild was detected for the selected target: Error: C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin\msbuild: Command failed with exit code 1
at C:\Users\travis\build\janpio\cordova-windows-ci\platforms\windows\cordova\lib\build.js:83:29
at _rejected (C:\Users\travis\build\janpio\cordova-windows-ci\node_modules\q\q.js:864:24)
at C:\Users\travis\build\janpio\cordova-windows-ci\node_modules\q\q.js:890:30
at Promise.when (C:\Users\travis\build\janpio\cordova-windows-ci\node_modules\q\q.js:1142:31)
at Promise.promise.promiseDispatch (C:\Users\travis\build\janpio\cordova-windows-ci\node_modules\q\q.js:808:41)
at C:\Users\travis\build\janpio\cordova-windows-ci\node_modules\q\q.js:624:44
at runSingle (C:\Users\travis\build\janpio\cordova-windows-ci\node_modules\q\q.js:137:13)
at flush (C:\Users\travis\build\janpio\cordova-windows-ci\node_modules\q\q.js:125:13)
at process._tickCallback (internal/process/next_tick.js:61:11)
The command "cordova build windows --verbose" exited with 0.
...
Running command: reg query HKLM\SOFTWARE\Microsoft\Microsoft SDKs\Windows /s /v InstallationFolder /reg:32
Command finished with error code 0: reg query,HKLM\SOFTWARE\Microsoft\Microsoft SDKs\Windows,/s,/v,InstallationFolder,/reg:32
buildProject spawn: C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin\msbuild [ 'C:\\Users\\travis\\build\\janpio\\cordova-windows-ci\\platforms\\windows\\CordovaApp.Windows10.jsproj',
'/clp:NoSummary;NoItemAndPropertyList;Verbosity=minimal',
'/nologo',
'/p:Configuration=debug',
'/p:Platform=anycpu',
'/p:AppxBundle=Never' ] { stdio: 'inherit' }
Running command: C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin\msbuild C:\Users\travis\build\janpio\cordova-windows-ci\platforms\windows\CordovaApp.Windows10.jsproj /clp:NoSummary;NoItemAndPropertyList;Verbosity=minimal /nologo /p:Configuration=debug /p:Platform=anycpu /p:AppxBundle=Never
prebuild.js: Patching platform `10`
- Injected `base.js` reference to `/www/index.html`
- Removing /( *)(<script\s+(?:type="text\/javascript"\s+)?src="\/\/Microsoft.WinJS.2.0\/js\/base.js">\s*<\/script>)(\s*)/ from /www/index.html
- Removing /( *)(<script\s+(?:type="text\/javascript"\s+)?src="\/\/Microsoft.Phone.WinJS.2.1\/js\/base.js">\s*<\/script>)(\s*)/ from /www/index.html
C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\Microsoft\VisualStudio\v15.0\AppxPackage\Microsoft.AppXPackage.Targets(2519,5): warning APPX0105: Cannot import the key file 'CordovaApp_TemporaryKey.pfx'. The key file may be password protected. To correct this, try to import the certificate manually into the current user’s personal certificate store. [C:\Users\travis\build\janpio\cordova-windows-ci\platforms\windows\CordovaApp.Windows10.jsproj]
C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\Microsoft\VisualStudio\v15.0\AppxPackage\Microsoft.AppXPackage.Targets(2519,5): warning APPX0107: The certificate specified is not valid for signing. For more information about valid certificates, see http://go.microsoft.com/fwlink/?LinkID=241478. [C:\Users\travis\build\janpio\cordova-windows-ci\platforms\windows\CordovaApp.Windows10.jsproj]
C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\Microsoft\VisualStudio\v15.0\AppxPackage\Microsoft.AppXPackage.Targets(2638,5): error APPX0002: Task 'ValidateAppxManifest' failed. Retrieving the COM class factory for component with CLSID {5842A140-FF9F-4166-8F5C-62F5B7B0C781} failed due to the following error: 8007045a A dynamic link library (DLL) initialization routine failed. (Exception from HRESULT: 0x8007045A). [C:\Users\travis\build\janpio\cordova-windows-ci\platforms\windows\CordovaApp.Windows10.jsproj]
C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\Microsoft\VisualStudio\v15.0\AppxPackage\Microsoft.AppXPackage.Targets(2638,5): error APPX0002: [C:\Users\travis\build\janpio\cordova-windows-ci\platforms\windows\CordovaApp.Windows10.jsproj]
Command finished with error code 1: C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin\msbuild C:\Users\travis\build\janpio\cordova-windows-ci\platforms\windows\CordovaApp.Windows10.jsproj,/clp:NoSummary;NoItemAndPropertyList;Verbosity=minimal,/nologo,/p:Configuration=debug,/p:Platform=anycpu,/p:AppxBundle=Never
CordovaError: No valid MSBuild was detected for the selected target: Error: C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin\msbuild: Command failed with exit code 1
at C:\Users\travis\build\janpio\cordova-windows-ci\platforms\windows\cordova\lib\build.js:83:29
at _rejected (C:\Users\travis\build\janpio\cordova-windows-ci\node_modules\q\q.js:864:24)
at C:\Users\travis\build\janpio\cordova-windows-ci\node_modules\q\q.js:890:30
at Promise.when (C:\Users\travis\build\janpio\cordova-windows-ci\node_modules\q\q.js:1142:31)
at Promise.promise.promiseDispatch (C:\Users\travis\build\janpio\cordova-windows-ci\node_modules\q\q.js:808:41)
at C:\Users\travis\build\janpio\cordova-windows-ci\node_modules\q\q.js:624:44
at runSingle (C:\Users\travis\build\janpio\cordova-windows-ci\node_modules\q\q.js:137:13)
at flush (C:\Users\travis\build\janpio\cordova-windows-ci\node_modules\q\q.js:125:13)
at process._tickCallback (internal/process/next_tick.js:61:11)
The command "cordova run windows --verbose" exited with 0.
getting following error
tried all possible options - npm set registry https //registry.npmjs.org/ . installed Git
tried checking - https://registry.npmjs.org/cardova/cordova/ nothing exists at this location
ERROR -->
npm ERR! code E404
npm ERR! 404 Not Found: cordova@latest
npm ERR! A complete log of this run can be found in:
Changes to the config.xml should be reflected in the AppxManifest.xml / package.*.appxmanifest file after running the build command.
Adding for example this configuration to the main config.xml:
<platform name="windows">
<config-file parent="/Package/Capabilities" target="package.appxmanifest">
<Capability Name="allJoyn" />
</config-file>
</platform>
And then building the application with cordova build windows -- --archs="x64"
will:
Running the cordova build windows -- --archs="x64"
command a second time,
The build command needs to be run two times before the value is actually applied to the appxmanifest file.
Windows 10
Cordova 8.1.2
Cordova-windows 6.0.1 and 7.0.0
Hello,
I have an application which needs to run in local mode. However, as soon as I enable local mode in the config.xml by setting <preference name="WindowsDefaultUriPrefix" value="ms-appx://" />
, scrolling does not work anymore (scrollbar is also not displayed):
Changing the mode back to Remote, and the scrolling works again.
Here is a repository with a simple example application:
https://github.com/dominic-simplan/cordova-scrolling
Is this a bug or am I missing some additional setting?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.