2025, Sep 18 09:00
Fix msstore CLI 'could not find a project publisher' in CI for Python/Kivy apps by publishing the MSIX with the app id
Resolve the msstore CLI 'could not find a project publisher' error in CI. Publish MSIX with -id to ensure reliable Microsoft Store CI/CD for Python/Kivy apps.
Publishing a Python/Kivy app to the Microsoft Store from CI can stumble on subtle details. A common case: the msstore CLI starts fine, recognizes the CI environment, but fails to associate a publisher with the build output directory and stops with a cryptic message. Below is a compact walkthrough of the failure pattern and the fix that gets the pipeline green.
Code example
The initial flow uses msstore reconfigure followed by a publish that tries to infer everything from the current directory:
msstore reconfigure --tenantId {TENANT_ID} --clientId {CLIENT_ID} --clientSecret {CLIENT_SECRET} --sellerId {SELLER_ID}
msstore publish -v -i .
The CLI starts, detects it runs in CI, and then exits with:
We could not find a project publisher for the project at 'D:\a\app-language\app-language\windows\dist'.
What’s actually going on
The tool cannot resolve a project publisher when pointed at the build output directory. In this scenario, the directory-based inference fails, even though the CI session itself is correctly detected. The result is a hard stop right before publishing.
Solution
Switch from directory inference to an explicit artifact. Provide the direct path to the MSIX you want to publish and pass the application id:
msstore publish "{ABS_MSIX_PATH}" -v -id {STORE_APP_ID}
This replaces the ambiguous directory target with a concrete MSIX file and gives the CLI exactly what it needs to push the package.
Why this matters
In automated pipelines, implicit discovery can break on small differences in how artifacts are laid out or named. Explicitly addressing the MSIX file makes the process deterministic, which is what you need for repeatable CI/CD. The CLI no longer has to guess what’s under the dist folder; it simply takes the stated package and publishes it under the provided id.
Practical takeaways
If the msstore CLI says it “could not find a project publisher” for your dist path, stop relying on directory inference. Use the absolute MSIX path and the -id argument. Keep reconfigure in place for credentials and seller association, but hand the publish step a concrete package. This small change prevents guesswork and eliminates a whole class of path-related failures in CI.
In short: be explicit about the artifact. Point msstore publish at the MSIX file and supply the app id. That’s enough to get the job done reliably.