I recently learned that the Italian government is only allowed to buy proprietary software after it has determined that there isn't a free software option. IIUC they're also required to publish any code they write (or commission to be written) under a free license.
However, at least as far as I know Windows, Office, et al are being used everywhere in public administration, and even e.g. public transport apps are proprietary. What gives?