General Troubleshooting Steps
Before diving into specific issues, try these general troubleshooting steps:-
Clean the project and get dependencies:
-
Update Flutter and dependencies:
-
Ensure Para package is up to date: Check your
pubspec.yaml
file and update the Para package version if necessary. -
Rebuild the project:
Common Issues and Solutions
1. Package Not Found or Version Conflicts
Problem: Dart can’t find the Para package or there are version conflicts with other dependencies. Solution: Ensure yourpubspec.yaml
file is correctly configured:
pubspec.yaml
, run:
2. Platform-Specific Setup Issues
Problem: Para features not working on specific platforms (iOS/Android). Solution: Ensure platform-specific configurations are correct: For iOS (ios/Runner/Info.plist
):
android/app/build.gradle
):
3. V2 API Initialization Errors
Problem: Para v2 fails to initialize or throws errors on startup. Solution: Ensure proper initialization with requiredappScheme
parameter:
- Missing
appScheme
parameter - Incorrect environment configuration
- Invalid API key format
4. V2 API ParaFuture Handling Errors
Problem: Errors when handlingParaFuture
operations in v2 API.
Solution: Ensure proper ParaFuture
handling with cancellation support:
- Not awaiting the
.future
property - Incorrect cancellation handling
- Missing error type checking for
ParaBridgeException
5. UI Thread Blocking
Problem: Para operations blocking the UI thread. Solution: Usecompute
function for heavy computations:
6. Platform Channel Errors
Problem: Errors related to platform channel communication. Solution: Ensure the latest version of Para Flutter plugin is used and platform-specific code is correctly implemented. If issues persist, check the plugin’s GitHub repository for any known issues or updates.V2-Specific Issues
7. Authentication Flow Errors
Problem: V2 authentication flow failing or returning unexpected states. Solution: Follow the correct v2 authentication pattern:8. OAuth Integration Issues
Problem: OAuth flows failing or not redirecting properly. Solution: Ensure deep link configuration matches OAuth setup:9. Extension Methods Not Found
Problem:initiateAuthFlow()
or other extension methods not available.
Solution: Import the auth extensions:
Best Practices for V2
-
Use ParaFuture Properly: Always await the
.future
property and handle cancellation where appropriate. -
Error Handling: Implement robust error handling with specific exception types:
-
Session Management: Use v2 session methods for persistence:
- State Management: Use proper state management for v2 authentication flows.
- Deep Link Security: Validate deep link callbacks to prevent malicious redirects.
- Testing: Write unit and integration tests for your Para v2 integration.
-
Performance Monitoring: Monitor
ParaFuture
operations for performance. - Keep Updated: Regularly update to the latest v2 API changes.
Debugging Tips
-
Enable Verbose Logging: Enable verbose logging for Para operations to get more detailed information:
- Use Flutter DevTools: Utilize Flutter DevTools for performance profiling and debugging.
- Platform-Specific Debugging: For platform-specific issues, use Xcode for iOS and Android Studio for Android debugging.
Setup and Integration Issues
Para SDK initialization fails
Para SDK initialization fails
If you’re having trouble initializing the Para SDK:
- Ensure you’re providing the required
appScheme
parameter - Verify that you’re using the correct API key and environment
- Check that all necessary dependencies are installed properly
- Look for any Dart errors in your Flutter debug console
- Verify that your Flutter version is compatible with the Para SDK
Passkey operations fail or throw errors
Passkey operations fail or throw errors
If passkey creation, retrieval, or usage isn’t working:
- Verify that you’ve set up associated domains correctly in your iOS project
- For Android, check that you’ve configured your
build.gradle
file with the namespace fix - Make sure you’ve provided the correct SHA-256 fingerprint to the Para team for Android
- Ensure that biometric authentication is enabled on the test device
- For Android, confirm the test device has a Google account signed in
- Check that
WebAuthenticationSession
is properly configured
Authentication fails or API requests are rejected
Authentication fails or API requests are rejected
If you’re experiencing authentication issues:
- Double-check that your API key is correct and properly set in your Para client initialization
- Verify you’re using the correct environment (
beta
orprod
) that matches your API key - Ensure your account has the necessary permissions for the operations you’re attempting
- Check that your deep link scheme matches what’s configured in your app
- Verify the authentication flow is being followed correctly (verify → signup/login)
V2 Migration Issues
V2 Migration Issues
If you’re migrating from V1 to V2:
- Replace
signUpOrLogIn()
withinitiateAuthFlow()
- Replace
verifyNewAccount()
withverifyOtp()
- Replace
loginWithPasskey()
withhandleLogin()
- Remove calls to
init()
- it no longer exists - Update constructor to use
Para.fromConfig()
factory method - Add the required
appScheme
parameter (now without ://callback suffix) - Update wallet creation to use
handleSignup()
withSignupMethod.passkey
or.password
Integration Support
If you’re experiencing issues that aren’t resolved by our troubleshooting resources, please contact our team for assistance. To help us resolve your issue quickly, please include the following information in your request:- 1
A detailed description of the problem you’re encountering.
- 2
Any relevant error messages or logs.
- 3
Steps to reproduce the issue.
- 4
Details about your system or environment (e.g., device, operating system, software version).