Installation Issues
CocoaPods: Pod not found
CocoaPods: Pod not found
Error:
Unable to find a specification for 'Permutive_iOS'Solutions:- Update your CocoaPods repo:
- Ensure CocoaPods is version 1.9.1 or later:
- Clear the cache:
SPM: Package resolution failed
SPM: Package resolution failed
Error: Xcode cannot resolve the package.Solutions:
- Check your network connection
- Reset package caches: File → Packages → Reset Package Caches
- Verify the URL is correct:
https://github.com/permutive-engineering/permutive-ios-spm - Try removing and re-adding the package
Module not found after installation
Module not found after installation
Error:
No such module 'Permutive_iOS'Solutions:- Clean build folder: Product → Clean Build Folder (⇧⌘K)
- For CocoaPods: Ensure you opened the
.xcworkspacefile, not.xcodeproj - Restart Xcode
- For SPM: Reset package caches
Bitcode errors
Bitcode errors
Error: Bitcode-related build errors.Solution: Disable Bitcode in your target’s Build Settings:
- Set Enable Bitcode to No
Duplicate symbols
Duplicate symbols
Error: Duplicate symbol errors during linking.Solutions:
- Ensure you’re not mixing CocoaPods and SPM for Permutive
- Check for conflicting library versions
- Clean derived data:
rm -rf ~/Library/Developer/Xcode/DerivedData
Initialization Issues
Options returns nil
Options returns nil
Problem:
Options(apiKey:organisationId:workspaceId:) returns nil.Causes:- Empty or whitespace-only credentials
- Invalid credential format
Initialization fails silently
Initialization fails silently
Problem: No error, but SDK doesn’t seem to work.Solution: Enable debug logging and check for errors:
Network error during initialization
Network error during initialization
Problem: Initialization fails with network error.Solutions:
- Check device network connectivity
- Verify no firewall is blocking Permutive domains
- Check if running on simulator with network issues
- Retry initialization:
SDK not ready when tracking
SDK not ready when tracking
Problem: Events tracked before initialization completes are lost.Solution: Wait for the completion callback:
Tracking Issues
Events rejected with schema error
Events rejected with schema error
Error:Causes:
- Property names don’t match schema
- Property types don’t match schema
- Extra properties not in schema
- Check your Permutive dashboard for the correct schema
- Verify property names exactly (case-sensitive)
- Remove any extra properties
- Verify property types match (string, int, bool, etc.)
EventProperties init throws
EventProperties init throws
Error:
EventProperties constructor throws an exception.Causes:- Unsupported value types
- Invalid nested objects
Pageview event not firing
Pageview event not firing
Problem: No Pageview event in logs.Solutions:
- Ensure
resume()is called: - Check PageTracker was created successfully
- Verify SDK is initialized before creating PageTracker
- Enable debug logging
PageTracker stops unexpectedly
PageTracker stops unexpectedly
Problem: PageTracker stops when navigating or creating new trackers.Cause: Only one PageTracker/MediaTracker can be active at a time.Solution: This is expected behavior. Creating a new tracker stops any existing one. Design your flow accordingly.
No log output
No log output
Problem: Console is silent, no Permutive logs appear.Solutions:
- Confirm
logModesis set beforestart(): - Check Xcode console filter isn’t hiding messages
- Verify SDK is actually being initialized
Cohort and Activation Issues
Empty cohorts
Empty cohorts
Problem:
Permutive.shared.cohorts returns an empty set.Causes:- SDK just initialized (cohorts not yet synced)
- No events tracked yet
- User doesn’t qualify for any cohorts
- Wait a few seconds after initialization
- Track some events to generate data
- Use TriggerProvider for reactive updates
- Check your dashboard for cohort definitions
Activations different from cohorts
Activations different from cohorts
Problem: User is in a cohort but it doesn’t appear in activations.Cause: Not all cohorts are activated for all platforms.Solution: Check your Permutive dashboard configuration. Activations must be explicitly configured for each platform (GAM, Xandr, etc.).
Contextual cohorts not appearing
Contextual cohorts not appearing
Problem:
dfp_contextual or appnexus_adserver_contextual is empty.Solutions:- Verify contextual features are enabled (contact your CSM)
- Update to SDK 2.0.0+
- Ensure PageTracker has a valid, publicly accessible URL
- Allow time for content analysis (1-2 seconds)
- Check debug logs for classification errors
Identity Issues
setIdentityForIDFA fails
setIdentityForIDFA fails
Error:
setIdentityForIDFA throws an error.Cause: IDFA is all zeros (tracking denied/restricted).Solution:Reserved tag error
Reserved tag error
Problem: Alias with certain tags is ignored.Cause: Reserved tags:
appnexus, amp, gigya, sailthru, aaidSolution: Use custom tag names:Identity not merging across devices
Identity not merging across devices
Problem: Same user appears as different users on different devices.Solution: Use consistent identifiers that work across devices:
Ad Integration Issues
No targeting data in ad request
No targeting data in ad request
Problem:
googleCustomTargeting returns empty or minimal data.Solutions:- Verify SDK is initialized before calling
- Check that cohorts exist for the user
- Wait for cohort data to sync after initialization
- Enable debug logging to see activations
View ID missing from targeting
View ID missing from targeting
Problem:
prmtvvid key not in targeting dictionary.Solution: Pass the active PageTracker:TriggerProvider Issues
Trigger callbacks not firing
Trigger callbacks not firing
Problem: No callbacks when cohort membership changes.Solutions:
- Store a strong reference to TriggerAction:
- Verify cohort IDs match your dashboard exactly
- Enable debug logging to see cohort updates
Trigger stops working
Trigger stops working
Problem: Trigger worked initially but stopped.Cause: TriggerAction reference was released.Solution: Keep TriggerAction as an instance property for the lifetime you need it.
Debug Logging
Enable comprehensive logging for troubleshooting:Log Messages to Look For
| Message | Meaning |
|---|---|
SDK ready | Initialization successful |
Accepted: X / X | Events sent successfully |
event rejection | Schema validation failed |
Schema validation failed | Property mismatch |
Getting Help
If you can’t resolve an issue:- Enable debug logging and capture relevant logs
- Check SDK version - ensure you’re on the latest
- Contact support:
- SDK version
- iOS/tvOS version
- Xcode version
- Relevant logs
- Steps to reproduce