Skip to content

Commit

Permalink
auto commit docs (#30)
Browse files Browse the repository at this point in the history
  • Loading branch information
cpelley authored Jun 7, 2024
1 parent b2ba8ec commit 5a9e026
Show file tree
Hide file tree
Showing 8 changed files with 104 additions and 76 deletions.
31 changes: 30 additions & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,49 @@ on: [pull_request]

jobs:
test:
if: "!contains(github.event.head_commit.message, '[skip ci]')"
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4
with:
ref: ${{ github.head_ref }} # Ensure branch is checked out, not detached state (so we can push a commit later)
token: ${{ secrets.GITHUB_TOKEN }}

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: 3.9
cache: 'pip'

- name: Add checkout directory to PYTHONPATH
run: echo "PYTHONPATH=$(pwd):$PYTHONPATH" >> $GITHUB_ENV

- name: Install dependencies
run: pip install .[tests]
run: |
pip install .[tests,docs]
pip uninstall dagrunner -y
- name: Run pytest
run: pytest

- name: Build documentation
run: |
./docs/gen_docs dagrunner ./docs
- name: Check if documentation has changed
id: check-docs
run: |
git diff --quiet --exit-code || echo "::set-output name=changed::true"
# https://github.com/orgs/community/discussions/26560#discussioncomment-3531273
- name: Commit and push documentation changes
if: steps.check-docs.outputs.changed == 'true'
run: |
git config user.name github-actions[bot]
git config user.email 41898282+github-actions[bot]@users.noreply.github.com
git commit -am "Automated reference documentation update for PR ${{ github.event.number }} [skip ci]"
git push
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
18 changes: 8 additions & 10 deletions docs/dagrunner.execute_graph.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@

see [class: dagrunner.plugin_framework.NodeAwarePlugin](dagrunner.plugin_framework.md#class-nodeawareplugin)

see [class: dagrunner.utils.ObjectAsStr](dagrunner.utils.md#class-objectasstr)

see [class: dagrunner.utils.TimeIt](dagrunner.utils.md#class-timeit)

see [function: dagrunner.utils.function_to_argparse](dagrunner.utils.md#function-function_to_argparse)
Expand All @@ -16,7 +14,7 @@ see [function: dagrunner.utils.visualisation.visualise_graph](dagrunner.utils.vi

## class: `ExecuteGraph`

[Source](../dagrunner/execute_graph.py#L159)
[Source](../dagrunner/execute_graph.py#L170)

### Call Signature:

Expand All @@ -26,7 +24,7 @@ ExecuteGraph(networkx_graph: str, <function plugin_executor>, scheduler: str = '

### function: `__call__`

[Source](../dagrunner/execute_graph.py#L246)
[Source](../dagrunner/execute_graph.py#L262)

#### Call Signature:

Expand All @@ -38,7 +36,7 @@ Call self as a function.

### function: `__init__`

[Source](../dagrunner/execute_graph.py#L160)
[Source](../dagrunner/execute_graph.py#L171)

#### Call Signature:

Expand All @@ -50,7 +48,7 @@ Execute a networkx graph using a chosen scheduler.

Args:
- `networkx_graph` (networkx.DiGraph, callable or str):
A networkx graph; dot path to a networkx graph or callable that returns
A networkx graph; dot path to a networkx graph or callable that returns
one; tuple representing (edges, nodes) or callable object that
returns a networkx.
- `plugin_executor` (callable):
Expand Down Expand Up @@ -78,7 +76,7 @@ Args:

### function: `visualise`

[Source](../dagrunner/execute_graph.py#L243)
[Source](../dagrunner/execute_graph.py#L259)

#### Call Signature:

Expand All @@ -90,7 +88,7 @@ visualise(self, output_filepath: str)

## class: `SkipBranch`

[Source](../dagrunner/execute_graph.py#L33)
[Source](../dagrunner/execute_graph.py#L26)

This exception is used to skip a branch of the execution graph.

Expand All @@ -101,7 +99,7 @@ subsequent tasks.

## function: `main`

[Source](../dagrunner/execute_graph.py#L257)
[Source](../dagrunner/execute_graph.py#L275)

### Call Signature:

Expand All @@ -114,7 +112,7 @@ Parses command line arguments and executes the graph using the ExecuteGraph clas

## function: `plugin_executor`

[Source](../dagrunner/execute_graph.py#L46)
[Source](../dagrunner/execute_graph.py#L40)

### Call Signature:

Expand Down
7 changes: 4 additions & 3 deletions docs/dagrunner.plugin_framework.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ Abstract base class to define our plugin UI
#### Call Signature:

```python
__call__(self, *args, timeout=120, polling=1, file_count=None)
__call__(self, *args, timeout=120, polling=1, file_count=None, verbose=False)
```

Poll for availability of files
Expand All @@ -38,6 +38,7 @@ Args:
number of arguments. Each argument is expected to return a minimum of
1 match each in either case.


Returns:
- None

Expand All @@ -46,7 +47,7 @@ Raises:

## class: `Input`

[Source](../dagrunner/plugin_framework.py#L107)
[Source](../dagrunner/plugin_framework.py#L116)

### Call Signature:

Expand All @@ -60,7 +61,7 @@ that are 'node aware'.

### function: `__call__`

[Source](../dagrunner/plugin_framework.py#L108)
[Source](../dagrunner/plugin_framework.py#L117)

#### Call Signature:

Expand Down
6 changes: 3 additions & 3 deletions docs/dagrunner.runner.schedulers.asyncmp.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ itself.

### function: `__enter__`

[Source](../dagrunner/runner/schedulers/asyncmp.py#L135)
[Source](../dagrunner/runner/schedulers/asyncmp.py#L137)

#### Call Signature:

Expand All @@ -32,7 +32,7 @@ Initiate the pool of workers.

### function: `__exit__`

[Source](../dagrunner/runner/schedulers/asyncmp.py#L140)
[Source](../dagrunner/runner/schedulers/asyncmp.py#L142)

#### Call Signature:

Expand Down Expand Up @@ -72,7 +72,7 @@ Keyword Args:

### function: `run`

[Source](../dagrunner/runner/schedulers/asyncmp.py#L49)
[Source](../dagrunner/runner/schedulers/asyncmp.py#L51)

#### Call Signature:

Expand Down
34 changes: 17 additions & 17 deletions docs/dagrunner.runner.schedulers.dask.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ See the following useful background reading:

## class: `DaskOnRay`

[Source](../dagrunner/runner/schedulers/dask.py#L186)
[Source](../dagrunner/runner/schedulers/dask.py#L200)

### Call Signature:

Expand All @@ -27,7 +27,7 @@ A class to run dask graphs using the 'dak-on-ray' scheduler.

### function: `__enter__`

[Source](../dagrunner/runner/schedulers/dask.py#L193)
[Source](../dagrunner/runner/schedulers/dask.py#L208)

#### Call Signature:

Expand All @@ -37,7 +37,7 @@ __enter__(self)

### function: `__exit__`

[Source](../dagrunner/runner/schedulers/dask.py#L196)
[Source](../dagrunner/runner/schedulers/dask.py#L211)

#### Call Signature:

Expand All @@ -47,7 +47,7 @@ __exit__(self, exc_type, exc_value, exc_traceback)

### function: `__init__`

[Source](../dagrunner/runner/schedulers/dask.py#L188)
[Source](../dagrunner/runner/schedulers/dask.py#L203)

#### Call Signature:

Expand All @@ -59,7 +59,7 @@ Initialize self. See help(type(self)) for accurate signature.

### function: `run`

[Source](../dagrunner/runner/schedulers/dask.py#L200)
[Source](../dagrunner/runner/schedulers/dask.py#L216)

#### Call Signature:

Expand All @@ -80,7 +80,7 @@ Returns:

## class: `Distributed`

[Source](../dagrunner/runner/schedulers/dask.py#L79)
[Source](../dagrunner/runner/schedulers/dask.py#L80)

### Call Signature:

Expand All @@ -92,7 +92,7 @@ A class to run dask graphs on a distributed cluster.

### function: `__enter__`

[Source](../dagrunner/runner/schedulers/dask.py#L87)
[Source](../dagrunner/runner/schedulers/dask.py#L89)

#### Call Signature:

Expand All @@ -104,7 +104,7 @@ Create a local cluster and connect a client to it.

### function: `__exit__`

[Source](../dagrunner/runner/schedulers/dask.py#L95)
[Source](../dagrunner/runner/schedulers/dask.py#L100)

#### Call Signature:

Expand All @@ -114,7 +114,7 @@ __exit__(self)

### function: `__init__`

[Source](../dagrunner/runner/schedulers/dask.py#L81)
[Source](../dagrunner/runner/schedulers/dask.py#L83)

#### Call Signature:

Expand All @@ -126,7 +126,7 @@ Initialize self. See help(type(self)) for accurate signature.

### function: `run`

[Source](../dagrunner/runner/schedulers/dask.py#L99)
[Source](../dagrunner/runner/schedulers/dask.py#L104)

#### Call Signature:

Expand All @@ -147,7 +147,7 @@ Returns:

## class: `SingleMachine`

[Source](../dagrunner/runner/schedulers/dask.py#L124)
[Source](../dagrunner/runner/schedulers/dask.py#L129)

### Call Signature:

Expand All @@ -159,7 +159,7 @@ A class to run dask graphs on a single machine.

### function: `__enter__`

[Source](../dagrunner/runner/schedulers/dask.py#L133)
[Source](../dagrunner/runner/schedulers/dask.py#L141)

#### Call Signature:

Expand All @@ -169,7 +169,7 @@ __enter__(self)

### function: `__exit__`

[Source](../dagrunner/runner/schedulers/dask.py#L182)
[Source](../dagrunner/runner/schedulers/dask.py#L196)

#### Call Signature:

Expand All @@ -179,7 +179,7 @@ __exit__(self, exc_type, exc_value, exc_traceback)

### function: `__init__`

[Source](../dagrunner/runner/schedulers/dask.py#L126)
[Source](../dagrunner/runner/schedulers/dask.py#L132)

#### Call Signature:

Expand All @@ -191,7 +191,7 @@ Initialize self. See help(type(self)) for accurate signature.

### function: `run`

[Source](../dagrunner/runner/schedulers/dask.py#L136)
[Source](../dagrunner/runner/schedulers/dask.py#L144)

#### Call Signature:

Expand All @@ -212,7 +212,7 @@ Returns:

## function: `add_dummy_tasks`

[Source](../dagrunner/runner/schedulers/dask.py#L33)
[Source](../dagrunner/runner/schedulers/dask.py#L34)

### Call Signature:

Expand Down Expand Up @@ -242,7 +242,7 @@ TODO:

## function: `no_op`

[Source](../dagrunner/runner/schedulers/dask.py#L25)
[Source](../dagrunner/runner/schedulers/dask.py#L26)

### Call Signature:

Expand Down
Loading

0 comments on commit 5a9e026

Please sign in to comment.