Draft
Conversation
Co-authored-by: ChasNelson1990 <7795189+ChasNelson1990@users.noreply.github.com>
…onfig Co-authored-by: ChasNelson1990 <7795189+ChasNelson1990@users.noreply.github.com>
Co-authored-by: ChasNelson1990 <7795189+ChasNelson1990@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Update repository to use Python 3.10
Migrate to Python 3.10
Dec 8, 2025
ChasNelson1990
requested changes
Dec 8, 2025
Member
ChasNelson1990
left a comment
There was a problem hiding this comment.
Remove strict-ssl and trusted-host flags - they will not be needed in our systems
Co-authored-by: ChasNelson1990 <7795189+ChasNelson1990@users.noreply.github.com>
Author
Done. Removed |
Member
|
@A-Souhei - I have some additional work on this PR on my other laptop. Focus on those ckanexts for now I think. |
Major changes: - Updated all CKAN core dependencies to 2.11.4 versions - Fixed Flask 3.x compatibility issues - Fixed Python 3.10 collections.abc imports - Updated all CKAN 2.11.4 API changes across extensions - Replaced deprecated ReclineView with DataTablesView - Added missing dependencies: frictionless, markupsafe - Re-added ckanext-pages that was accidentally removed - Updated plugin configuration to remove deprecated view plugins See PYTHON310_CKAN2114_MIGRATION.md for detailed change log.
- Remove editable flag from git dependency (caused pipenv errors) - Keep as regular git dependency pointing to v0.5.2 - Update migration notes
- ckanext-sentry is not installed - Remove from plugin list to avoid PluginNotFoundException - Update migration notes
- Update model.py to pass bind parameter to table operations - Fixes UnboundExecutionError when checking if tables exist - Update migration notes
- Use inspector.has_table() instead of deprecated table.exists() - Properly handle engine binding for table operations
- ckanext-versions: Use inspector for table checks - ckanext-validation: Use inspector for table checks - ckanext-unaids: Use inspector for dataset_transfer table checks - All use None check for engine during startup - Update migration documentation
…n ckanext-pages and ckanext-harvest
- Remove --skip-lock flag from bootstrap.sh to ensure proper dependency resolution - Add async-timeout==4.0.3 (required by redis 5.0.7 on Python 3.10) - Add numpy>=1.21.0 (required by pandas>=1.4.2) - Update migration documentation with fixes
- Add --verbose flag to see detailed package installation progress - Add error checking to fail fast if pipenv install fails - Add success message after dependencies are installed - Pipfile.lock updated with numpy 2.2.6 and other dependency updates
- Update ckanext-unaids to use direct g.user/g.userobj assignment - Avoid calling identify_user() which causes infinite recursion - Update migration documentation with detailed explanation
- In CKAN 2.11.4, activity functionality moved to ckanext/activity extension - The activity plugin must be enabled for package_activity_list action to exist - ckanext-unaids chains to this action, causing NotFound error when missing - This also fixes the KeyError: 'model' issue which was caused by action wrapping failing during plugin initialization
- Update restricted_get_username_from_context to check is_authenticated - Handle Flask-Login's AnonymousUser which lacks as_dict() method - Update migration documentation
- Handle None return from User.by_email() instead of empty list - Fixes TypeError during OAuth user creation - Update migration documentation
- Create patch_saml2auth.py to fix session serialization issues - Convert SAML ava dict values to strings for JSON compatibility - Add patch execution to bootstrap.sh - Update migration documentation This fixes TypeError: Object of type NameID is not JSON serializable during SAML OAuth login in Flask 3.x
- Improve patch_saml2auth.py to handle both ava and session_info objects - Add dynamic venv path detection for Docker and local environments - Ensure all SAML session data is JSON serializable for Flask 3.x - Update Pipfile.lock platform markers The activity plugin was already correctly configured in CKAN 2.11.4. The plugin loading issue was resolved by allowing bootstrap process to complete.
- Add clarification about activity plugin entry point registration - Document bootstrap process completion requirement - Add SAML2 session serialization fixes to issues list - Document activity plugin verification steps
- Change ckanext-authz-service: datopian -> adx-tmp - Change ckanext-pages: ckan -> adx-tmp This allows us to maintain our Python 3.10/CKAN 2.11.4 migration patches without pushing to official upstream repositories.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Updates the repository to use Python 3.10 across all components (Pipfile, Docker, everywhere).
Changes
Pipfile
python_version:3.8→3.10ckan/Dockerfile
python:3.8→python:3.10python3-distutils(included in Python 3.10+)ca-certificatesfor SSL supportdocker-compose.yml
buildcontext forckanandsupervisorservices to enable local image buildsNotes
Pipfile.lock regeneration will occur during next CI/CD build with initialized submodules.
Verified: Python 3.10.19, pip 25.3, pipenv 2025.1.1 installed and functional in CKAN image.
Original prompt
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.