Add Origin Review, Propagation, Deployment & Guide #1956
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.
Implement Origin Curation Feature (#1932)
Overview
Adds comprehensive origin review, curation, propagation, and deployment capabilities to ScanCode.io, enabling manual review of automated origin determinations and publishing curated results to FederatedCode.
Key Features
OriginCurationmodelChanges
Models & Database
scanpipe/models.py- AddedOriginCurationandPropagationBatchmodels, extendedCodebaseRelationwith curation fieldsscanpipe/migrations/0077_add_origin_curation.py- Migration for new models and fieldsAPI
scanpipe/api/views.py- Addedrelations,relation_detail,relations_bulk_curateendpointsscanpipe/api/serializers.py- Added curation serializers with history trackingUI & Views
scanpipe/views.py- AddedOriginReviewView,OriginCurateView,OriginCurateCreateView,OriginPropagateView,OriginDeployView,OriginBulkCurationViewscanpipe/forms.py- Added curation forms (OriginCurationForm,BulkCurationForm,OriginPropagationForm,OriginDeployForm)scanpipe/filters.py- Added curation filtersscanpipe/urls.py- Added origin curation routesTemplates
scanpipe/templates/scanpipe/origin_*.html- Review, curate, propagate, deploy pagesscanpipe/templates/scanpipe/tabset/tab_curation*.html- Curation detail tabsscanpipe/templates/scanpipe/modals/origin_bulk_curation_modal.html- Bulk actions modalproject_detail.htmlandrelation_list.htmlwith origin review linksPipes & Logic
scanpipe/pipes/origin_propagation.py- Propagation strategies implementationscanpipe/pipes/federatedcode.py- Export and merge functions for origin curationsscanpipe/pipelines/publish_to_federatedcode.py- Integration with deployment pipelineDocumentation
docs/api/origin-curation-api.rst- REST API referencedocs/origin-curation-guide.rst- User guidedocs/tutorial_origin_curation_workflow.rst- Step-by-step tutorialdocs/developer/origin-curation-architecture.rst- Architecture documentationdocs/index.rst- Added documentation linksTests
scanpipe/tests/test_api.py- API endpoint testsscanpipe/tests/test_views.py- View testsscanpipe/tests/test_models.py- Model testsscanpipe/tests/test_pipelines.py- Pipeline testsscanpipe/tests/pipes/test_*.py- Pipe testsApproach
The implementation follows a layered architecture: data models with audit trails, UI forms/views for user interaction, REST API for automation, and background pipes for propagation/deployment. All curation actions create
OriginCurationhistory records for full traceability.