maxim-lobanov / setup-xcode

Set up your GitHub Actions workflow with a specific version of Xcode
MIT License
280 stars 28 forks source link

Error: Could not find Xcode version '14.3.1', that should be available #77

Closed geeron closed 6 months ago

geeron commented 6 months ago

Trying to use xcode version '14.3.1' that should be available, but get error below. Setting the version to '14.2.0' works

ios-deployment:
    runs-on: macos-latest
    steps:
      - uses: maxim-lobanov/setup-xcode@v1
        with:
          xcode-version: '14.3.1'

Error:

Run maxim-lobanov/setup-xcode@v1
Switching Xcode to version '14.3.1'...
Available versions:
┌─────────┬──────────┬─────────────┬─────────────┬────────┬──────────────────────────────────┐
│ (index) │ version  │ buildNumber │ releaseType │ stable │               path               │
├─────────┼──────────┼─────────────┼─────────────┼────────┼──────────────────────────────────┤
│    0    │ '14.2.0' │   '14C18'   │    'GM'     │  true  │  '/Applications/Xcode_14.2.app'  │
│    1    │ '14.1.0' │  '14B47b'   │    'GM'     │  true  │  '/Applications/Xcode_14.1.app'  │
│    2    │ '14.0.1' │  '14A400'   │    'GM'     │  true  │ '/Applications/Xcode_14.0.1.app' │
│    3    │ '13.4.1' │  '13F[10](https://github.com/hurtigruten/mobile.application/actions/runs/8077394084/job/22067643793#step:2:11)0'   │    'GM'     │  true  │ '/Applications/Xcode_[13](https://github.com/hurtigruten/mobile.application/actions/runs/8077394084/job/22067643793#step:2:14).4.1.app' │
│    4    │ '13.3.1' │  '13E500a'  │    'GM'     │  true  │ '/Applications/Xcode_13.3.1.app' │
│    5    │ '13.2.1' │  '13C100'   │    'GM'     │  true  │ '/Applications/Xcode_13.2.1.app' │
│    6    │ '13.1.0' │ '13A1030d'  │    'GM'     │  true  │  '/Applications/Xcode_13.1.app'  │
└─────────┴──────────┴─────────────┴─────────────┴────────┴──────────────────────────────────┘
Error: Could not find Xcode version that satisfied version spec: '14.3.1'
maxim-lobanov commented 6 months ago

Hi @geeron ,

You use macos-latest in your workflow YAML. Based on GitHub Actions docs, macos-latest still points to MacOS 12 and based on docs macOS 12 doesn't contain Xcode > 14.2.

If you want to use Xcode 14.3.1, you should use macos-13 or macos-14 labels:

geeron commented 6 months ago

Hi @maxim-lobanov, appreciate your swift reply! Thanks so much for the detailed clarification :)