Skip to content

Commit

Permalink
[Docs] Add hybrid plugin system notebook
Browse files Browse the repository at this point in the history
Part of OpenAssetIO/OpenAssetIO#1202. Add a Jupyter Notebook
illustrating the design and usage of the hybrid plugin system.

Signed-off-by: David Feltell <[email protected]>
  • Loading branch information
feltech committed Aug 30, 2024
1 parent 66a7839 commit f3f929f
Show file tree
Hide file tree
Showing 7 changed files with 535 additions and 5 deletions.
5 changes: 3 additions & 2 deletions .github/build_openassetio/action.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# SPDX-License-Identifier: Apache-2.0
# Copyright 2023 The Foundry Visionmongers Ltd
# Copyright 2023-2024 The Foundry Visionmongers Ltd

# Composite action for reuse within other workflows.
# Builds OpenAssetIO.
Expand All @@ -15,13 +15,14 @@ runs:
with:
repository: OpenAssetIO/OpenAssetIO
path: openassetio-checkout
ref: v1.0.0-rc.1.0

- name: Build OpenAssetIO
shell: bash
run: |
cd openassetio-checkout
mkdir build
cmake -G Ninja -S . -B build
cmake -G Ninja -S . -B build -DOPENASSETIO_ENABLE_SIMPLECPPMANAGER=ON
cmake --build build
cmake --install build
- uses: actions/upload-artifact@v3
Expand Down
39 changes: 38 additions & 1 deletion .github/workflows/examples.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ jobs:
matrix:
os: ["windows-2022", "ubuntu-22.04", "macos-13"]
python: ["3.10", "3.11"]
defaults:
run:
shell: bash
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
Expand All @@ -28,4 +31,38 @@ jobs:
python -m pip install .
python -m pip install -r examples/resources/requirements.txt
- name: Test Notebooks
run: jupyter nbconvert --to html --execute examples/*.ipynb
# Execute all the notebooks apart from the Hybrid Plugin System,
# which requires a build of SimpleCppManager
run: >
find examples -maxdepth 1 -name "*.ipynb"
! -name "hybrid_plugin_system.ipynb"
-exec jupyter nbconvert --to html --execute {} \;
test-cpp-notebooks:
# A special job just for the Hybrid Plugin System because it needs a
# build of SimpleCppManager. Use the OpenAssetIO Docker container to
# get a build. If/when OpenAssetIO publishes SimpleCppManager with
# its release artifacts, this could be simplified.
name: Test Hybrid Plugin System notebook
runs-on: ubuntu-latest
container:
image: ghcr.io/openassetio/openassetio-build
steps:
- uses: actions/checkout@v3
- name: Install Dependencies
run: |
python -m pip install .
python -m pip install -r examples/resources/requirements.txt
- name: Build SimpleCppManager
uses: ./.github/build_openassetio

- name: Copy SimpleCppManager to expected location for notebook
run: >
cp openassetio-checkout/build/dist/SimpleCppManager.so
examples/resources/hybrid_plugin_system/SimpleCppManager/
- name: Test notebook
run: jupyter nbconvert --to html --execute examples/hybrid_plugin_system.ipynb


Loading

0 comments on commit f3f929f

Please sign in to comment.