Skip to content

Commit b70e87d

Browse files
committed
Work around sphinx cross-ref bug.
The error is: ``` stdpopsim/species.py:docstring of stdpopsim.Species::more than one target found for cross-reference 'id': stdpopsim.engines._MsprimeEngine.id, stdpopsim.slim_engine._SLiMEngine.id ``` See currently open sphinx issue for workaround. sphinx-doc/sphinx#2549
1 parent 7f7921a commit b70e87d

File tree

3 files changed

+14
-14
lines changed

3 files changed

+14
-14
lines changed

stdpopsim/engines.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -47,10 +47,10 @@ class Engine(object):
4747
be set, and the :func:`simulate()` and :func:`get_version()` methods must
4848
be implemented. See msprime example in ``engines.py``.
4949
50-
:ivar id: The unique identifier for the simulation engine.
51-
:vartype id: str
52-
:ivar description: A short description of this engine.
53-
:vartype description: str
50+
:ivar ~.id: The unique identifier for the simulation engine.
51+
:vartype ~.id: str
52+
:ivar ~.description: A short description of this engine.
53+
:vartype ~.description: str
5454
:ivar citations: A list of citations for the simulation engine.
5555
:vartype citations: list of :class:`.Citation`
5656
"""

stdpopsim/models.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -114,10 +114,10 @@ class Population(object):
114114
"""
115115
Class recording metadata representing a population in a simulation.
116116
117-
:ivar id: The id of the population.
118-
:vartype id: str
119-
:ivar description: a short description of the population
120-
:vartype description: str
117+
:ivar ~.id: The id of the population.
118+
:vartype ~.id: str
119+
:ivar ~.description: a short description of the population
120+
:vartype ~.description: str
121121
:ivar sampling_time: an integer value which indicates how many
122122
generations prior to the present individuals should samples should
123123
be drawn from this population. If `None`, sampling not allowed from this
@@ -149,13 +149,13 @@ class DemographicModel(object):
149149
This class is indended to be used by model implementors. To instead
150150
obtain a pre-specified model, see :class:`Species.get_demographic_model`.
151151
152-
:ivar id: The unique identifier for this model. DemographicModel IDs should be
152+
:ivar ~.id: The unique identifier for this model. DemographicModel IDs should be
153153
short and memorable, perhaps as an abbreviation of the model's name.
154-
:vartype id: str
155-
:ivar description: A short description of this model as it would be used in
154+
:vartype ~.id: str
155+
:ivar ~.description: A short description of this model as it would be used in
156156
written text, e.g., "Three population Out-of-Africa". This should
157157
describe the model itself and not contain author or year information.
158-
:vartype description: str
158+
:vartype ~.description: str
159159
:ivar long_description: A concise, but detailed, summary of the model.
160160
:vartype long_description: str
161161
:ivar generation_time: Mean inter-generation interval, in years.

stdpopsim/species.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,14 +61,14 @@ class Species(object):
6161
"""
6262
Class representing a species in the catalog.
6363
64-
:ivar id: The unique identifier for this species. The species ID is
64+
:ivar ~.id: The unique identifier for this species. The species ID is
6565
the three first letters of the genus name followed by the first
6666
three letters of the species name, and does not
6767
contain any spaces or punctuation. The usual scheme is to
6868
use the first three letters of the genus and species (similar to the
6969
approach used in the UCSC genome browser), e.g., "HomSap"
7070
is the ID for Homo Sapiens.
71-
:vartype id: str
71+
:vartype ~.id: str
7272
:ivar name: The full name of this species in binominal nomenclature as
7373
it would be used in written text, e.g., "Homo sapiens".
7474
:vartype name: str

0 commit comments

Comments
 (0)