pyobjc-framework-PushKit 10.3.2__tar.gz → 12.2.2__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 (40) hide show
  1. {pyobjc_framework_pushkit-10.3.2 → pyobjc_framework_pushkit-12.2.2}/Lib/PushKit/_metadata.py +23 -1
  2. {pyobjc_framework_pushkit-10.3.2 → pyobjc_framework_pushkit-12.2.2}/Lib/pyobjc_framework_PushKit.egg-info/PKG-INFO +21 -9
  3. {pyobjc_framework_pushkit-10.3.2 → pyobjc_framework_pushkit-12.2.2}/Lib/pyobjc_framework_PushKit.egg-info/SOURCES.txt +4 -8
  4. pyobjc_framework_pushkit-12.2.2/Lib/pyobjc_framework_PushKit.egg-info/pyobjc-build-info.txt +3 -0
  5. pyobjc_framework_pushkit-12.2.2/Lib/pyobjc_framework_PushKit.egg-info/requires.txt +2 -0
  6. {pyobjc_framework_pushkit-10.3.2 → pyobjc_framework_pushkit-12.2.2}/License.txt +1 -1
  7. pyobjc_framework_pushkit-12.2.2/Modules/_PushKit.m +64 -0
  8. {pyobjc_framework_pushkit-10.3.2 → pyobjc_framework_pushkit-12.2.2}/Modules/_PushKit_protocols.m +2 -1
  9. {pyobjc_framework_pushkit-10.3.2 → pyobjc_framework_pushkit-12.2.2}/Modules/pyobjc-api.h +6 -3
  10. pyobjc_framework_pushkit-12.2.2/Modules/pyobjc-compat.h +371 -0
  11. {pyobjc_framework_pushkit-10.3.2 → pyobjc_framework_pushkit-12.2.2}/PKG-INFO +21 -9
  12. pyobjc_framework_pushkit-12.2.2/PyObjCTest/__init__.py +1 -0
  13. {pyobjc_framework_pushkit-10.3.2 → pyobjc_framework_pushkit-12.2.2}/PyObjCTest/test_pkpushregistry.py +12 -1
  14. pyobjc_framework_pushkit-12.2.2/PyObjCTest/test_pkvoippushmetadata.py +9 -0
  15. pyobjc_framework_pushkit-10.3.2/metadata/raw/arm64-14.5.fwinfo → pyobjc_framework_pushkit-12.2.2/metadata/raw/arm64-26.5.fwinfo +178 -5
  16. pyobjc_framework_pushkit-10.3.2/metadata/raw/x86_64-14.5.fwinfo → pyobjc_framework_pushkit-12.2.2/metadata/raw/x86_64-26.5.fwinfo +178 -5
  17. {pyobjc_framework_pushkit-10.3.2 → pyobjc_framework_pushkit-12.2.2}/pyobjc_setup.py +75 -54
  18. {pyobjc_framework_pushkit-10.3.2 → pyobjc_framework_pushkit-12.2.2}/setup.py +1 -3
  19. pyobjc_framework_pushkit-10.3.2/Lib/pyobjc_framework_PushKit.egg-info/requires.txt +0 -2
  20. pyobjc_framework_pushkit-10.3.2/Modules/_PushKit.m +0 -38
  21. pyobjc_framework_pushkit-10.3.2/Modules/pyobjc-compat.h +0 -245
  22. pyobjc_framework_pushkit-10.3.2/PyObjCTest/__init__.py +0 -1
  23. pyobjc_framework_pushkit-10.3.2/metadata/raw/arm64-12.3.fwinfo +0 -372
  24. pyobjc_framework_pushkit-10.3.2/metadata/raw/arm64-13.3.fwinfo +0 -375
  25. pyobjc_framework_pushkit-10.3.2/metadata/raw/x86_64-10.15.fwinfo +0 -361
  26. pyobjc_framework_pushkit-10.3.2/metadata/raw/x86_64-10.16.fwinfo +0 -371
  27. pyobjc_framework_pushkit-10.3.2/metadata/raw/x86_64-12.3.fwinfo +0 -372
  28. pyobjc_framework_pushkit-10.3.2/metadata/raw/x86_64-13.3.fwinfo +0 -375
  29. {pyobjc_framework_pushkit-10.3.2 → pyobjc_framework_pushkit-12.2.2}/Lib/PushKit/__init__.py +0 -0
  30. {pyobjc_framework_pushkit-10.3.2 → pyobjc_framework_pushkit-12.2.2}/Lib/pyobjc_framework_PushKit.egg-info/dependency_links.txt +0 -0
  31. {pyobjc_framework_pushkit-10.3.2 → pyobjc_framework_pushkit-12.2.2}/Lib/pyobjc_framework_PushKit.egg-info/not-zip-safe +0 -0
  32. {pyobjc_framework_pushkit-10.3.2 → pyobjc_framework_pushkit-12.2.2}/Lib/pyobjc_framework_PushKit.egg-info/top_level.txt +0 -0
  33. {pyobjc_framework_pushkit-10.3.2 → pyobjc_framework_pushkit-12.2.2}/MANIFEST.in +0 -0
  34. {pyobjc_framework_pushkit-10.3.2 → pyobjc_framework_pushkit-12.2.2}/PyObjCTest/test_pkdefines.py +0 -0
  35. {pyobjc_framework_pushkit-10.3.2 → pyobjc_framework_pushkit-12.2.2}/PyObjCTest/test_pkpushcredentials.py +0 -0
  36. {pyobjc_framework_pushkit-10.3.2 → pyobjc_framework_pushkit-12.2.2}/PyObjCTest/test_pushkit.py +0 -0
  37. {pyobjc_framework_pushkit-10.3.2 → pyobjc_framework_pushkit-12.2.2}/metadata/PushKit.fwinfo +0 -0
  38. {pyobjc_framework_pushkit-10.3.2 → pyobjc_framework_pushkit-12.2.2}/metadata/metadata.ini +0 -0
  39. {pyobjc_framework_pushkit-10.3.2 → pyobjc_framework_pushkit-12.2.2}/pyproject.toml +0 -0
  40. {pyobjc_framework_pushkit-10.3.2 → pyobjc_framework_pushkit-12.2.2}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  # This file is generated by objective.metadata
2
2
  #
3
- # Last update: Sat May 18 09:34:28 2024
3
+ # Last update: Sun May 24 11:55:38 2026
4
4
  #
5
5
  # flake8: noqa
6
6
 
@@ -76,6 +76,26 @@ try:
76
76
  },
77
77
  },
78
78
  )
79
+ r(
80
+ b"NSObject",
81
+ b"pushRegistry:didReceiveIncomingVoIPPushWithPayload:metadata:withCompletionHandler:",
82
+ {
83
+ "required": False,
84
+ "retval": {"type": b"v"},
85
+ "arguments": {
86
+ 2: {"type": b"@"},
87
+ 3: {"type": b"@"},
88
+ 4: {"type": b"@"},
89
+ 5: {
90
+ "callable": {
91
+ "retval": {"type": b"v"},
92
+ "arguments": {0: {"type": b"^v"}},
93
+ },
94
+ "type": b"@?",
95
+ },
96
+ },
97
+ },
98
+ )
79
99
  r(
80
100
  b"NSObject",
81
101
  b"pushRegistry:didUpdatePushCredentials:forType:",
@@ -85,9 +105,11 @@ try:
85
105
  "arguments": {2: {"type": b"@"}, 3: {"type": b"@"}, 4: {"type": b"@"}},
86
106
  },
87
107
  )
108
+ r(b"PKVoIPPushMetadata", b"mustReport", {"retval": {"type": b"Z"}})
88
109
  finally:
89
110
  objc._updatingMetadata(False)
90
111
 
112
+ objc.registerNewKeywordsFromSelector("PKPushRegistry", b"init")
91
113
  objc.registerNewKeywordsFromSelector("PKPushRegistry", b"initWithQueue:")
92
114
  expressions = {}
93
115
 
@@ -1,37 +1,49 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.4
2
2
  Name: pyobjc-framework-PushKit
3
- Version: 10.3.2
3
+ Version: 12.2.2
4
4
  Summary: Wrappers for the framework PushKit on macOS
5
5
  Home-page: https://github.com/ronaldoussoren/pyobjc
6
6
  Author: Ronald Oussoren
7
7
  Author-email: pyobjc-dev@lists.sourceforge.net
8
- License: MIT License
8
+ License: MIT
9
9
  Keywords: PyObjC,PushKit
10
10
  Platform: MacOS X (>=10.15)
11
11
  Classifier: Development Status :: 5 - Production/Stable
12
12
  Classifier: Environment :: Console
13
13
  Classifier: Environment :: MacOS X :: Cocoa
14
14
  Classifier: Intended Audience :: Developers
15
- Classifier: License :: OSI Approved :: MIT License
16
15
  Classifier: Natural Language :: English
17
16
  Classifier: Operating System :: MacOS :: MacOS X
18
17
  Classifier: Programming Language :: Python
19
18
  Classifier: Programming Language :: Python :: 3
20
19
  Classifier: Programming Language :: Python :: 3 :: Only
21
- Classifier: Programming Language :: Python :: 3.8
22
- Classifier: Programming Language :: Python :: 3.9
23
20
  Classifier: Programming Language :: Python :: 3.10
24
21
  Classifier: Programming Language :: Python :: 3.11
25
22
  Classifier: Programming Language :: Python :: 3.12
26
23
  Classifier: Programming Language :: Python :: 3.13
24
+ Classifier: Programming Language :: Python :: 3.14
25
+ Classifier: Programming Language :: Python :: 3.15
27
26
  Classifier: Programming Language :: Python :: Implementation :: CPython
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.8
31
+ Requires-Python: >=3.10
32
32
  Description-Content-Type: text/x-rst; charset=UTF-8
33
- Requires-Dist: pyobjc-core>=10.3.2
34
- Requires-Dist: pyobjc-framework-Cocoa>=10.3.2
33
+ Requires-Dist: pyobjc-core>=12.2.2
34
+ Requires-Dist: pyobjc-framework-Cocoa>=12.2.2
35
+ Dynamic: author
36
+ Dynamic: author-email
37
+ Dynamic: classifier
38
+ Dynamic: description
39
+ Dynamic: description-content-type
40
+ Dynamic: home-page
41
+ Dynamic: keywords
42
+ Dynamic: license
43
+ Dynamic: platform
44
+ Dynamic: requires-dist
45
+ Dynamic: requires-python
46
+ Dynamic: summary
35
47
  Project-URL: Documentation, https://pyobjc.readthedocs.io/en/latest/
36
48
  Project-URL: Issue tracker, https://github.com/ronaldoussoren/pyobjc/issues
37
49
  Project-URL: Repository, https://github.com/ronaldoussoren/pyobjc
@@ -9,6 +9,7 @@ Lib/pyobjc_framework_PushKit.egg-info/PKG-INFO
9
9
  Lib/pyobjc_framework_PushKit.egg-info/SOURCES.txt
10
10
  Lib/pyobjc_framework_PushKit.egg-info/dependency_links.txt
11
11
  Lib/pyobjc_framework_PushKit.egg-info/not-zip-safe
12
+ Lib/pyobjc_framework_PushKit.egg-info/pyobjc-build-info.txt
12
13
  Lib/pyobjc_framework_PushKit.egg-info/requires.txt
13
14
  Lib/pyobjc_framework_PushKit.egg-info/top_level.txt
14
15
  Modules/_PushKit.m
@@ -19,14 +20,9 @@ PyObjCTest/__init__.py
19
20
  PyObjCTest/test_pkdefines.py
20
21
  PyObjCTest/test_pkpushcredentials.py
21
22
  PyObjCTest/test_pkpushregistry.py
23
+ PyObjCTest/test_pkvoippushmetadata.py
22
24
  PyObjCTest/test_pushkit.py
23
25
  metadata/PushKit.fwinfo
24
26
  metadata/metadata.ini
25
- metadata/raw/arm64-12.3.fwinfo
26
- metadata/raw/arm64-13.3.fwinfo
27
- metadata/raw/arm64-14.5.fwinfo
28
- metadata/raw/x86_64-10.15.fwinfo
29
- metadata/raw/x86_64-10.16.fwinfo
30
- metadata/raw/x86_64-12.3.fwinfo
31
- metadata/raw/x86_64-13.3.fwinfo
32
- metadata/raw/x86_64-14.5.fwinfo
27
+ metadata/raw/arm64-26.5.fwinfo
28
+ metadata/raw/x86_64-26.5.fwinfo
@@ -0,0 +1,3 @@
1
+ macOS 26.6 (25G70)
2
+ Apple clang version 21.0.0 (clang-2100.1.1.101)
3
+ SDK: macOS 26.5
@@ -0,0 +1,2 @@
1
+ pyobjc-core>=12.2.2
2
+ pyobjc-framework-Cocoa>=12.2.2
@@ -1,7 +1,7 @@
1
1
  (This is the MIT license, note that libffi-src is a separate product with its own license)
2
2
 
3
3
  Copyright 2002, 2003 - Bill Bumgarner, Ronald Oussoren, Steve Majewski, Lele Gaifax, et.al.
4
- Copyright 2003-2024 - Ronald Oussoren
4
+ Copyright 2003-2025 - Ronald Oussoren
5
5
 
6
6
  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
7
7
 
@@ -0,0 +1,64 @@
1
+ #define PY_SSIZE_T_CLEAN
2
+ #include "Python.h"
3
+ #include "pyobjc-api.h"
4
+
5
+ #import <Foundation/Foundation.h>
6
+ #import <PushKit/PushKit.h>
7
+
8
+ /* We include the source code here instead of
9
+ * using the linker due to limitations in pyobjc-api.h
10
+ */
11
+ #include "_PushKit_protocols.m"
12
+
13
+ static PyMethodDef mod_methods[] = {
14
+ {0, 0, 0, 0} /* sentinel */
15
+ };
16
+
17
+ static int
18
+ mod_exec_module(PyObject* m)
19
+ {
20
+ return 0;
21
+ }
22
+
23
+ static struct PyModuleDef_Slot mod_slots[] = {
24
+ {.slot = Py_mod_exec, .value = (void*)mod_exec_module},
25
+ #if PY_VERSION_HEX >= 0x030c0000
26
+ {
27
+ /* This extension does not use the CPython API other than initializing
28
+ * the module, hence is safe with subinterpreters and per-interpreter
29
+ * GILs
30
+ */
31
+ .slot = Py_mod_multiple_interpreters,
32
+ .value = Py_MOD_PER_INTERPRETER_GIL_SUPPORTED,
33
+ },
34
+ #endif
35
+ #if PY_VERSION_HEX >= 0x030d0000
36
+ {
37
+ /* The code in this extension should be safe to use without the GIL */
38
+ .slot = Py_mod_gil,
39
+ .value = Py_MOD_GIL_NOT_USED,
40
+ },
41
+ #endif
42
+ {/* Sentinel */
43
+ .slot = 0,
44
+ .value = 0}};
45
+
46
+ static struct PyModuleDef mod_module = {
47
+ .m_base = PyModuleDef_HEAD_INIT,
48
+ .m_name = "_PushKit",
49
+ .m_doc = NULL,
50
+ .m_size = 0,
51
+ .m_methods = mod_methods,
52
+ .m_slots = mod_slots,
53
+ .m_traverse = NULL,
54
+ .m_clear = NULL,
55
+ .m_free = NULL,
56
+ };
57
+
58
+ PyObject* PyInit__PushKit(void);
59
+
60
+ PyObject* __attribute__((__visibility__("default")))
61
+ PyInit__PushKit(void)
62
+ {
63
+ return PyModuleDef_Init(&mod_module);
64
+ }
@@ -1,4 +1,5 @@
1
- static void __attribute__((__used__)) use_protocols(void)
1
+ static void __attribute__((__used__))
2
+ use_protocols(void)
2
3
  {
3
4
  PyObject* p __attribute__((__unused__));
4
5
  #if PyObjC_BUILD_RELEASE >= 1015
@@ -53,8 +53,9 @@ NS_ASSUME_NONNULL_BEGIN
53
53
  /*
54
54
  * Only add items to the end of this list!
55
55
  */
56
+
56
57
  typedef int(RegisterMethodMappingFunctionType)(
57
- Class, SEL,
58
+ Class _Nullable, SEL,
58
59
  PyObject* _Nullable (*_Nonnull)(PyObject* _Nonnull, PyObject* _Nonnull,
59
60
  PyObject* _Nonnull const* _Nonnull, size_t),
60
61
  IMP _Nullable (*_Nonnull)(PyObject* _Nonnull, PyObject* _Nonnull));
@@ -83,7 +84,8 @@ struct pyobjc_api {
83
84
  PyObject* _Nullable (*_Nonnull unsupported_method_caller)(
84
85
  PyObject* _Nonnull, PyObject* _Nonnull, PyObject* _Nonnull const* _Nonnull,
85
86
  size_t);
86
- void (*_Nonnull err_python_to_objc_gil)(PyGILState_STATE* _Nonnull state);
87
+ void (*_Nonnull err_python_to_objc_gil)(PyGILState_STATE* _Nonnull state)
88
+ __attribute__((__noreturn__));
87
89
  int (*_Nonnull simplify_sig)(const char* signature, char* buf, size_t buflen);
88
90
  void (*_Nonnull free_c_array)(int, Py_buffer*);
89
91
  int (*_Nonnull py_to_c_array)(BOOL, BOOL, const char* _Nonnull, PyObject* _Nonnull,
@@ -113,7 +115,8 @@ struct pyobjc_api {
113
115
  int (*_Nonnull checknokwnames)(PyObject* _Nonnull callable,
114
116
  PyObject* _Nullable kwnames);
115
117
 
116
- PyObject* _Nullable (*_Nonnull createopaquepointertype)(const char*, const char*, const char*);
118
+ PyObject* _Nullable (*_Nonnull createopaquepointertype)(const char*, const char*,
119
+ const char*);
117
120
  };
118
121
 
119
122
  #ifndef PYOBJC_BUILD
@@ -0,0 +1,371 @@
1
+ #ifndef PyObjC_COMPAT_H
2
+ #define PyObjC_COMPAT_H
3
+
4
+ #ifndef NS_ASSUME_NONNULL_BEGIN
5
+ /* Old compiler without the Nullability attributes */
6
+ #define NS_ASSUME_NONNULL_BEGIN
7
+ #define NS_ASSUME_NONNULL_END
8
+ #define _Nullable
9
+ #define _Nonnull
10
+ #endif
11
+
12
+ NS_ASSUME_NONNULL_BEGIN
13
+
14
+ #ifdef USE_STATIC_ANALYZER
15
+ #define CLANG_SUPPRESS [[clang::suppress]]
16
+ #else
17
+ #define CLANG_SUPPRESS
18
+ #endif
19
+
20
+ /*
21
+ *
22
+ * Start of compiler definitions
23
+ *
24
+ */
25
+ #if 0
26
+ #ifndef __has_feature
27
+ #define __has_feature(x) 0
28
+ #endif
29
+ #ifndef __has_extension
30
+ #define __has_extension(x) __has_feature(x)
31
+ #endif
32
+ #endif
33
+
34
+ #if __has_extension(c_static_assert)
35
+ #define STATIC_ASSERT(test, message) _Static_assert(test, message)
36
+ #else
37
+ #define STATIC_ASSERT(test, message) \
38
+ switch (0) { \
39
+ case 0: \
40
+ case test:; \
41
+ }
42
+ #endif
43
+
44
+ #if !__has_feature(objc_instancetype)
45
+ #define instancetype id
46
+ #endif
47
+
48
+ #ifdef __has_attribute
49
+ #if __has_attribute(objc_subclassing_restricted)
50
+ #define PyObjC_FINAL_CLASS __attribute__((__objc_subclassing_restricted__))
51
+ #endif
52
+ #endif
53
+ #ifndef PyObjC_FINAL_CLASS
54
+ #define PyObjC_FINAL_CLASS
55
+ #endif
56
+
57
+ /*
58
+ *
59
+ * Start of compiler support helpers
60
+ */
61
+
62
+ #define unlikely(x) __builtin_expect(!!(x), 0)
63
+ #define likely(x) __builtin_expect(!!(x), 1)
64
+
65
+ /*
66
+ *
67
+ * Python version compatibility
68
+ *
69
+ */
70
+
71
+ #ifndef Py_SET_TYPE
72
+ #define Py_SET_TYPE(obj, type) \
73
+ do { \
74
+ Py_TYPE((obj)) = (type); \
75
+ } while (0)
76
+ #endif
77
+
78
+ #ifndef Py_SET_SIZE
79
+ #define Py_SET_SIZE(obj, size) \
80
+ do { \
81
+ Py_SIZE((obj)) = (size); \
82
+ } while (0)
83
+ #endif
84
+
85
+ #ifndef Py_SET_REFCNT
86
+ #define Py_SET_REFCNT(obj, count) \
87
+ do { \
88
+ Py_REFCNT((obj)) = (count); \
89
+ } while (0)
90
+ #endif
91
+
92
+ /* Use CLINIC_SEP between the prototype and
93
+ * description in doc strings, to get clean
94
+ * docstrings.
95
+ */
96
+ #define CLINIC_SEP "--\n"
97
+
98
+ extern int PyObjC_Cmp(PyObject* o1, PyObject* o2, int* result);
99
+
100
+ #ifdef __clang__
101
+
102
+ #ifndef Py_LIMITED_API
103
+
104
+ static inline PyObject* _Nullable* _Nonnull PyTuple_ITEMS(PyObject* tuple)
105
+ {
106
+ return &PyTuple_GET_ITEM(tuple, 0); // LCOV_BR_EXCL_LINE
107
+ }
108
+
109
+ /* This is a crude hack to disable a otherwise useful warning in the context of
110
+ * PyTuple_SET_ITEM, without disabling it everywhere
111
+ */
112
+ #pragma clang diagnostic push
113
+ #pragma clang diagnostic ignored "-Warray-bounds"
114
+ static inline void
115
+ _PyObjCTuple_SetItem(PyObject* tuple, Py_ssize_t idx, PyObject* _Nullable value)
116
+ {
117
+ PyTuple_SET_ITEM(tuple, idx, value);
118
+ }
119
+ #undef PyTuple_SET_ITEM
120
+ #define PyTuple_SET_ITEM(a, b, c) _PyObjCTuple_SetItem(a, b, c)
121
+
122
+ static inline PyObject*
123
+ _PyObjCTuple_GetItem(PyObject* tuple, Py_ssize_t idx)
124
+ {
125
+ /* The protocol for tuples is that they are full initialized
126
+ * before handing them over to other code.
127
+ */
128
+ return (PyObject* _Nonnull)PyTuple_GET_ITEM(tuple, idx); // LCOV_BR_EXCL_LINE
129
+ }
130
+ #undef PyTuple_GET_ITEM
131
+ #define PyTuple_GET_ITEM(a, b) _PyObjCTuple_GetItem(a, b)
132
+
133
+ #pragma clang diagnostic pop
134
+
135
+ #endif /* !Py_LIMITED_API */
136
+
137
+ #endif /* __clang__ */
138
+
139
+ #define PyObjC_BEGIN_WITH_GIL \
140
+ { \
141
+ PyGILState_STATE _GILState; \
142
+ _GILState = PyGILState_Ensure();
143
+
144
+ #define PyObjC_GIL_FORWARD_EXC() \
145
+ do { \
146
+ PyObjCErr_ToObjCWithGILState(&_GILState); \
147
+ } while (0)
148
+
149
+ #define PyObjC_GIL_RETURN(val) \
150
+ do { \
151
+ PyGILState_Release(_GILState); \
152
+ return (val); \
153
+ } while (0)
154
+
155
+ #define PyObjC_GIL_RETURNVOID \
156
+ do { \
157
+ PyGILState_Release(_GILState); \
158
+ return; \
159
+ } while (0)
160
+
161
+ #define PyObjC_END_WITH_GIL \
162
+ PyGILState_Release(_GILState); \
163
+ }
164
+
165
+ #define PyObjC_LEAVE_GIL \
166
+ do { \
167
+ PyGILState_Release(_GILState); \
168
+ } while (0)
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
+ #if PY_VERSION_HEX < 0x030d0000
189
+ #define Py_BEGIN_CRITICAL_SECTION(value) \
190
+ { \
191
+ (void)(value);
192
+ #define Py_END_CRITICAL_SECTION() }
193
+ #define Py_EXIT_CRITICAL_SECTION() ((void)0)
194
+
195
+ #define Py_BEGIN_CRITICAL_SECTION2(value1, value2) \
196
+ { \
197
+ (void)(value1); \
198
+ (void)(value2);
199
+ #define Py_END_CRITICAL_SECTION2() }
200
+ #define Py_EXIT_CRITICAL_SECTION2() ((void)0)
201
+
202
+ #define PyObjC_ATOMIC
203
+
204
+ #else
205
+
206
+ #ifdef Py_GIL_DISABLED
207
+ #define Py_EXIT_CRITICAL_SECTION() PyCriticalSection_End(&_py_cs)
208
+ #define Py_EXIT_CRITICAL_SECTION2() PyCriticalSection2_End(&_py_cs2)
209
+ #define PyObjC_ATOMIC _Atomic
210
+ #else
211
+ #define Py_EXIT_CRITICAL_SECTION() ((void)0)
212
+ #define Py_EXIT_CRITICAL_SECTION2() ((void)0)
213
+ #define PyObjC_ATOMIC
214
+ #endif
215
+
216
+ #endif
217
+
218
+ #if PY_VERSION_HEX < 0x030d0000
219
+ static inline int
220
+ PyDict_GetItemRef(PyObject* p, PyObject* key, PyObject* _Nonnull* _Nullable result)
221
+ {
222
+ *result = PyDict_GetItemWithError(p, key);
223
+ if (*result == NULL) {
224
+ if (PyErr_Occurred()) {
225
+ return -1;
226
+ } else {
227
+ return 0;
228
+ }
229
+ } else {
230
+ Py_INCREF(*result);
231
+ return 1;
232
+ }
233
+ }
234
+
235
+ static inline PyObject* _Nullable PyList_GetItemRef(PyObject* l, Py_ssize_t i)
236
+ {
237
+ PyObject* result = PyList_GetItem(l, i);
238
+ Py_XINCREF(result);
239
+ return result;
240
+ }
241
+
242
+ static inline int
243
+ PyDict_SetDefaultRef(PyObject* p, PyObject* key, PyObject* default_value,
244
+ PyObject* _Nonnull* _Nullable result)
245
+ {
246
+ *result = PyDict_SetDefault(p, key, default_value);
247
+ if (*result == NULL) {
248
+ return -1;
249
+ }
250
+ Py_INCREF(*result);
251
+
252
+ /* This does not follow the spec, should return 1 when the key was already
253
+ * in the dict. That part of the API is not used in PyObjC though.
254
+ */
255
+ return 0;
256
+ }
257
+
258
+ #endif
259
+
260
+ #if PY_VERSION_HEX < 0x030c0000
261
+ static inline PyObject*
262
+ PyType_GetDict(PyTypeObject* type)
263
+ {
264
+ PyObject* result = type->tp_dict;
265
+ Py_INCREF(result);
266
+ return result;
267
+ }
268
+ #endif
269
+
270
+ #if PY_VERSION_HEX >= 0x030c0000 && PY_VERSION_HEX < 0x030e0000
271
+ /*
272
+ * These are available in 3.14 and above, the definitions below
273
+ * mirror the private implementation in 3.13.
274
+ */
275
+ static inline int
276
+ PyUnstable_Object_IsUniquelyReferenced(PyObject* ob)
277
+ {
278
+ #ifdef Py_GIL_DISABLED
279
+ return (_Py_IsOwnedByCurrentThread(ob)
280
+ && _Py_atomic_load_uint32_relaxed(&ob->ob_ref_local) == 1
281
+ && _Py_atomic_load_ssize_relaxed(&ob->ob_ref_shared) == 0);
282
+ #else
283
+ return Py_REFCNT(ob) == 1;
284
+ #endif
285
+ }
286
+
287
+ static inline void
288
+ PyUnstable_EnableTryIncRef(PyObject* op __attribute__((__unused__)))
289
+ {
290
+ #ifdef Py_GIL_DISABLED
291
+ for (;;) {
292
+ Py_ssize_t shared = _Py_atomic_load_ssize_relaxed(&op->ob_ref_shared);
293
+ if ((shared & _Py_REF_SHARED_FLAG_MASK) != 0) {
294
+ // Nothing to do if it's in WEAKREFS, QUEUED, or MERGED states.
295
+ return;
296
+ }
297
+ if (_Py_atomic_compare_exchange_ssize(&op->ob_ref_shared, &shared,
298
+ shared | _Py_REF_MAYBE_WEAKREF)) {
299
+ return;
300
+ }
301
+ }
302
+ #endif
303
+ }
304
+
305
+ #ifdef Py_GIL_DISABLED
306
+ static inline int
307
+ _Py_TryIncrefFast(PyObject* op)
308
+ {
309
+ uint32_t local = _Py_atomic_load_uint32_relaxed(&op->ob_ref_local);
310
+ local += 1;
311
+ if (local == 0) {
312
+ // immortal
313
+ return 1;
314
+ }
315
+ if (_Py_IsOwnedByCurrentThread(op)) {
316
+ _Py_INCREF_STAT_INC();
317
+ _Py_atomic_store_uint32_relaxed(&op->ob_ref_local, local);
318
+ #ifdef Py_REF_DEBUG
319
+ _Py_IncRefTotal(_PyThreadState_GET());
320
+ #endif
321
+ return 1;
322
+ }
323
+ return 0;
324
+ }
325
+
326
+ static inline int
327
+ _Py_TryIncRefShared(PyObject* op)
328
+ {
329
+ Py_ssize_t shared = _Py_atomic_load_ssize_relaxed(&op->ob_ref_shared);
330
+ for (;;) {
331
+ // If the shared refcount is zero and the object is either merged
332
+ // or may not have weak references, then we cannot incref it.
333
+ if (shared == 0 || shared == _Py_REF_MERGED) {
334
+ return 0;
335
+ }
336
+
337
+ if (_Py_atomic_compare_exchange_ssize(&op->ob_ref_shared, &shared,
338
+ shared + (1 << _Py_REF_SHARED_SHIFT))) {
339
+ #ifdef Py_REF_DEBUG
340
+ _Py_IncRefTotal(_PyThreadState_GET());
341
+ #endif
342
+ _Py_INCREF_STAT_INC();
343
+ return 1;
344
+ }
345
+ }
346
+ }
347
+ #endif
348
+
349
+ static inline int
350
+ PyUnstable_TryIncRef(PyObject* op __attribute__((__unused__)))
351
+ {
352
+ #ifdef Py_GIL_DISABLED
353
+ return _Py_TryIncrefFast(op) || _Py_TryIncRefShared(op);
354
+ #else
355
+ if (Py_REFCNT(op) > 0) {
356
+ Py_INCREF(op);
357
+ return 1;
358
+ }
359
+ return 0;
360
+ #endif
361
+ }
362
+ #endif
363
+
364
+ #if PY_VERSION_HEX < 0x030f00a7
365
+ #define PyAnyDict_CheckExact PyDict_CheckExact
366
+ #define PyAnyDict_Check PyDict_Check
367
+ #endif
368
+
369
+ NS_ASSUME_NONNULL_END
370
+
371
+ #endif /* PyObjC_COMPAT_H */
@@ -1,37 +1,49 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.4
2
2
  Name: pyobjc-framework-PushKit
3
- Version: 10.3.2
3
+ Version: 12.2.2
4
4
  Summary: Wrappers for the framework PushKit on macOS
5
5
  Home-page: https://github.com/ronaldoussoren/pyobjc
6
6
  Author: Ronald Oussoren
7
7
  Author-email: pyobjc-dev@lists.sourceforge.net
8
- License: MIT License
8
+ License: MIT
9
9
  Keywords: PyObjC,PushKit
10
10
  Platform: MacOS X (>=10.15)
11
11
  Classifier: Development Status :: 5 - Production/Stable
12
12
  Classifier: Environment :: Console
13
13
  Classifier: Environment :: MacOS X :: Cocoa
14
14
  Classifier: Intended Audience :: Developers
15
- Classifier: License :: OSI Approved :: MIT License
16
15
  Classifier: Natural Language :: English
17
16
  Classifier: Operating System :: MacOS :: MacOS X
18
17
  Classifier: Programming Language :: Python
19
18
  Classifier: Programming Language :: Python :: 3
20
19
  Classifier: Programming Language :: Python :: 3 :: Only
21
- Classifier: Programming Language :: Python :: 3.8
22
- Classifier: Programming Language :: Python :: 3.9
23
20
  Classifier: Programming Language :: Python :: 3.10
24
21
  Classifier: Programming Language :: Python :: 3.11
25
22
  Classifier: Programming Language :: Python :: 3.12
26
23
  Classifier: Programming Language :: Python :: 3.13
24
+ Classifier: Programming Language :: Python :: 3.14
25
+ Classifier: Programming Language :: Python :: 3.15
27
26
  Classifier: Programming Language :: Python :: Implementation :: CPython
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.8
31
+ Requires-Python: >=3.10
32
32
  Description-Content-Type: text/x-rst; charset=UTF-8
33
- Requires-Dist: pyobjc-core>=10.3.2
34
- Requires-Dist: pyobjc-framework-Cocoa>=10.3.2
33
+ Requires-Dist: pyobjc-core>=12.2.2
34
+ Requires-Dist: pyobjc-framework-Cocoa>=12.2.2
35
+ Dynamic: author
36
+ Dynamic: author-email
37
+ Dynamic: classifier
38
+ Dynamic: description
39
+ Dynamic: description-content-type
40
+ Dynamic: home-page
41
+ Dynamic: keywords
42
+ Dynamic: license
43
+ Dynamic: platform
44
+ Dynamic: requires-dist
45
+ Dynamic: requires-python
46
+ Dynamic: summary
35
47
 
36
48
 
37
49
  Wrappers for the "PushKit" framework on macOS 10.15 and later.
@@ -0,0 +1 @@
1
+ """tests"""