pyobjc-framework-SyncServices 11.0__tar.gz → 12.2.1__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 (48) hide show
  1. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/LICENSE.txt +1 -1
  2. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/Lib/SyncServices/_metadata.py +1 -30
  3. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/Lib/pyobjc_framework_SyncServices.egg-info/PKG-INFO +22 -9
  4. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/Lib/pyobjc_framework_SyncServices.egg-info/SOURCES.txt +2 -10
  5. pyobjc_framework_syncservices-12.2.1/Lib/pyobjc_framework_SyncServices.egg-info/pyobjc-build-info.txt +3 -0
  6. pyobjc_framework_syncservices-12.2.1/Lib/pyobjc_framework_SyncServices.egg-info/requires.txt +3 -0
  7. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/Modules/_SyncServices.m +18 -21
  8. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/Modules/_SyncServices_protocols.m +2 -1
  9. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/Modules/pyobjc-api.h +6 -3
  10. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/Modules/pyobjc-compat.h +137 -86
  11. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/PKG-INFO +22 -9
  12. pyobjc_framework_syncservices-12.2.1/PyObjCTest/__init__.py +1 -0
  13. pyobjc_framework_syncservices-11.0/metadata/raw/arm64-14.5.fwinfo → pyobjc_framework_syncservices-12.2.1/metadata/raw/arm64-26.5.fwinfo +1315 -31
  14. pyobjc_framework_syncservices-11.0/metadata/raw/x86_64-14.5.fwinfo → pyobjc_framework_syncservices-12.2.1/metadata/raw/x86_64-26.5.fwinfo +1315 -31
  15. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/pyobjc_setup.py +12 -45
  16. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/setup.py +1 -1
  17. pyobjc_framework_syncservices-11.0/Lib/pyobjc_framework_SyncServices.egg-info/pyobjc-build-info.txt +0 -3
  18. pyobjc_framework_syncservices-11.0/Lib/pyobjc_framework_SyncServices.egg-info/requires.txt +0 -3
  19. pyobjc_framework_syncservices-11.0/PyObjCTest/__init__.py +0 -1
  20. pyobjc_framework_syncservices-11.0/metadata/raw/arm64-12.3.fwinfo +0 -2931
  21. pyobjc_framework_syncservices-11.0/metadata/raw/arm64-15.0.fwinfo +0 -2947
  22. pyobjc_framework_syncservices-11.0/metadata/raw/x86_64-10.16.fwinfo +0 -2923
  23. pyobjc_framework_syncservices-11.0/metadata/raw/x86_64-10.6.fwinfo +0 -3058
  24. pyobjc_framework_syncservices-11.0/metadata/raw/x86_64-10.7.fwinfo +0 -2922
  25. pyobjc_framework_syncservices-11.0/metadata/raw/x86_64-10.8.fwinfo +0 -2922
  26. pyobjc_framework_syncservices-11.0/metadata/raw/x86_64-12.3.fwinfo +0 -2931
  27. pyobjc_framework_syncservices-11.0/metadata/raw/x86_64-15.0.fwinfo +0 -2947
  28. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/Lib/SyncServices/__init__.py +0 -0
  29. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/Lib/pyobjc_framework_SyncServices.egg-info/dependency_links.txt +0 -0
  30. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/Lib/pyobjc_framework_SyncServices.egg-info/not-zip-safe +0 -0
  31. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/Lib/pyobjc_framework_SyncServices.egg-info/top_level.txt +0 -0
  32. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/MANIFEST.in +0 -0
  33. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/PyObjCTest/test_isyncchange.py +0 -0
  34. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/PyObjCTest/test_isyncclient.py +0 -0
  35. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/PyObjCTest/test_isyncconflictpropertytype.py +0 -0
  36. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/PyObjCTest/test_isynccoredata.py +0 -0
  37. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/PyObjCTest/test_isyncfilter.py +0 -0
  38. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/PyObjCTest/test_isyncmanager.py +0 -0
  39. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/PyObjCTest/test_isyncrecordsnapshot.py +0 -0
  40. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/PyObjCTest/test_isyncsession.py +0 -0
  41. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/PyObjCTest/test_isyncsessiondriver.py +0 -0
  42. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/PyObjCTest/test_syncservices.py +0 -0
  43. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/PyObjCTest/test_syncserviceserrors.py +0 -0
  44. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/README.txt +0 -0
  45. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/metadata/SyncServices.fwinfo +0 -0
  46. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/metadata/metadata.ini +0 -0
  47. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/pyproject.toml +0 -0
  48. {pyobjc_framework_syncservices-11.0 → pyobjc_framework_syncservices-12.2.1}/setup.cfg +0 -0
@@ -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
 
@@ -1,6 +1,6 @@
1
1
  # This file is generated by objective.metadata
2
2
  #
3
- # Last update: Tue Jun 11 10:21:05 2024
3
+ # Last update: Sun May 24 11:59:41 2026
4
4
  #
5
5
  # flake8: noqa
6
6
 
@@ -592,35 +592,6 @@ protocols = {
592
592
  ),
593
593
  ],
594
594
  ),
595
- "ISyncSessionDriverDataSourceOptionalMethods": objc.informal_protocol(
596
- "ISyncSessionDriverDataSourceOptionalMethods",
597
- [
598
- objc.selector(None, b"entityNamesToSync", b"@@:", isRequired=False),
599
- objc.selector(None, b"entityNamesToPull", b"@@:", isRequired=False),
600
- objc.selector(None, b"sessionBeginTimeout", b"d@:", isRequired=False),
601
- objc.selector(None, b"sessionPullChangesTimeout", b"d@:", isRequired=False),
602
- objc.selector(None, b"lastAnchorForEntityName:", b"@@:@", isRequired=False),
603
- objc.selector(None, b"nextAnchorForEntityName:", b"@@:@", isRequired=False),
604
- objc.selector(
605
- None,
606
- b"changedRecordsForEntityName:moreComing:error:",
607
- b"@@:@^Z^@",
608
- isRequired=False,
609
- ),
610
- objc.selector(
611
- None,
612
- b"changesForEntityName:moreComing:error:",
613
- b"@@:@^Z^@",
614
- isRequired=False,
615
- ),
616
- objc.selector(
617
- None,
618
- b"identifiersForRecordsToDeleteForEntityName:moreComing:error:",
619
- b"@@:@^Z^@",
620
- isRequired=False,
621
- ),
622
- ],
623
- ),
624
595
  "SyncUIHelperInformalProtocol": objc.informal_protocol(
625
596
  "SyncUIHelperInformalProtocol",
626
597
  [
@@ -1,39 +1,52 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.4
2
2
  Name: pyobjc-framework-SyncServices
3
- Version: 11.0
3
+ Version: 12.2.1
4
4
  Summary: Wrappers for the framework SyncServices 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,SyncServices
10
10
  Platform: MacOS X
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.9
22
20
  Classifier: Programming Language :: Python :: 3.10
23
21
  Classifier: Programming Language :: Python :: 3.11
24
22
  Classifier: Programming Language :: Python :: 3.12
25
23
  Classifier: Programming Language :: Python :: 3.13
26
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.9
31
+ Requires-Python: >=3.10
32
32
  Description-Content-Type: text/x-rst; charset=UTF-8
33
33
  License-File: LICENSE.txt
34
- Requires-Dist: pyobjc-core>=11.0
35
- Requires-Dist: pyobjc-framework-Cocoa>=11.0
36
- Requires-Dist: pyobjc-framework-CoreData>=11.0
34
+ Requires-Dist: pyobjc-core>=12.2.1
35
+ Requires-Dist: pyobjc-framework-Cocoa>=12.2.1
36
+ Requires-Dist: pyobjc-framework-CoreData>=12.2.1
37
+ Dynamic: author
38
+ Dynamic: author-email
39
+ Dynamic: classifier
40
+ Dynamic: description
41
+ Dynamic: description-content-type
42
+ Dynamic: home-page
43
+ Dynamic: keywords
44
+ Dynamic: license
45
+ Dynamic: license-file
46
+ Dynamic: platform
47
+ Dynamic: requires-dist
48
+ Dynamic: requires-python
49
+ Dynamic: summary
37
50
  Project-URL: Documentation, https://pyobjc.readthedocs.io/en/latest/
38
51
  Project-URL: Issue tracker, https://github.com/ronaldoussoren/pyobjc/issues
39
52
  Project-URL: Repository, https://github.com/ronaldoussoren/pyobjc
@@ -31,13 +31,5 @@ PyObjCTest/test_syncservices.py
31
31
  PyObjCTest/test_syncserviceserrors.py
32
32
  metadata/SyncServices.fwinfo
33
33
  metadata/metadata.ini
34
- metadata/raw/arm64-12.3.fwinfo
35
- metadata/raw/arm64-14.5.fwinfo
36
- metadata/raw/arm64-15.0.fwinfo
37
- metadata/raw/x86_64-10.16.fwinfo
38
- metadata/raw/x86_64-10.6.fwinfo
39
- metadata/raw/x86_64-10.7.fwinfo
40
- metadata/raw/x86_64-10.8.fwinfo
41
- metadata/raw/x86_64-12.3.fwinfo
42
- metadata/raw/x86_64-14.5.fwinfo
43
- metadata/raw/x86_64-15.0.fwinfo
34
+ metadata/raw/arm64-26.5.fwinfo
35
+ metadata/raw/x86_64-26.5.fwinfo
@@ -0,0 +1,3 @@
1
+ macOS 26.5 (25F71)
2
+ Apple clang version 21.0.0 (clang-2100.1.1.101)
3
+ SDK: macOS 26.5
@@ -0,0 +1,3 @@
1
+ pyobjc-core>=12.2.1
2
+ pyobjc-framework-Cocoa>=12.2.1
3
+ pyobjc-framework-CoreData>=12.2.1
@@ -13,54 +13,51 @@ static PyMethodDef mod_methods[] = {
13
13
  {0, 0, 0, 0} /* sentinel */
14
14
  };
15
15
 
16
- static int mod_exec_module(PyObject* m)
16
+ static int
17
+ mod_exec_module(PyObject* m)
17
18
  {
18
19
  return 0;
19
20
  }
20
21
 
21
22
  static struct PyModuleDef_Slot mod_slots[] = {
22
- {
23
- .slot = Py_mod_exec,
24
- .value = (void*)mod_exec_module
25
- },
23
+ {.slot = Py_mod_exec, .value = (void*)mod_exec_module},
26
24
  #if PY_VERSION_HEX >= 0x030c0000
27
25
  {
28
26
  /* This extension does not use the CPython API other than initializing
29
27
  * the module, hence is safe with subinterpreters and per-interpreter
30
28
  * GILs
31
29
  */
32
- .slot = Py_mod_multiple_interpreters,
30
+ .slot = Py_mod_multiple_interpreters,
33
31
  .value = Py_MOD_PER_INTERPRETER_GIL_SUPPORTED,
34
32
  },
35
33
  #endif
36
34
  #if PY_VERSION_HEX >= 0x030d0000
37
35
  {
38
36
  /* The code in this extension should be safe to use without the GIL */
39
- .slot = Py_mod_gil,
37
+ .slot = Py_mod_gil,
40
38
  .value = Py_MOD_GIL_NOT_USED,
41
39
  },
42
40
  #endif
43
- { /* Sentinel */
44
- .slot = 0,
45
- .value = 0
46
- }
47
- };
41
+ {/* Sentinel */
42
+ .slot = 0,
43
+ .value = 0}};
48
44
 
49
45
  static struct PyModuleDef mod_module = {
50
- .m_base = PyModuleDef_HEAD_INIT,
51
- .m_name = "_SyncServices",
52
- .m_doc = NULL,
53
- .m_size = 0,
54
- .m_methods = mod_methods,
55
- .m_slots = mod_slots,
46
+ .m_base = PyModuleDef_HEAD_INIT,
47
+ .m_name = "_SyncServices",
48
+ .m_doc = NULL,
49
+ .m_size = 0,
50
+ .m_methods = mod_methods,
51
+ .m_slots = mod_slots,
56
52
  .m_traverse = NULL,
57
- .m_clear = NULL,
58
- .m_free = NULL,
53
+ .m_clear = NULL,
54
+ .m_free = NULL,
59
55
  };
60
56
 
61
57
  PyObject* PyInit__SyncServices(void);
62
58
 
63
- PyObject* __attribute__((__visibility__("default"))) PyInit__SyncServices(void)
59
+ PyObject* __attribute__((__visibility__("default")))
60
+ PyInit__SyncServices(void)
64
61
  {
65
62
  return PyModuleDef_Init(&mod_module);
66
63
  }
@@ -6,7 +6,8 @@
6
6
 
7
7
  #import <SyncServices/ISyncConflictPropertyType.h>
8
8
 
9
- static void __attribute__((__used__)) use_protocols(void)
9
+ static void __attribute__((__used__))
10
+ use_protocols(void)
10
11
  {
11
12
  PyObject* p __attribute__((__unused__));
12
13
  p = PyObjC_IdToPython(@protocol(ISyncFiltering));
@@ -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) __attribute__((__noreturn__));
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
@@ -22,12 +22,14 @@ NS_ASSUME_NONNULL_BEGIN
22
22
  * Start of compiler definitions
23
23
  *
24
24
  */
25
+ #if 0
25
26
  #ifndef __has_feature
26
27
  #define __has_feature(x) 0
27
28
  #endif
28
29
  #ifndef __has_extension
29
30
  #define __has_extension(x) __has_feature(x)
30
31
  #endif
32
+ #endif
31
33
 
32
34
  #if __has_extension(c_static_assert)
33
35
  #define STATIC_ASSERT(test, message) _Static_assert(test, message)
@@ -55,46 +57,10 @@ NS_ASSUME_NONNULL_BEGIN
55
57
  /*
56
58
  *
57
59
  * Start of compiler support helpers
58
- *
59
- * XXX: Are these needed?
60
60
  */
61
61
 
62
- #ifdef __GNUC__
63
62
  #define unlikely(x) __builtin_expect(!!(x), 0)
64
63
  #define likely(x) __builtin_expect(!!(x), 1)
65
- #else
66
- #define likely(x) x
67
- #define likely(x) x
68
- #endif
69
-
70
- /* On some versions of GCC <limits.h> defines LONG_LONG_MAX but not LLONG_MAX, compensate.
71
- */
72
- #ifndef LLONG_MIN
73
- #ifdef LONG_LONG_MIN
74
- #define LLONG_MIN LONG_LONG_MIN
75
- #define LLONG_MAX LONG_LONG_MAX
76
- #define ULLONG_MAX ULONG_LONG_MAX
77
- #endif
78
- #endif
79
-
80
- /*
81
- *
82
- * End of compiler support helpers
83
- *
84
- * XXX: These two are no longer needed, all supported platforms
85
- * are 64-bit
86
- */
87
-
88
- #if __LP64__
89
- #define Py_ARG_NSInteger "l"
90
- #define Py_ARG_NSUInteger "k"
91
- #else
92
- #define Py_ARG_NSInteger "i"
93
- #define Py_ARG_NSUInteger "I"
94
- #endif
95
-
96
- #define PyObjC__STR(x) #x
97
- #define PyObjC_STR(x) PyObjC__STR(x)
98
64
 
99
65
  /*
100
66
  *
@@ -123,34 +89,6 @@ NS_ASSUME_NONNULL_BEGIN
123
89
  } while (0)
124
90
  #endif
125
91
 
126
- #if PY_VERSION_HEX < 0x03090000
127
-
128
- /* For use on Python 3.8 and earlier. PyObjC doesn't use the
129
- * "flag" bit internally.
130
- */
131
-
132
- #ifndef PY_VECTORCALL_ARGUMENTS_OFFSET
133
- #define PY_VECTORCALL_ARGUMENTS_OFFSET ((size_t)1 << (8 * sizeof(size_t) - 1))
134
- #endif
135
-
136
- #define PyVectorcall_NARGS(nargsf) ((nargsf) & ~PY_VECTORCALL_ARGUMENTS_OFFSET)
137
-
138
- #ifdef OBJC_VERSION
139
- /* Don't use PyObject prefixed symbols in our binaries */
140
- #define PyObject_Vectorcall PyObjC_Vectorcall
141
- #define PyObject_VectorcallMethod PyObjC_VectorcallMethod
142
-
143
- extern PyObject* _Nullable PyObject_Vectorcall(PyObject* callable,
144
- PyObject* _Nonnull const* _Nonnull args,
145
- size_t nargsf,
146
- PyObject* _Nullable kwnames);
147
- extern PyObject* _Nullable PyObject_VectorcallMethod(
148
- PyObject* name, PyObject* _Nonnull const* _Nonnull args, size_t nargsf,
149
- PyObject* _Nullable kwnames);
150
- #endif
151
-
152
- #endif /* Python < 3.9 */
153
-
154
92
  /* Use CLINIC_SEP between the prototype and
155
93
  * description in doc strings, to get clean
156
94
  * docstrings.
@@ -159,27 +97,13 @@ extern PyObject* _Nullable PyObject_VectorcallMethod(
159
97
 
160
98
  extern int PyObjC_Cmp(PyObject* o1, PyObject* o2, int* result);
161
99
 
162
- /*
163
- * A micro optimization: when using Python 3.3 or later it
164
- * is possible to access a 'char*' with an ASCII representation
165
- * of a unicode object without first converting it to a bytes
166
- * string (if the string can be encoded as ASCII in the first
167
- * place.
168
- *
169
- * This slightly reduces the object allocation rate during
170
- * attribute access.
171
- *
172
- * XXX: Use PyUnicode_AsUTF8 instead.
173
- */
174
- extern const char* _Nullable PyObjC_Unicode_Fast_Bytes(PyObject* object);
175
-
176
100
  #ifdef __clang__
177
101
 
178
102
  #ifndef Py_LIMITED_API
179
103
 
180
104
  static inline PyObject* _Nullable* _Nonnull PyTuple_ITEMS(PyObject* tuple)
181
105
  {
182
- return &PyTuple_GET_ITEM(tuple, 0);
106
+ return &PyTuple_GET_ITEM(tuple, 0); // LCOV_BR_EXCL_LINE
183
107
  }
184
108
 
185
109
  /* This is a crude hack to disable a otherwise useful warning in the context of
@@ -198,7 +122,10 @@ _PyObjCTuple_SetItem(PyObject* tuple, Py_ssize_t idx, PyObject* _Nullable value)
198
122
  static inline PyObject*
199
123
  _PyObjCTuple_GetItem(PyObject* tuple, Py_ssize_t idx)
200
124
  {
201
- return PyTuple_GET_ITEM(tuple, idx);
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
202
129
  }
203
130
  #undef PyTuple_GET_ITEM
204
131
  #define PyTuple_GET_ITEM(a, b) _PyObjCTuple_GetItem(a, b)
@@ -242,13 +169,15 @@ _PyObjCTuple_GetItem(PyObject* tuple, Py_ssize_t idx)
242
169
 
243
170
  #if PY_VERSION_HEX < 0x030a0000
244
171
 
245
- static inline PyObject* Py_NewRef(PyObject* o)
172
+ static inline PyObject*
173
+ Py_NewRef(PyObject* o)
246
174
  {
247
175
  Py_INCREF(o);
248
176
  return o;
249
177
  }
250
178
 
251
- static inline PyObject* Py_XNewRef(PyObject* o)
179
+ static inline PyObject*
180
+ Py_XNewRef(PyObject* o)
252
181
  {
253
182
  Py_XINCREF(o);
254
183
  return o;
@@ -257,11 +186,16 @@ static inline PyObject* Py_XNewRef(PyObject* o)
257
186
  #endif /* PY_VERSION_HEX < 0x030a0000 */
258
187
 
259
188
  #if PY_VERSION_HEX < 0x030d0000
260
- #define Py_BEGIN_CRITICAL_SECTION(value) { (void)(value);
189
+ #define Py_BEGIN_CRITICAL_SECTION(value) \
190
+ { \
191
+ (void)(value);
261
192
  #define Py_END_CRITICAL_SECTION() }
262
193
  #define Py_EXIT_CRITICAL_SECTION() ((void)0)
263
194
 
264
- #define Py_BEGIN_CRITICAL_SECTION2(value1, value2) { (void)(value1); (void)(value2);
195
+ #define Py_BEGIN_CRITICAL_SECTION2(value1, value2) \
196
+ { \
197
+ (void)(value1); \
198
+ (void)(value2);
265
199
  #define Py_END_CRITICAL_SECTION2() }
266
200
  #define Py_EXIT_CRITICAL_SECTION2() ((void)0)
267
201
 
@@ -282,7 +216,8 @@ static inline PyObject* Py_XNewRef(PyObject* o)
282
216
  #endif
283
217
 
284
218
  #if PY_VERSION_HEX < 0x030d0000
285
- static inline int PyDict_GetItemRef(PyObject *p, PyObject *key, PyObject * _Nonnull* _Nullable result)
219
+ static inline int
220
+ PyDict_GetItemRef(PyObject* p, PyObject* key, PyObject* _Nonnull* _Nullable result)
286
221
  {
287
222
  *result = PyDict_GetItemWithError(p, key);
288
223
  if (*result == NULL) {
@@ -303,10 +238,28 @@ static inline PyObject* _Nullable PyList_GetItemRef(PyObject* l, Py_ssize_t i)
303
238
  Py_XINCREF(result);
304
239
  return result;
305
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
+
306
258
  #endif
307
259
 
308
260
  #if PY_VERSION_HEX < 0x030c0000
309
- static inline PyObject* PyType_GetDict(PyTypeObject* type)
261
+ static inline PyObject*
262
+ PyType_GetDict(PyTypeObject* type)
310
263
  {
311
264
  PyObject* result = type->tp_dict;
312
265
  Py_INCREF(result);
@@ -314,6 +267,104 @@ static inline PyObject* PyType_GetDict(PyTypeObject* type)
314
267
  }
315
268
  #endif
316
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
317
368
 
318
369
  NS_ASSUME_NONNULL_END
319
370
 
@@ -1,39 +1,52 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.4
2
2
  Name: pyobjc-framework-SyncServices
3
- Version: 11.0
3
+ Version: 12.2.1
4
4
  Summary: Wrappers for the framework SyncServices 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,SyncServices
10
10
  Platform: MacOS X
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.9
22
20
  Classifier: Programming Language :: Python :: 3.10
23
21
  Classifier: Programming Language :: Python :: 3.11
24
22
  Classifier: Programming Language :: Python :: 3.12
25
23
  Classifier: Programming Language :: Python :: 3.13
26
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.9
31
+ Requires-Python: >=3.10
32
32
  Description-Content-Type: text/x-rst; charset=UTF-8
33
33
  License-File: LICENSE.txt
34
- Requires-Dist: pyobjc-core>=11.0
35
- Requires-Dist: pyobjc-framework-Cocoa>=11.0
36
- Requires-Dist: pyobjc-framework-CoreData>=11.0
34
+ Requires-Dist: pyobjc-core>=12.2.1
35
+ Requires-Dist: pyobjc-framework-Cocoa>=12.2.1
36
+ Requires-Dist: pyobjc-framework-CoreData>=12.2.1
37
+ Dynamic: author
38
+ Dynamic: author-email
39
+ Dynamic: classifier
40
+ Dynamic: description
41
+ Dynamic: description-content-type
42
+ Dynamic: home-page
43
+ Dynamic: keywords
44
+ Dynamic: license
45
+ Dynamic: license-file
46
+ Dynamic: platform
47
+ Dynamic: requires-dist
48
+ Dynamic: requires-python
49
+ Dynamic: summary
37
50
 
38
51
 
39
52
  Wrappers for the "SyncServices" framework on macOS.
@@ -0,0 +1 @@
1
+ """Unittests"""