Uploaded image for project: 'Apache Cordova'
  1. Apache Cordova
  2. CB-10394

config-file changes are not written to package.windows.appxmanifest

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 4.3.0
    • None
    • cordova-windows

    Description

      I've noticed that config-file changes defined in a plugin are not correctly written to package.windows.appxmanifest file. After a plugin import, the file does not contain these changes. The changes are correctly applied to the other appxmanifest files (phone, windows10, windows80).

      I've bested both with windows platform 4.3.0 as well as master and the problem exists in both branches.

      The problem is related to the appxmanifest caching mechanism. The package.windows.appxmanifest file is loaded early on to determine the package name (through jsprojManager.getPackageName()). The appxmanifest content is then cached in memory. Then, the config-file changes defined in the plugin.xml file are applied to the manifests and written to disk. They do not use the cached manifests from the earlier step,but rather load the files through a different code path. After that all previously cached appxmanifest instances are then written to disk, which effectively overwrites the content of package.windows.appxmanifest. Since this is the only manifest that gets loaded early on, this does not affect the other appxmanifest files.

      Attachments

        Activity

          People

            vladimir.kotikov Vladimir Kotikov
            biasmv Marco Biasini
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: