Registry /
aws / pyobjc-framework-cloudkit
Install & Compatibility
Where this runs
tested against v? · pip install
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
muslpy 3.10–3.920 runs
build_error
glibcpy 3.10–3.920 runs
build_error
Code
Verified usage
Verified import paths — ran on the pinned version, not inferred.
CKContainer
✓ from CloudKit import CKContainer
Classes and functions from the CloudKit framework are imported directly from the `CloudKit` module after installing `pyobjc-framework-cloudkit`.
This quickstart demonstrates how to import and interact with basic CloudKit objects like `CKContainer` and `CKRecord`. Note that CloudKit operations fundamentally require a macOS application with specific entitlements and a developer certificate to function correctly in a real-world scenario.
import objc
from Foundation import NSObject
from CloudKit import CKContainer, CKRecord
# CloudKit APIs generally require an app with appropriate entitlements and a developer certificate.
# This is a minimal example showing how to access a CloudKit class.
# To run successfully, this code needs to be part of a macOS app bundle
# with CloudKit entitlements enabled.
def get_default_container_name():
try:
# Access the default CloudKit container
default_container = CKContainer.defaultContainer()
print(f"Accessed default CKContainer: {default_container}")
# Example: Getting the container identifier (CKContainerIdentifier is a string)
print(f"Default container identifier: {default_container.containerIdentifier()}")
# Instantiate a CKRecord (example, won't be saved without proper setup)
record = CKRecord.alloc().initWithRecordType_('MyCustomRecordType')
print(f"Created CKRecord: {record.recordType()}")
except objc.nosuchmethod_error as e:
print(f"Error: CloudKit method not found or framework not available. {e}")
print("Ensure you are running on macOS and have the necessary Xcode command-line tools and app entitlements.")
except Exception as e:
print(f"An unexpected error occurred: {e}")
if __name__ == '__main__':
get_default_container_name()
Debug
Known issues
breakingPyObjC 12.0 dropped support for Python 3.9. Users on Python 3.9 must use an earlier version of PyObjC.fixUpgrade to Python 3.10 or later, or pin `pyobjc` to `<12.0`.
affects: >=12.0
breakingPyObjC 11.0 dropped support for Python 3.8. Users on Python 3.8 must use an earlier version of PyObjC.fixUpgrade to Python 3.9 or later, or pin `pyobjc` to `<11.0`.
affects: >=11.0
breakingAs of PyObjC 10.0, the 'IMServicePlugIn' framework bindings were removed. This framework was deprecated in macOS 10.13 and removed in macOS 14.fixMigrate away from using the 'IMServicePlugIn' framework. If still needed, pin `pyobjc` to `<10.0` and target an older macOS version.
affects: >=10.0
gotchaIn PyObjC 11.1, the core bridge's behavior for initializer methods (`init` family) was aligned with `clang`'s Automatic Reference Counting (ARC) documentation. This means `init` methods now correctly model stealing a reference to `self` and returning a new reference, which might change behavior for code relying on previous reference counting assumptions.fixReview code that interacts with Objective-C `init` methods and adjust for standard ARC behavior. Consult Apple's ARC documentation.
affects: >=11.1
gotchaCloudKit is an AppStore-only API and requires a developer certificate and specific entitlements configured in an Xcode project (e.g., in `Info.plist`) to function correctly. Python scripts interacting with CloudKit must be part of a properly signed and entitled macOS application bundle.fixDevelop your PyObjC CloudKit application within an Xcode project, ensure it has the necessary CloudKit entitlements, and that it is signed with a valid developer certificate.
affects: all
gotchaWhile PyObjC 11.0 and later may include experimental support for PEP 703 (free-threading) with Python 3.13, PyObjC does not fully support the experimental free-threading features in Python 3.13 at this time. Using free-threading with PyObjC may lead to undefined behavior or crashes.fixAvoid using PyObjC in a free-threaded Python 3.13 environment until full support is officially announced.
affects: >=11.0, with Python 3.13+
Upgrade
Version history
12.2latest on PyPI · released May 30, 2026
Audit
Dependencies
pyobjc-corerequiredThis package provides the core bridge between Python and Objective-C, which all PyObjC framework bindings rely upon.