# Ventura macOS version check fails

**URL:** <https://forum.juce.com/t/ventura-macos-version-check-fails/53411>\
**Category:** General JUCE discussion\
**Created:** [October 18, 2022, 12:43pm UTC](https://forum.juce.com/t/ventura-macos-version-check-fails/53411 "2022-10-18T12:43:15Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![gavinburke](https://avatars.discourse-cdn.com/v4/letter/g/e19adc/32.png) [@gavinburke](https://forum.juce.com/u/gavinburke)\
**Post date:** [October 18, 2022, 12:43pm UTC](https://forum.juce.com/t/ventura-macos-version-check-fails/53411/1 "2022-10-18T12:43:15Z")

</div>

Hey guys,

We have a recurring issue every time a major version of macOS is released, where by an operating system check in our code fails.

```auto
 if ((juce::SystemStats::getOperatingSystemType() & juce::SystemStats::MacOSX) != 0)
{
 //do some macOS specific stuff here...
}

```

A fix is to just add a line in getOperatingSystemType() switch to handle Ventura ( macOS 13 )

```auto
switch (major)
    {
        case 10:
        {
            jassert (minor > 2);
            return (OperatingSystemType) (minor + MacOSX_10_7 - 7);
        }

        case 11: return MacOS_11;
        case 12: return MacOS_12;
        case 13: return MacOS_13;
    }

```

This same bug comes up every time a major macOS version is released and causes our plugins to stop working. Is there anyway to future proof this?

---

<div class="post-metadata">

**Author:** ![reuk](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/reuk/32/21494_2.png) [@reuk](https://forum.juce.com/u/reuk)\
**Post date:** [October 18, 2022, 12:57pm UTC](https://forum.juce.com/t/ventura-macos-version-check-fails/53411/2 "2022-10-18T12:57:32Z")

</div>

That change is already present on develop:

> <https://github.com/juce-framework/JUCE/blob/41adf71cc70d8a201eccaf071725e168b95a6115/modules/juce_core/native/juce_mac_SystemStats.mm#L138>

Do you need a runtime check? Why not use `#if JUCE_MAC`?
