pyobjc-framework-MetalKit 12.2.2__tar.gz → 13.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (31) hide show
  1. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/Lib/MetalKit/_metadata.py +35 -10
  2. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/Lib/pyobjc_framework_MetalKit.egg-info/PKG-INFO +6 -6
  3. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/Lib/pyobjc_framework_MetalKit.egg-info/SOURCES.txt +2 -2
  4. pyobjc_framework_metalkit-13.0/Lib/pyobjc_framework_MetalKit.egg-info/pyobjc-build-info.txt +3 -0
  5. pyobjc_framework_metalkit-13.0/Lib/pyobjc_framework_MetalKit.egg-info/requires.txt +3 -0
  6. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/Modules/_MetalKit.m +9 -2
  7. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/Modules/_MetalKit_protocols.m +7 -5
  8. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/Modules/pyobjc-api.h +18 -4
  9. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/Modules/pyobjc-compat.h +0 -18
  10. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/PKG-INFO +6 -6
  11. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/PyObjCTest/test_mtkmodel.py +4 -1
  12. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/PyObjCTest/test_mtktextureloader.py +32 -1
  13. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/PyObjCTest/test_mtkview.py +2 -2
  14. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/metadata/MetalKit.fwinfo +1 -72
  15. pyobjc_framework_metalkit-12.2.2/metadata/raw/arm64-26.5.fwinfo → pyobjc_framework_metalkit-13.0/metadata/raw/arm64-27.fwinfo +10 -3
  16. pyobjc_framework_metalkit-12.2.2/metadata/raw/x86_64-26.5.fwinfo → pyobjc_framework_metalkit-13.0/metadata/raw/x86_64-27.fwinfo +10 -3
  17. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/pyobjc_setup.py +7 -7
  18. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/setup.py +1 -1
  19. pyobjc_framework_metalkit-12.2.2/Lib/pyobjc_framework_MetalKit.egg-info/pyobjc-build-info.txt +0 -3
  20. pyobjc_framework_metalkit-12.2.2/Lib/pyobjc_framework_MetalKit.egg-info/requires.txt +0 -3
  21. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/Lib/MetalKit/__init__.py +0 -0
  22. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/Lib/pyobjc_framework_MetalKit.egg-info/dependency_links.txt +0 -0
  23. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/Lib/pyobjc_framework_MetalKit.egg-info/not-zip-safe +0 -0
  24. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/Lib/pyobjc_framework_MetalKit.egg-info/top_level.txt +0 -0
  25. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/License.txt +0 -0
  26. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/MANIFEST.in +0 -0
  27. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/PyObjCTest/__init__.py +0 -0
  28. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/PyObjCTest/test_metalkit.py +0 -0
  29. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/metadata/metadata.ini +0 -0
  30. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/pyproject.toml +0 -0
  31. {pyobjc_framework_metalkit-12.2.2 → pyobjc_framework_metalkit-13.0}/setup.cfg +0 -0
@@ -1,7 +1,5 @@
1
1
  # This file is generated by objective.metadata
2
2
  #
3
- # Last update: Sun May 24 11:53:04 2026
4
- #
5
3
  # flake8: noqa
6
4
 
7
5
  import objc, sys
@@ -70,7 +68,10 @@ try:
70
68
  r(
71
69
  b"MTKMesh",
72
70
  b"newMeshesFromAsset:device:sourceMeshes:error:",
73
- {"arguments": {5: {"type_modifier": b"o"}}},
71
+ {
72
+ "retval": {"already_retained": True},
73
+ "arguments": {5: {"type_modifier": b"o"}},
74
+ },
74
75
  )
75
76
  r(
76
77
  b"MTKTextureLoader",
@@ -93,7 +94,10 @@ try:
93
94
  r(
94
95
  b"MTKTextureLoader",
95
96
  b"newTextureWithCGImage:options:error:",
96
- {"arguments": {4: {"type_modifier": b"o"}}},
97
+ {
98
+ "retval": {"already_retained": True},
99
+ "arguments": {4: {"type_modifier": b"o"}},
100
+ },
97
101
  )
98
102
  r(
99
103
  b"MTKTextureLoader",
@@ -116,7 +120,10 @@ try:
116
120
  r(
117
121
  b"MTKTextureLoader",
118
122
  b"newTextureWithContentsOfURL:options:error:",
119
- {"arguments": {4: {"type_modifier": b"o"}}},
123
+ {
124
+ "retval": {"already_retained": True},
125
+ "arguments": {4: {"type_modifier": b"o"}},
126
+ },
120
127
  )
121
128
  r(
122
129
  b"MTKTextureLoader",
@@ -139,7 +146,10 @@ try:
139
146
  r(
140
147
  b"MTKTextureLoader",
141
148
  b"newTextureWithData:options:error:",
142
- {"arguments": {4: {"type_modifier": b"o"}}},
149
+ {
150
+ "retval": {"already_retained": True},
151
+ "arguments": {4: {"type_modifier": b"o"}},
152
+ },
143
153
  )
144
154
  r(
145
155
  b"MTKTextureLoader",
@@ -162,7 +172,10 @@ try:
162
172
  r(
163
173
  b"MTKTextureLoader",
164
174
  b"newTextureWithMDLTexture:options:error:",
165
- {"arguments": {4: {"type_modifier": b"o"}}},
175
+ {
176
+ "retval": {"already_retained": True},
177
+ "arguments": {4: {"type_modifier": b"o"}},
178
+ },
166
179
  )
167
180
  r(
168
181
  b"MTKTextureLoader",
@@ -185,7 +198,10 @@ try:
185
198
  r(
186
199
  b"MTKTextureLoader",
187
200
  b"newTextureWithName:scaleFactor:bundle:options:error:",
188
- {"arguments": {6: {"type_modifier": b"o"}}},
201
+ {
202
+ "retval": {"already_retained": True},
203
+ "arguments": {6: {"type_modifier": b"o"}},
204
+ },
189
205
  )
190
206
  r(
191
207
  b"MTKTextureLoader",
@@ -208,7 +224,10 @@ try:
208
224
  r(
209
225
  b"MTKTextureLoader",
210
226
  b"newTextureWithName:scaleFactor:displayGamut:bundle:options:error:",
211
- {"arguments": {7: {"type_modifier": b"o"}}},
227
+ {
228
+ "retval": {"already_retained": True},
229
+ "arguments": {7: {"type_modifier": b"o"}},
230
+ },
212
231
  )
213
232
  r(
214
233
  b"MTKTextureLoader",
@@ -231,7 +250,10 @@ try:
231
250
  r(
232
251
  b"MTKTextureLoader",
233
252
  b"newTexturesWithContentsOfURLs:options:error:",
234
- {"arguments": {4: {"type_modifier": b"o"}}},
253
+ {
254
+ "retval": {"already_retained": True},
255
+ "arguments": {4: {"type_modifier": b"o"}},
256
+ },
235
257
  )
236
258
  r(
237
259
  b"MTKTextureLoader",
@@ -313,5 +335,8 @@ objc.registerNewKeywordsFromSelector("MTKTextureLoader", b"initWithDevice:")
313
335
  objc.registerNewKeywordsFromSelector("MTKView", b"initWithCoder:")
314
336
  objc.registerNewKeywordsFromSelector("MTKView", b"initWithFrame:device:")
315
337
  expressions = {}
338
+ formal_protocols = {
339
+ "MTKViewDelegate": "MTKViewDelegate",
340
+ }
316
341
 
317
342
  # END OF FILE
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pyobjc-framework-MetalKit
3
- Version: 12.2.2
3
+ Version: 13.0
4
4
  Summary: Wrappers for the framework MetalKit on macOS
5
5
  Home-page: https://github.com/ronaldoussoren/pyobjc
6
6
  Author: Ronald Oussoren
@@ -17,22 +17,22 @@ Classifier: Operating System :: MacOS :: MacOS X
17
17
  Classifier: Programming Language :: Python
18
18
  Classifier: Programming Language :: Python :: 3
19
19
  Classifier: Programming Language :: Python :: 3 :: Only
20
- Classifier: Programming Language :: Python :: 3.10
21
20
  Classifier: Programming Language :: Python :: 3.11
22
21
  Classifier: Programming Language :: Python :: 3.12
23
22
  Classifier: Programming Language :: Python :: 3.13
24
23
  Classifier: Programming Language :: Python :: 3.14
25
24
  Classifier: Programming Language :: Python :: 3.15
25
+ Classifier: Programming Language :: Python :: 3.16
26
26
  Classifier: Programming Language :: Python :: Implementation :: CPython
27
27
  Classifier: Programming Language :: Python :: Free Threading :: 3 - Stable
28
28
  Classifier: Programming Language :: Objective C
29
29
  Classifier: Topic :: Software Development :: Libraries :: Python Modules
30
30
  Classifier: Topic :: Software Development :: User Interfaces
31
- Requires-Python: >=3.10
31
+ Requires-Python: >=3.11
32
32
  Description-Content-Type: text/x-rst; charset=UTF-8
33
- Requires-Dist: pyobjc-core>=12.2.2
34
- Requires-Dist: pyobjc-framework-Cocoa>=12.2.2
35
- Requires-Dist: pyobjc-framework-Metal>=12.2.2
33
+ Requires-Dist: pyobjc-core>=13.0
34
+ Requires-Dist: pyobjc-framework-Cocoa>=13.0
35
+ Requires-Dist: pyobjc-framework-Metal>=13.0
36
36
  Dynamic: author
37
37
  Dynamic: author-email
38
38
  Dynamic: classifier
@@ -23,5 +23,5 @@ PyObjCTest/test_mtktextureloader.py
23
23
  PyObjCTest/test_mtkview.py
24
24
  metadata/MetalKit.fwinfo
25
25
  metadata/metadata.ini
26
- metadata/raw/arm64-26.5.fwinfo
27
- metadata/raw/x86_64-26.5.fwinfo
26
+ metadata/raw/arm64-27.fwinfo
27
+ metadata/raw/x86_64-27.fwinfo
@@ -0,0 +1,3 @@
1
+ macOS 27.2 (26B123)
2
+ Apple clang version 21.0.0 (clang-2100.4.1.1)
3
+ SDK: macOS 27.2
@@ -0,0 +1,3 @@
1
+ pyobjc-core>=13.0
2
+ pyobjc-framework-Cocoa>=13.0
3
+ pyobjc-framework-Metal>=13.0
@@ -2,6 +2,10 @@
2
2
  #include "Python.h"
3
3
  #include "pyobjc-api.h"
4
4
 
5
+ #ifdef USE_STATIC_ANALYZER
6
+ #include "../../pyobjc-core/Modules/objc/python-api-used.h"
7
+ #endif
8
+
5
9
  #import <Foundation/Foundation.h>
6
10
  #import <MetalKit/MetalKit.h>
7
11
 
@@ -10,6 +14,8 @@
10
14
  */
11
15
  #include "_MetalKit_protocols.m"
12
16
 
17
+ NS_ASSUME_NONNULL_BEGIN
18
+
13
19
  static PyMethodDef mod_methods[] = {
14
20
  {0, 0, 0, 0} /* sentinel */
15
21
  };
@@ -55,10 +61,11 @@ static struct PyModuleDef mod_module = {
55
61
  .m_free = NULL,
56
62
  };
57
63
 
58
- PyObject* PyInit__MetalKit(void);
64
+ PyObject* _Nullable PyInit__MetalKit(void);
59
65
 
60
- PyObject* __attribute__((__visibility__("default")))
66
+ PyObject* _Nullable __attribute__((__visibility__("default")))
61
67
  PyInit__MetalKit(void)
62
68
  {
63
69
  return PyModuleDef_Init(&mod_module);
64
70
  }
71
+ NS_ASSUME_NONNULL_END
@@ -1,8 +1,7 @@
1
- /*
2
- * This file is generated by objective.metadata
3
- *
4
- * Last update: Wed Jan 16 13:10:52 2013
5
- */
1
+ // LCOV_EXCL_START
2
+ // This function is only present to ensure protocols are
3
+ // available at runtime.
4
+ NS_ASSUME_NONNULL_BEGIN
6
5
 
7
6
  static void __attribute__((__used__))
8
7
  use_protocols(void)
@@ -11,3 +10,6 @@ use_protocols(void)
11
10
  p = PyObjC_IdToPython(@protocol(MTKViewDelegate));
12
11
  Py_XDECREF(p);
13
12
  }
13
+
14
+ NS_ASSUME_NONNULL_END
15
+ // LCOV_EXCL_STOP
@@ -60,6 +60,11 @@ typedef int(RegisterMethodMappingFunctionType)(
60
60
  PyObject* _Nonnull const* _Nonnull, size_t),
61
61
  IMP _Nullable (*_Nonnull)(PyObject* _Nonnull, PyObject* _Nonnull));
62
62
 
63
+ #ifndef PyObjC_FUNCTION_CALL_H
64
+ typedef PyObject* _Nullable (*PyObjC_FunctionCallFunc)(
65
+ PyObject* meth, PyObject* _Nonnull const* _Nonnull args, size_t nargs);
66
+ #endif
67
+
63
68
  struct pyobjc_api {
64
69
  int api_version; /* API version */
65
70
  size_t struct_len; /* Length of this struct */
@@ -117,6 +122,9 @@ struct pyobjc_api {
117
122
 
118
123
  PyObject* _Nullable (*_Nonnull createopaquepointertype)(const char*, const char*,
119
124
  const char*);
125
+ int (*_Nonnull register_functioncaller)(void*, PyObjC_FunctionCallFunc);
126
+ PyObject* _Nullable (*_Nonnull create_registered_struct)(
127
+ const char*, Py_ssize_t, const char* _Nonnull* _Nullable, Py_ssize_t*);
120
128
  };
121
129
 
122
130
  #ifndef PYOBJC_BUILD
@@ -159,6 +167,8 @@ static struct pyobjc_api* PyObjC_API;
159
167
  #define PyObjC_CheckArgCount (PyObjC_API->checkargcount)
160
168
  #define PyObjC_CheckNoKwnames (PyObjC_API->checknokwnames)
161
169
  #define PyObjCCreateOpaquePointerType (PyObjC_API->createopaquepointertype)
170
+ #define PyObjCRegister_FunctionCaller (PyObjC_API->register_functioncaller)
171
+ #define PyObjC_CreateRegisteredStruct (PyObjC_API->create_registered_struct)
162
172
 
163
173
  typedef void (*PyObjC_Function_Pointer)(void);
164
174
  typedef struct PyObjC_function_map {
@@ -178,21 +188,25 @@ static inline int
178
188
  PyObjC_ImportAPI(PyObject* calling_module)
179
189
  {
180
190
  PyObjC_API = (struct pyobjc_api*)PyCapsule_Import("objc." PYOBJC_API_NAME, 0);
181
- if (PyObjC_API == NULL) {
182
- return -1;
191
+ if (PyObjC_API == NULL) { // LCOV_BR_EXCL_LINE
192
+ return -1; // LCOV_EXCL_LINE
183
193
  }
184
- if (PyObjC_API->api_version != PYOBJC_API_VERSION) {
194
+ if (PyObjC_API->api_version != PYOBJC_API_VERSION) { // LCOV_BR_EXCL_LINE
195
+ // LCOV_EXCL_START
185
196
  PyErr_Format(PyExc_RuntimeError,
186
197
  "Wrong version of PyObjC C API (got %d, expected %d)",
187
198
  (int)PyObjC_API->api_version, (int)PYOBJC_API_VERSION);
188
199
  return -1;
200
+ // LCOV_EXCL_STOP
189
201
  }
190
202
 
191
- if (PyObjC_API->struct_len < PyObjC_EXPECTED_STRUCT_SIZE) {
203
+ if (PyObjC_API->struct_len < PyObjC_EXPECTED_STRUCT_SIZE) { // LCOV_EXCL_LINE
204
+ // LCOV_EXCL_START
192
205
  PyErr_Format(PyExc_RuntimeError,
193
206
  "Wrong struct-size of PyObjC C API (got %d, expected %d)",
194
207
  (int)PyObjC_API->struct_len, (int)sizeof(struct pyobjc_api));
195
208
  return -1;
209
+ // LCOV_EXCL_STOP
196
210
  }
197
211
 
198
212
  /* Current pyobjc implementation doesn't allow deregistering
@@ -167,24 +167,6 @@ _PyObjCTuple_GetItem(PyObject* tuple, Py_ssize_t idx)
167
167
  PyGILState_Release(_GILState); \
168
168
  } while (0)
169
169
 
170
- #if PY_VERSION_HEX < 0x030a0000
171
-
172
- static inline PyObject*
173
- Py_NewRef(PyObject* o)
174
- {
175
- Py_INCREF(o);
176
- return o;
177
- }
178
-
179
- static inline PyObject*
180
- Py_XNewRef(PyObject* o)
181
- {
182
- Py_XINCREF(o);
183
- return o;
184
- }
185
-
186
- #endif /* PY_VERSION_HEX < 0x030a0000 */
187
-
188
170
  #if PY_VERSION_HEX < 0x030d0000
189
171
  #define Py_BEGIN_CRITICAL_SECTION(value) \
190
172
  { \
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pyobjc-framework-MetalKit
3
- Version: 12.2.2
3
+ Version: 13.0
4
4
  Summary: Wrappers for the framework MetalKit on macOS
5
5
  Home-page: https://github.com/ronaldoussoren/pyobjc
6
6
  Author: Ronald Oussoren
@@ -17,22 +17,22 @@ Classifier: Operating System :: MacOS :: MacOS X
17
17
  Classifier: Programming Language :: Python
18
18
  Classifier: Programming Language :: Python :: 3
19
19
  Classifier: Programming Language :: Python :: 3 :: Only
20
- Classifier: Programming Language :: Python :: 3.10
21
20
  Classifier: Programming Language :: Python :: 3.11
22
21
  Classifier: Programming Language :: Python :: 3.12
23
22
  Classifier: Programming Language :: Python :: 3.13
24
23
  Classifier: Programming Language :: Python :: 3.14
25
24
  Classifier: Programming Language :: Python :: 3.15
25
+ Classifier: Programming Language :: Python :: 3.16
26
26
  Classifier: Programming Language :: Python :: Implementation :: CPython
27
27
  Classifier: Programming Language :: Python :: Free Threading :: 3 - Stable
28
28
  Classifier: Programming Language :: Objective C
29
29
  Classifier: Topic :: Software Development :: Libraries :: Python Modules
30
30
  Classifier: Topic :: Software Development :: User Interfaces
31
- Requires-Python: >=3.10
31
+ Requires-Python: >=3.11
32
32
  Description-Content-Type: text/x-rst; charset=UTF-8
33
- Requires-Dist: pyobjc-core>=12.2.2
34
- Requires-Dist: pyobjc-framework-Cocoa>=12.2.2
35
- Requires-Dist: pyobjc-framework-Metal>=12.2.2
33
+ Requires-Dist: pyobjc-core>=13.0
34
+ Requires-Dist: pyobjc-framework-Cocoa>=13.0
35
+ Requires-Dist: pyobjc-framework-Metal>=13.0
36
36
  Dynamic: author
37
37
  Dynamic: author-email
38
38
  Dynamic: classifier
@@ -5,7 +5,7 @@ import MetalKit
5
5
 
6
6
 
7
7
  class TestMTKModel(TestCase):
8
- def test_typed_enum(self):
8
+ def test_typed_enums(self):
9
9
  self.assertIsTypedEnum(MetalKit.MTKModelError, str)
10
10
 
11
11
  @min_os_level("10.11")
@@ -16,6 +16,9 @@ class TestMTKModel(TestCase):
16
16
  @min_os_level("10.11")
17
17
  def test_methods10_11(self):
18
18
  self.assertArgIsOut(MetalKit.MTKMesh.initWithMesh_device_error_, 2)
19
+ self.assertResultIsRetained(
20
+ MetalKit.MTKMesh.newMeshesFromAsset_device_sourceMeshes_error_
21
+ )
19
22
  self.assertArgIsOut(
20
23
  MetalKit.MTKMesh.newMeshesFromAsset_device_sourceMeshes_error_, 3
21
24
  )
@@ -7,7 +7,7 @@ MTKTextureLoaderArrayCallback = b"v@@"
7
7
 
8
8
 
9
9
  class TestMTKTextureLoading(TestCase):
10
- def test_typed_enum(self):
10
+ def test_typed_enums(self):
11
11
  self.assertIsTypedEnum(MetalKit.MTKTextureLoaderCubeLayout, str)
12
12
  self.assertIsTypedEnum(MetalKit.MTKTextureLoaderError, str)
13
13
  self.assertIsTypedEnum(MetalKit.MTKTextureLoaderOption, str)
@@ -45,23 +45,36 @@ class TestMTKTextureLoading(TestCase):
45
45
  2,
46
46
  MTKTextureLoaderCallback,
47
47
  )
48
+
48
49
  self.assertArgIsBlock(
49
50
  MetalKit.MTKTextureLoader.newTextureWithData_options_completionHandler_,
50
51
  2,
51
52
  MTKTextureLoaderCallback,
52
53
  )
54
+
53
55
  self.assertArgIsBlock(
54
56
  MetalKit.MTKTextureLoader.newTextureWithCGImage_options_completionHandler_,
55
57
  2,
56
58
  MTKTextureLoaderCallback,
57
59
  )
58
60
 
61
+ self.assertResultIsRetained(
62
+ MetalKit.MTKTextureLoader.newTextureWithContentsOfURL_options_error_
63
+ )
59
64
  self.assertArgIsOut(
60
65
  MetalKit.MTKTextureLoader.newTextureWithContentsOfURL_options_error_, 2
61
66
  )
67
+
68
+ self.assertResultIsRetained(
69
+ MetalKit.MTKTextureLoader.newTextureWithData_options_error_
70
+ )
62
71
  self.assertArgIsOut(
63
72
  MetalKit.MTKTextureLoader.newTextureWithData_options_error_, 2
64
73
  )
74
+
75
+ self.assertResultIsRetained(
76
+ MetalKit.MTKTextureLoader.newTextureWithCGImage_options_error_
77
+ )
65
78
  self.assertArgIsOut(
66
79
  MetalKit.MTKTextureLoader.newTextureWithCGImage_options_error_, 2
67
80
  )
@@ -73,16 +86,19 @@ class TestMTKTextureLoading(TestCase):
73
86
  4,
74
87
  MTKTextureLoaderCallback,
75
88
  )
89
+
76
90
  self.assertArgIsBlock(
77
91
  MetalKit.MTKTextureLoader.newTextureWithName_scaleFactor_displayGamut_bundle_options_completionHandler_, # noqa: B950
78
92
  5,
79
93
  MTKTextureLoaderCallback,
80
94
  )
95
+
81
96
  self.assertArgIsBlock(
82
97
  MetalKit.MTKTextureLoader.newTexturesWithContentsOfURLs_options_completionHandler_, # noqa: B950
83
98
  2,
84
99
  MTKTextureLoaderArrayCallback,
85
100
  )
101
+
86
102
  self.assertArgIsBlock(
87
103
  MetalKit.MTKTextureLoader.newTexturesWithNames_scaleFactor_bundle_options_completionHandler_, # noqa: B950
88
104
  4,
@@ -99,16 +115,31 @@ class TestMTKTextureLoading(TestCase):
99
115
  MTKTextureLoaderCallback,
100
116
  )
101
117
 
118
+ self.assertResultIsRetained(
119
+ MetalKit.MTKTextureLoader.newTexturesWithContentsOfURLs_options_error_
120
+ )
102
121
  self.assertArgIsOut(
103
122
  MetalKit.MTKTextureLoader.newTexturesWithContentsOfURLs_options_error_, 2
104
123
  )
124
+
125
+ self.assertResultIsRetained(
126
+ MetalKit.MTKTextureLoader.newTextureWithMDLTexture_options_error_
127
+ )
105
128
  self.assertArgIsOut(
106
129
  MetalKit.MTKTextureLoader.newTextureWithMDLTexture_options_error_, 2
107
130
  )
131
+
132
+ self.assertResultIsRetained(
133
+ MetalKit.MTKTextureLoader.newTextureWithName_scaleFactor_bundle_options_error_
134
+ )
108
135
  self.assertArgIsOut(
109
136
  MetalKit.MTKTextureLoader.newTextureWithName_scaleFactor_bundle_options_error_,
110
137
  4,
111
138
  )
139
+
140
+ self.assertResultIsRetained(
141
+ MetalKit.MTKTextureLoader.newTextureWithName_scaleFactor_displayGamut_bundle_options_error_
142
+ ) # noqa: B950
112
143
  self.assertArgIsOut(
113
144
  MetalKit.MTKTextureLoader.newTextureWithName_scaleFactor_displayGamut_bundle_options_error_, # noqa: B950
114
145
  5,
@@ -37,9 +37,9 @@ class TestMTKView(TestCase):
37
37
 
38
38
  @min_sdk_level("10.15")
39
39
  def test_protocols(self):
40
- self.assertProtocolExists("MTKViewDelegate")
40
+ self.assertProtocolExists("MTKViewDelegate", MetalKit)
41
41
 
42
- def test_methods(self):
42
+ def test_protocol_methods(self):
43
43
  self.assertArgHasType(
44
44
  TestMTKViewHelper.mtkView_drawableSizeWillChange_,
45
45
  1,
@@ -10,25 +10,6 @@
10
10
  "MTKTextureLoaderOrigin": { "type": "@", "type_name": "NSString" }
11
11
  },
12
12
  "classes": {
13
- "MTKMesh": {
14
- "methods": [
15
- {
16
- "args": {
17
- "2": { "type_modifier": "o" }
18
- },
19
- "class_method": false,
20
- "selector": "initWithMesh:device:error:"
21
- },
22
- {
23
- "args": {
24
- "2": {},
25
- "3": { "type_modifier": "o" }
26
- },
27
- "class_method": true,
28
- "selector": "newMeshesFromAsset:device:sourceMeshes:error:"
29
- }
30
- ]
31
- },
32
13
  "MTKTextureLoader": {
33
14
  "methods": [
34
15
  {
@@ -174,56 +155,6 @@
174
155
  },
175
156
  "class_method": false,
176
157
  "selector": "newTextureWithName:scaleFactor:displayGamut:bundle:options:completionHandler:"
177
- },
178
- {
179
- "args": {
180
- "2": { "type_modifier": "o" }
181
- },
182
- "class_method": false,
183
- "selector": "newTextureWithContentsOfURL:options:error:"
184
- },
185
- {
186
- "args": {
187
- "2": { "type_modifier": "o" }
188
- },
189
- "class_method": false,
190
- "selector": "newTexturesWithContentsOfURLs:options:error:"
191
- },
192
- {
193
- "args": {
194
- "2": { "type_modifier": "o" }
195
- },
196
- "class_method": false,
197
- "selector": "newTextureWithData:options:error:"
198
- },
199
- {
200
- "args": {
201
- "0": {},
202
- "2": { "type_modifier": "o" }
203
- },
204
- "class_method": false,
205
- "selector": "newTextureWithCGImage:options:error:"
206
- },
207
- {
208
- "args": {
209
- "2": { "type_modifier": "o" }
210
- },
211
- "class_method": false,
212
- "selector": "newTextureWithMDLTexture:options:error:"
213
- },
214
- {
215
- "args": {
216
- "4": { "type_modifier": "o" }
217
- },
218
- "class_method": false,
219
- "selector": "newTextureWithName:scaleFactor:bundle:options:error:"
220
- },
221
- {
222
- "args": {
223
- "5": { "type_modifier": "o" }
224
- },
225
- "class_method": false,
226
- "selector": "newTextureWithName:scaleFactor:displayGamut:bundle:options:error:"
227
158
  }
228
159
  ]
229
160
  },
@@ -244,7 +175,6 @@
244
175
  ]
245
176
  }
246
177
  },
247
- "formal_protocols": {},
248
178
  "functions": {
249
179
  "MTKMetalVertexDescriptorFromModelIOWithError": {
250
180
  "args": {
@@ -256,7 +186,6 @@
256
186
  "1": { "type_modifier": "o" }
257
187
  }
258
188
  }
259
- },
260
- "informal_protocols": {}
189
+ }
261
190
  }
262
191
  }
@@ -1,7 +1,6 @@
1
1
  // GENERATED FILE DO NOT EDIT
2
2
  //
3
3
  // This file was generated by objective.metadata
4
- // Last update: Sun May 24 11:53:04 2026
5
4
  {
6
5
  "arch": "arm64",
7
6
  "definitions": {
@@ -96,6 +95,7 @@
96
95
  "class_method": true,
97
96
  "introduced": "10.11",
98
97
  "retval": {
98
+ "already_retained": true,
99
99
  "type_name": "NSArray<MTKMesh *> *",
100
100
  "typestr": "@",
101
101
  "typestr_special": false
@@ -1248,6 +1248,7 @@
1248
1248
  "class_method": false,
1249
1249
  "introduced": "10.11",
1250
1250
  "retval": {
1251
+ "already_retained": true,
1251
1252
  "type_name": "id<MTLTexture>",
1252
1253
  "typestr": "@",
1253
1254
  "typestr_special": false
@@ -1283,6 +1284,7 @@
1283
1284
  "class_method": false,
1284
1285
  "introduced": "10.12",
1285
1286
  "retval": {
1287
+ "already_retained": true,
1286
1288
  "type_name": "NSArray<id<MTLTexture>> *",
1287
1289
  "typestr": "@",
1288
1290
  "typestr_special": false
@@ -1318,6 +1320,7 @@
1318
1320
  "class_method": false,
1319
1321
  "introduced": "10.11",
1320
1322
  "retval": {
1323
+ "already_retained": true,
1321
1324
  "type_name": "id<MTLTexture>",
1322
1325
  "typestr": "@",
1323
1326
  "typestr_special": false
@@ -1353,6 +1356,7 @@
1353
1356
  "class_method": false,
1354
1357
  "introduced": "10.11",
1355
1358
  "retval": {
1359
+ "already_retained": true,
1356
1360
  "type_name": "id<MTLTexture>",
1357
1361
  "typestr": "@",
1358
1362
  "typestr_special": false
@@ -1388,6 +1392,7 @@
1388
1392
  "class_method": false,
1389
1393
  "introduced": "10.12",
1390
1394
  "retval": {
1395
+ "already_retained": true,
1391
1396
  "type_name": "id<MTLTexture>",
1392
1397
  "typestr": "@",
1393
1398
  "typestr_special": false
@@ -1436,6 +1441,7 @@
1436
1441
  "class_method": false,
1437
1442
  "introduced": "10.12",
1438
1443
  "retval": {
1444
+ "already_retained": true,
1439
1445
  "type_name": "id<MTLTexture>",
1440
1446
  "typestr": "@",
1441
1447
  "typestr_special": false
@@ -1490,6 +1496,7 @@
1490
1496
  "class_method": false,
1491
1497
  "introduced": "10.12",
1492
1498
  "retval": {
1499
+ "already_retained": true,
1493
1500
  "type_name": "id<MTLTexture>",
1494
1501
  "typestr": "@",
1495
1502
  "typestr_special": false
@@ -2815,6 +2822,6 @@
2815
2822
  "MTKTextureLoader.h",
2816
2823
  "MTKView.h"
2817
2824
  ],
2818
- "release": "26.5",
2819
- "sdk": "/Users/ronald/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX26.5.sdk"
2825
+ "release": "macOS 27.2",
2826
+ "sdk": "Xcode 27.2 (27B5038i)/MacOSX27.sdk"
2820
2827
  }
@@ -1,7 +1,6 @@
1
1
  // GENERATED FILE DO NOT EDIT
2
2
  //
3
3
  // This file was generated by objective.metadata
4
- // Last update: Sun May 24 11:53:00 2026
5
4
  {
6
5
  "arch": "x86_64",
7
6
  "definitions": {
@@ -96,6 +95,7 @@
96
95
  "class_method": true,
97
96
  "introduced": "10.11",
98
97
  "retval": {
98
+ "already_retained": true,
99
99
  "type_name": "NSArray<MTKMesh *> *",
100
100
  "typestr": "@",
101
101
  "typestr_special": false
@@ -1248,6 +1248,7 @@
1248
1248
  "class_method": false,
1249
1249
  "introduced": "10.11",
1250
1250
  "retval": {
1251
+ "already_retained": true,
1251
1252
  "type_name": "id<MTLTexture>",
1252
1253
  "typestr": "@",
1253
1254
  "typestr_special": false
@@ -1283,6 +1284,7 @@
1283
1284
  "class_method": false,
1284
1285
  "introduced": "10.12",
1285
1286
  "retval": {
1287
+ "already_retained": true,
1286
1288
  "type_name": "NSArray<id<MTLTexture>> *",
1287
1289
  "typestr": "@",
1288
1290
  "typestr_special": false
@@ -1318,6 +1320,7 @@
1318
1320
  "class_method": false,
1319
1321
  "introduced": "10.11",
1320
1322
  "retval": {
1323
+ "already_retained": true,
1321
1324
  "type_name": "id<MTLTexture>",
1322
1325
  "typestr": "@",
1323
1326
  "typestr_special": false
@@ -1353,6 +1356,7 @@
1353
1356
  "class_method": false,
1354
1357
  "introduced": "10.11",
1355
1358
  "retval": {
1359
+ "already_retained": true,
1356
1360
  "type_name": "id<MTLTexture>",
1357
1361
  "typestr": "@",
1358
1362
  "typestr_special": false
@@ -1388,6 +1392,7 @@
1388
1392
  "class_method": false,
1389
1393
  "introduced": "10.12",
1390
1394
  "retval": {
1395
+ "already_retained": true,
1391
1396
  "type_name": "id<MTLTexture>",
1392
1397
  "typestr": "@",
1393
1398
  "typestr_special": false
@@ -1436,6 +1441,7 @@
1436
1441
  "class_method": false,
1437
1442
  "introduced": "10.12",
1438
1443
  "retval": {
1444
+ "already_retained": true,
1439
1445
  "type_name": "id<MTLTexture>",
1440
1446
  "typestr": "@",
1441
1447
  "typestr_special": false
@@ -1490,6 +1496,7 @@
1490
1496
  "class_method": false,
1491
1497
  "introduced": "10.12",
1492
1498
  "retval": {
1499
+ "already_retained": true,
1493
1500
  "type_name": "id<MTLTexture>",
1494
1501
  "typestr": "@",
1495
1502
  "typestr_special": false
@@ -2815,6 +2822,6 @@
2815
2822
  "MTKTextureLoader.h",
2816
2823
  "MTKView.h"
2817
2824
  ],
2818
- "release": "26.5",
2819
- "sdk": "/Users/ronald/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX26.5.sdk"
2825
+ "release": "macOS 27.2",
2826
+ "sdk": "Xcode 27.2 (27B5038i)/MacOSX27.sdk"
2820
2827
  }
@@ -110,13 +110,11 @@ class oc_egg_info(egg_info.egg_info):
110
110
  else:
111
111
  sdk_version = os.path.basename(sdk_root)
112
112
 
113
- build_info = textwrap.dedent(
114
- f"""\
113
+ build_info = textwrap.dedent(f"""\
115
114
  macOS {macos_version} ({macos_build})
116
115
  {clang_version}
117
116
  SDK: {sdk_version}
118
- """
119
- )
117
+ """)
120
118
 
121
119
  self.write_file(
122
120
  "pyobjc-build-info.txt",
@@ -204,7 +202,7 @@ class oc_test(Command):
204
202
  "errors": len(result.errors),
205
203
  "xfails": len(getattr(result, "expectedFailures", [])),
206
204
  "xpass": len(getattr(result, "unexpectedSuccesses", [])),
207
- "skip=": len(getattr(result, "skipped", [])),
205
+ "skip": len(getattr(result, "skipped", [])),
208
206
  "testSeconds": (time_after - time_before),
209
207
  }
210
208
  print(f"SUMMARY: {summary}")
@@ -228,12 +226,12 @@ Operating System :: MacOS :: MacOS X
228
226
  Programming Language :: Python
229
227
  Programming Language :: Python :: 3
230
228
  Programming Language :: Python :: 3 :: Only
231
- Programming Language :: Python :: 3.10
232
229
  Programming Language :: Python :: 3.11
233
230
  Programming Language :: Python :: 3.12
234
231
  Programming Language :: Python :: 3.13
235
232
  Programming Language :: Python :: 3.14
236
233
  Programming Language :: Python :: 3.15
234
+ Programming Language :: Python :: 3.16
237
235
  Programming Language :: Python :: Implementation :: CPython
238
236
  Programming Language :: Python :: Free Threading :: 3 - Stable
239
237
  Programming Language :: Objective C
@@ -499,6 +497,8 @@ def Extension(*args, **kwds):
499
497
  "-DPyObjC_BUILD_RELEASE=%02d%02d"
500
498
  % (tuple(map(int, version.split(".")[:2])))
501
499
  )
500
+ ldflags.append("-isysroot")
501
+ ldflags.append(data)
502
502
  else:
503
503
  cflags.append(
504
504
  "-DPyObjC_BUILD_RELEASE=%02d%02d"
@@ -677,7 +677,7 @@ def setup(
677
677
  zip_safe=False,
678
678
  license="MIT",
679
679
  classifiers=CLASSIFIERS,
680
- python_requires=">=3.10",
680
+ python_requires=">=3.11",
681
681
  keywords=["PyObjC"] + [p for p in k["packages"] if p not in ("PyObjCTools",)],
682
682
  options=options,
683
683
  **k,
@@ -15,7 +15,7 @@ sys.path.insert(0, os.path.dirname(__file__))
15
15
 
16
16
  from pyobjc_setup import Extension, setup # noqa: E402
17
17
 
18
- VERSION = "12.2.2"
18
+ VERSION = "13.0"
19
19
 
20
20
  setup(
21
21
  name="pyobjc-framework-MetalKit",
@@ -1,3 +0,0 @@
1
- macOS 26.6 (25G70)
2
- Apple clang version 21.0.0 (clang-2100.1.1.101)
3
- SDK: macOS 26.5
@@ -1,3 +0,0 @@
1
- pyobjc-core>=12.2.2
2
- pyobjc-framework-Cocoa>=12.2.2
3
- pyobjc-framework-Metal>=12.2.2