Skip to content

Conversation

@bruvzg
Copy link
Member

@bruvzg bruvzg commented Apr 9, 2020

Ignore process serial number (-psn_...) command line argument passed by macOS Gatekeeper.

PSN is only passed on the first start of the downloaded app (.app bundle with com.apple.quarantine extended file attribute), confuses Godot, causing it to load non-existent project instead of project manager.

Fixes #37713
Probably fixes #37446, fixes #35383 and fixes #36616?

@bruvzg bruvzg added bug platform:macos topic:editor topic:platforms cherrypick:3.x Considered for cherry-picking into a future 3.x release labels Apr 9, 2020
Copy link
Member

@Calinou Calinou left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There should be a comment so we know why this was added in the future 🙂

@bruvzg bruvzg force-pushed the macos_ignore_psn branch from 922426b to e92a14a Compare April 10, 2020 07:32
@akien-mga akien-mga added this to the 4.0 milestone Apr 10, 2020
@akien-mga
Copy link
Member

It's really a weird design for macOS to arbitrarily pass arguments to thirdparty processes that are not designed to handle them... I'm sure we're not the only ones to have issues with that (though our argument parsing is particularly bad right now, but we'll get to properly fixing #20000 eventually :)).

Anyway, this is hacky but seems like a good solution for now.

@akien-mga akien-mga merged commit 4c36feb into godotengine:master Apr 10, 2020
@akien-mga
Copy link
Member

Thanks!

@bruvzg bruvzg deleted the macos_ignore_psn branch April 10, 2020 08:46
@bruvzg
Copy link
Member Author

bruvzg commented Apr 10, 2020

It's really a weird design for macOS to arbitrarily pass arguments to thirdparty processes that are not designed to handle them...

This was the normal way to pass PSN to the Carbon apps (API deprecated in 10.8 and removed in 10.15), probably some of the old code accidentally get into the Gatekeeper.

I'm sure we're not the only ones to have issues with that...

For the reference, it's definitely known issue: Chromium, Qt, Firefox

@akien-mga
Copy link
Member

Cherry-picked for 3.2.2.

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

Projects

None yet

3 participants