Skip to content

Commit

Permalink
Document datasets (#3060)
Browse files Browse the repository at this point in the history
  • Loading branch information
flying-sheep authored Jun 4, 2024
1 parent 8d046ff commit 4f40d68
Show file tree
Hide file tree
Showing 16 changed files with 417 additions and 180 deletions.
14 changes: 11 additions & 3 deletions .azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ trigger:

variables:
python.version: '3.12'
PYTEST_ADDOPTS: '-v --color=yes --nunit-xml=test-data/test-results.xml'
PYTEST_ADDOPTS: '-v --color=yes --internet-tests --nunit-xml=test-data/test-results.xml'
TEST_EXTRA: 'test-full'
DEPENDENCIES_VERSION: "latest" # |"pre-release" | "minimum-version"
TEST_TYPE: "standard" # | "coverage"
Expand Down Expand Up @@ -44,11 +44,19 @@ jobs:
inputs:
key: '"python $(python.version)" | "$(Agent.OS)" | pyproject.toml'
restoreKeys: |
python | "$(Agent.OS)"
python
"python" | "$(Agent.OS)"
"python"
path: $(uv_cache_dir)
displayName: Cache pip packages


- task: Cache@2
inputs:
key: '"pytest"'
restoreKeys: '"pytest"'
path: $(System.DefaultWorkingDirectory)/.pytest_cache/d
displayName: Cache pytest data

- script: |
export MPLBACKEND="agg"
echo $MPLBACKEND
Expand Down
30 changes: 30 additions & 0 deletions docs/extensions/patch_myst_nb.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
"""Extension to patch https://github.com/executablebooks/MyST-NB/pull/599."""

# TODO once MyST-NB 1.1.1/1.2.0 is out, this can be removed.

from __future__ import annotations

from copy import copy
from typing import TYPE_CHECKING

from myst_nb.core.render import MditRenderMixin

if TYPE_CHECKING:
from sphinx.application import Sphinx


get_orig = MditRenderMixin.get_cell_level_config


def get_cell_level_config(
self: MditRenderMixin,
field: str,
cell_metadata: dict[str, object],
line: int | None = None,
):
rv = get_orig(self, field, cell_metadata, line)
return copy(rv)


def setup(app: Sphinx):
MditRenderMixin.get_cell_level_config = get_cell_level_config
15 changes: 15 additions & 0 deletions docs/references.bib
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,21 @@ @article{Blondel2008
pages = {P10008},
}

@article{Burczynski2006,
author = {Burczynski, Michael E. and Peterson, Ron L. and Twine, Natalie C. and Zuberek, Krystyna A. and Brodeur, Brendan J. and Casciotti, Lori and Maganti, Vasu and Reddy, Padma S. and Strahs, Andrew and Immermann, Fred and Spinelli, Walter and Schwertschlag, Ulrich and Slager, Anna M. and Cotreau, Monette M. and Dorner, Andrew J.},
title = {Molecular Classification of Crohn’s Disease and Ulcerative Colitis Patients Using Transcriptional Profiles in Peripheral Blood Mononuclear Cells},
volume = {8},
issn = {1525-1578},
url = {https://doi.org/10.2353/jmoldx.2006.050079},
doi = {10.2353/jmoldx.2006.050079},
number = {1},
journal = {The Journal of Molecular Diagnostics},
publisher = {Elsevier BV},
year = {2006},
month = {feb},
pages = {51--61},
}

@article{Butler2018,
author = {Butler, Andrew and Hoffman, Paul and Smibert, Peter and Papalexi, Efthymia and Satija, Rahul},
title = {Integrating single-cell transcriptomic data across different conditions, technologies, and species},
Expand Down
1 change: 1 addition & 0 deletions docs/release-notes/1.10.2.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
* Fixed incorrect instructions in "testing" dev docs {pr}`2994` {smaller}`I Virshup`
* Update marsilea tutorial to use `group_` methods {pr}`3001` {smaller}`I Virshup`
* Fixed citations {pr}`3032` {smaller}`P Angerer`
* Improve dataset documentation {pr}`3060` {smaller}`P Angerer`

```{rubric} Bug fixes
```
Expand Down
7 changes: 7 additions & 0 deletions scanpy/_utils/_doctests.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,10 @@ def decorator(func: F) -> F:
return func

return decorator


def doctest_internet(func: F) -> F:
"""Mark function so doctest gets the internet mark."""

func._doctest_internet = True
return func
Loading

0 comments on commit 4f40d68

Please sign in to comment.