Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CMake 3.31 MSI package brocken on windows-2022 image #11174

Closed
2 of 15 tasks
SimeonEhrig opened this issue Dec 12, 2024 · 7 comments
Closed
2 of 15 tasks

CMake 3.31 MSI package brocken on windows-2022 image #11174

SimeonEhrig opened this issue Dec 12, 2024 · 7 comments

Comments

@SimeonEhrig
Copy link

Description

I cannot uninstall the cmake with chocolatey nor install a different version with uninstalling before.

Platforms affected

  • Azure DevOps
  • GitHub Actions - Standard Runners
  • GitHub Actions - Larger Runners

Runner images affected

  • Ubuntu 20.04
  • Ubuntu 22.04
  • Ubuntu 24.04
  • macOS 12
  • macOS 13
  • macOS 13 Arm64
  • macOS 14
  • macOS 14 Arm64
  • macOS 15
  • macOS 15 Arm64
  • Windows Server 2019
  • Windows Server 2022

Image version and build link

Image: windows-2022
Version: 20241201.2.0

Is it regression?

yes, Image: windows-2022, Version: 20241125.1.0

Expected behavior

CMake can be uninstalled.

Actual behavior

$ choco uninstall cmake.install
Chocolatey v2.4.0
Uninstalling the following packages:
cmake.install

cmake.install v3.31.1
 Running auto uninstaller...
 [AutoUninstaller] The installation source for this product is not available. Verify that the source exists and that you can access it.
 [AutoUninstaller] 
 [AutoUninstaller] 
 Auto uninstaller failed. Please remove machine installation manually.
 Exit code was 1612
 cmake.install has been successfully uninstalled.

Chocolatey uninstalled 1/1 packages. 
 See the log for details (C:\ProgramData\chocolatey\logs\chocolatey.log).

Warnings:
 - cmake.install -  Auto uninstaller failed. Please remove machine installation manually.
 Exit code was 1612
$ choco install cmake.install --allow-downgrade --no-progress --version 3.25
Chocolatey v2.4.0
Installing the following packages:
cmake.install
By installing, you accept licenses for the packages.
Downloading package from source 'https://community.chocolatey.org/api/v2/'
cmake.install v3.25.0 [Approved]
cmake.install package files install completed. Performing other installation steps.
Installing 64-bit cmake.install...
WARNING: Generic MSI Error. This is a local environment error, not an issue with a package or the MSI itself - it could mean a pending reboot is necessary prior to install or something else (like the same version is already installed). Please see MSI log if available. If not, try again adding '--install-arguments="'/l*v c:\cmake.install_msi_install.log'"'. Then search the MSI Log for "Return Value 3" and look above that for the error.
ERROR: Running ["C:\Windows\System32\msiexec.exe" /i "C:\ProgramData\chocolatey\lib\cmake.install\tools\cmake-3.25.0-windows-x86_64.msi" /qn /norestart /l*v "C:\Users\runneradmin\AppData\Local\Temp\chocolatey\cmake.install.3.25.0.MsiInstall.log"] was not successful. Exit code was '1603'. Exit code indicates the following: Generic MSI Error. This is a local environment error, not an issue with a package or the MSI itself - it could mean a pending reboot is necessary prior to install or something else (like the same version is already installed). Please see MSI log if available. If not, try again adding '--install-arguments="'/l*v c:\cmake.install_msi_install.log'"'. Then search the MSI Log for "Return Value 3" and look above that for the error..
The install of cmake.install was NOT successful.
Error while running 'C:\ProgramData\chocolatey\lib\cmake.install\tools\chocolateyInstall.ps1'.
 See log for details.
Chocolatey installed 0/1 packages. 1 packages failed.
 See the log for details (C:\ProgramData\chocolatey\logs\chocolatey.log).
Failures
 - cmake.install (exited 1603) - Error while running 'C:\ProgramData\chocolatey\lib\cmake.install\tools\chocolateyInstall.ps1'.
 See log for details.

Repro steps

Create the following workflow:

name: windowsJob
on: [push, pull_request]
jobs:
    uninstall-cmake:
        runs-on: windows-2022
        steps:
            - run: cmake --version
            - run: choco uninstall cmake.install
@Prabhatkumar59
Copy link
Contributor

Hi @SimeonEhrig - Thank you for bringing this issue to our attention. We are looking into this issue and will update you after investigating.

hydai added a commit to WasmEdge/WasmEdge that referenced this issue Dec 13, 2024
See: actions/runner-images#11174
It's not possible to install specific version of cmake on the
GitHub Windows Image currently.

Signed-off-by: hydai <[email protected]>
hydai added a commit to WasmEdge/WasmEdge that referenced this issue Dec 13, 2024
See: actions/runner-images#11174
It's not possible to install specific version of cmake on the
GitHub Windows Image currently.

Signed-off-by: hydai <[email protected]>
@Prabhatkumar59
Copy link
Contributor

Hi @SimeonEhrig - As I can see from actual behaviour that the error codes 1612 and 1603 suggest issues with the MSI installer cache or corrupted installation metadata.

For this:-
-Could you please try checking once by Cleaning the Registry Entries by removing MSI installer metadata using wmic

wmic product where "name like 'CMake%'" call uninstall /nointeractive

-Also please try once by cleaning Chocolatey package Metadata:-

choco uninstall cmake.install --force
Please check and feel free to update. In meantime, we are checking more into this. Thanks!

@SimeonEhrig
Copy link
Author

This workaround works. Also choco uninstall cmake.install is working without the --force flag. But deleting the MSI installer metadata can take up 14 minutes. Therefore it is no practical workaround and it needs to be fixed.

Here is my test code: SimeonEhrig/github-actions-sandbox#8

@Prabhatkumar59
Copy link
Contributor

Hey @SimeonEhrig - Thanks for your input! I will look into your test code once and will update you.

@Prabhatkumar59
Copy link
Contributor

Hi @SimeonEhrig - Could you also please try to update your sync process and check once as new image version(20241215.1) has been rolled out. In mean time, we are checking more into this. Thanks!

@vidyasagarnimmagaddi
Copy link
Contributor

Hi @SimeonEhrig ,
We were able to reproduce the Workflow provided . kindly try to build the same.

name: windowsJob
on: [push, pull_request]
jobs:
    uninstall-cmake:
        runs-on: windows-2022
        steps:
            - run: cmake --version
            - run: choco uninstall cmake.install

image

@vidyasagarnimmagaddi
Copy link
Contributor

Hi @SimeonEhrig ,We were able to reproduce the Workflow provided , as we haven't heard from you, we were closing this issue. thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants