mirror of
https://github.com/kovidgoyal/kitty.git
synced 2026-08-03 22:25:57 +00:00
Dont import ctypes unless type checking
ctypes in Python 3.14 is broken on Intel macs. It uses libffi which is broken on Intel macs without extra security entitlements. At least com.apple.security.cs.allow-unsigned-executable-memory and possibly com.apple.security.cs.disable-executable-page-protection Rather than add these entitlements, we simply do not import ctypes as it is not actually used on macs anyway. Fixes #9643
This commit is contained in:
parent
c2447abd30
commit
b9d7a661ce
2 changed files with 3 additions and 1 deletions
|
|
@ -174,6 +174,8 @@ Detailed list of changes
|
|||
|
||||
- Fix a regression that broke accept anyway shortcut in the paste confirmation dialog (:pull:`9640`)
|
||||
|
||||
- Fix kitty hanging on startup on Intel macs (:iss:`9643`)
|
||||
|
||||
0.46.0 [2026-03-11]
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,6 @@
|
|||
#!/usr/bin/env python
|
||||
# License: GPL v3 Copyright: 2016, Kovid Goyal <kovid at kovidgoyal.net>
|
||||
|
||||
import ctypes
|
||||
import os
|
||||
import sys
|
||||
from collections.abc import Callable, Generator
|
||||
|
|
@ -218,6 +217,7 @@ def set_font_family(opts: Options | None = None, override_font_size: float | Non
|
|||
|
||||
|
||||
if TYPE_CHECKING:
|
||||
import ctypes
|
||||
CBufType = ctypes.Array[ctypes.c_ubyte]
|
||||
else:
|
||||
CBufType = None
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue