Skip to content

Conversation

@jspada200
Copy link
Collaborator

@jspada200 jspada200 commented Jan 9, 2026

Building out a shotgrid providor and the abstractions needed. A providor for SG was added and pydantic models for different entitiy types. You can test the API by connecting the the AWSF site Sam setup by copying sg_example.docker-compose.local.yml, renaming to docker-compose.local.yml and updating the variables. Once you update you can run make build and make start-local. Once up, you can test out the API with http://0.0.0.0:8000/docs

- Introduced `use-radix.mdc` and `workplace.mdc` to enforce frontend framework usage and directory structure.
- Added `.env.example` for environment variable setup in prompt testing.
- Created `prompt_evaluation.ipynb` for evaluating LLM responses and integrating with the transcription dataset

---------

Signed-off-by: James Spadafora <[email protected]>
- Created a new `requirements.txt` file for the prompt testing environment.
- Included dependencies: `openai`, `python-dotenv`, `ipykernel`, and `litellm` with specified minimum versions.

---------

Signed-off-by: James Spadafora <[email protected]>
---------

Signed-off-by: James Spadafora <[email protected]>
---------

Signed-off-by: James Spadafora <[email protected]>
---------

Signed-off-by: James Spadafora <[email protected]>
---------

Signed-off-by: James Spadafora <[email protected]>
---------

Signed-off-by: James Spadafora <[email protected]>
This commit introduces a GitHub Actions workflow for automatic code formatting and type checking in the frontend. It includes the setup for Prettier and TypeScript checks, ensuring code quality on pushes and pull requests. Additionally, configuration files for Prettier and updates to package.json files are included to support these features. The README is also updated to provide instructions for local formatting and type checking.

---------

Signed-off-by: James Spadafora <[email protected]>
This commit modifies the backend and frontend code formatting workflows to remove references to the 'master' branch, ensuring compatibility with the current branching strategy that only includes 'main' and 'develop'.

---------

Signed-off-by: James Spadafora <[email protected]>
…nd black configuration

This commit modifies the GitHub Actions workflow to check code formatting and import sorting in the backend by adjusting the paths to 'src/' and 'tests/'. Additionally, it introduces a new 'pyproject.toml' file to configure isort and black, ensuring consistent code style across the project.

---------

Signed-off-by: James Spadafora <[email protected]>
This commit updates the backend formatting workflow by refining the paths for code formatting and import sorting checks. It ensures that the workflow aligns with the latest project structure and maintains consistent code quality standards.

---------

Signed-off-by: James Spadafora <[email protected]>
This commit introduces several updates to the backend configuration, including the addition of a local Docker Compose file for environment-specific settings and the integration of ShotGrid as a production tracking provider. Key changes include:

- Updated `.gitignore` to include local environment files.
- Modified `docker-compose.yml` to support local configurations and added necessary environment variables for ShotGrid.
- Refactored the `makefile` to utilize the new local Docker Compose file.
- Adjusted `pyproject.toml` and `pytest.ini` for improved project structure and coverage reporting.
- Added new models and provider classes for ShotGrid, including entity handling and linked entity support.
- Implemented comprehensive tests for the ShotGrid provider to ensure functionality and error handling.

These changes aim to streamline the development process and enhance the integration with ShotGrid for production tracking.

---------

Signed-off-by: James Spadafora <[email protected]>
…ructure

This commit introduces several new rules for the development process, including:

- `always-update-tests`: Ensures tests are always run when code changes are made.
- `apply-comments-only-when-needed`: Restricts comments to necessary explanations only.
- `run-formatting`: Enforces code formatting after changes in the backend.

Additionally, the backend structure is improved with updates to the Docker configuration, including changes to the `docker-compose.yml` and `Dockerfile` to better manage source paths and environment variables. The FastAPI application is enhanced with detailed API metadata and organized endpoint tags for better documentation.

These changes aim to streamline development practices and improve code quality.

---------

Signed-off-by: James Spadafora <[email protected]>
This commit introduces significant updates to the backend, including:

- Added `PRODTRACK_PROVIDER` environment variable to `docker-compose.yml` for ShotGrid integration.
- Enhanced the `EntityBase` model with new fields for `project` and `note_links`.
- Implemented the `add_entity` method in the `ShotgridProvider` to facilitate entity creation in ShotGrid.
- Refactored entity conversion methods to streamline data handling between ShotGrid and DNA models.
- Introduced comprehensive tests for entity creation in ShotGrid, covering both unit and integration scenarios.

These changes aim to improve the integration with ShotGrid and enhance the overall functionality of the entity management system.

---------

Signed-off-by: James Spadafora <[email protected]>
This commit introduces a new endpoint for creating notes in the FastAPI application, along with enhancements to the entity models. Key changes include:

- Added `CreateNoteRequest` model to handle note creation requests.
- Implemented the `create_note` function to process incoming requests and create note entities.
- Updated `EntityBase` and related models to include a `project` field for better project association.
- Enhanced the ShotGrid provider to support project information in entity mappings.
- Added comprehensive tests for the new note creation endpoint, ensuring proper functionality and error handling.

These changes aim to improve the note management capabilities within the production tracking system.

---------

signed-off-by: James Spadafora <[email protected]>
This commit introduces several improvements to the entity model and ShotGrid provider:

- Added a `type` computed property to the `EntityBase` model, returning the entity's class name.
- Updated the `ShotgridProvider` to preserve linked entities during the creation process, ensuring that linked fields are restored in the created entity.
- Enhanced tests for note creation to verify the integrity of linked entities.

These changes aim to improve the handling of entity types and linked relationships within the production tracking system.

signed-off-by: James Spadafora <[email protected]>
This commit introduces a comprehensive suite of tests for the ProdtrackProviderBase and ShotgridProvider classes, enhancing the test coverage for entity handling. Key changes include:

- Added tests for the ProdtrackProviderBase class, verifying the correct entity model retrieval and ensuring that NotImplementedError is raised for unimplemented methods.
- Implemented edge case tests for the ShotgridProvider, including error handling for unknown entity types and validation of entity conversion methods.
- Enhanced the test suite for the ShotgridProvider to ensure proper functionality when dealing with linked entities and various input scenarios.

These changes aim to improve the reliability and robustness of the production tracking system's provider classes.

Signed-off-by: James Spadafora <[email protected]>
Signed-off-by: James Spadafora <[email protected]>
@jspada200 jspada200 self-assigned this Jan 9, 2026
@jspada200 jspada200 added the enhancement New feature or request label Jan 9, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR introduces a backend abstraction layer for ShotGrid integration, enabling the DNA application to interact with production tracking systems through a provider pattern. The implementation includes Pydantic models for various entity types (Shot, Asset, Version, Note, Playlist, Task) and a ShotGrid provider with comprehensive field mapping.

Changes:

  • Added ShotGrid provider implementation with entity CRUD operations and field mapping
  • Created Pydantic models for production tracking entities with validation and serialization
  • Implemented FastAPI endpoints for entity retrieval and note creation with dependency injection

Reviewed changes

Copilot reviewed 20 out of 21 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
backend/src/dna/prodtrack_providers/shotgrid.py Core ShotGrid provider with entity conversion and field mapping
backend/src/dna/models/entity.py Pydantic entity models with validators and serialization
backend/src/main.py FastAPI application with entity endpoints and ShotGrid integration
backend/tests/providors/test_shotgrid_providor.py Comprehensive unit tests for ShotGrid provider functionality
backend/tests/providors/test_entity_creation.py Unit and integration tests for entity creation
backend/tests/test_main.py API endpoint tests with mocked provider
backend/requirements.txt Added shotgun_api3 dependency
backend/Dockerfile Updated PYTHONPATH for module imports
backend/docker-compose.yml Added ShotGrid environment variables
backend/pytest.ini Updated pythonpath and coverage configuration
backend/pyproject.toml Updated import paths for isort

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

jspada200 and others added 4 commits January 9, 2026 15:53
Co-authored-by: Copilot <[email protected]>
Signed-off-by: James Spadafora <[email protected]>
Co-authored-by: Copilot <[email protected]>
Signed-off-by: James Spadafora <[email protected]>
This commit deletes the test files `test_entity_creation.py` and `test_shotgrid_providor.py`, which are no longer needed. The removal of these files helps streamline the test suite and eliminate redundancy, as their functionality has been covered in other tests.

Signed-off-by: James Spadafora <[email protected]>
This commit introduces a new GitHub Actions workflow file `backend-tests.yml` to automate testing for the backend. The workflow triggers on pushes and pull requests to the `main` and `develop` branches, specifically for changes in the `backend` directory. It sets up a Python environment, installs dependencies, and runs tests with coverage, ensuring code quality and reliability.

Additionally, a minor whitespace adjustment was made in `backend/src/main.py` for improved code formatting.

Signed-off-by: James Spadafora <[email protected]>
This commit updates the GitHub Actions workflow for backend tests by adding environment variables necessary for connecting to the ShotGrid API. The new variables include `SHOTGRID_URL`, `SHOTGRID_SCRIPT_NAME`, and `SHOTGRID_API_KEY`, which are essential for the test environment setup.

These changes aim to ensure that the backend tests can properly interact with the ShotGrid service during execution.

Signed-off-by: James Spadafora <[email protected]>
This commit updates the test suite for the note creation endpoint by introducing a mock provider to simulate the ShotGrid API. The test for handling missing project fields now utilizes dependency overrides for better isolation and reliability. Additionally, the integration test for creating notes linked to versions has been refactored to use the mocked provider, ensuring that the tests do not rely on real ShotGrid connections.

These changes enhance the robustness of the test suite and improve the clarity of the test cases.

Signed-off-by: James Spadafora <[email protected]>
This commit enhances the backend README by adding a section on configuring ShotGrid credentials. It provides step-by-step instructions for creating a local docker-compose override file, updating environment variables with ShotGrid credentials, and notes that the configuration file is gitignored to protect sensitive information. These additions aim to improve the setup process for developers integrating with ShotGrid.

Signed-off-by: James Spadafora <[email protected]>
@jspada200 jspada200 merged commit 3bb76ac into AcademySoftwareFoundation:main Jan 13, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant