Skip to content

Commit 54d4e46

Browse files
Apply suggestions from code review
docstring improvements in datajoint.table. Co-authored-by: Raphael Guzman <[email protected]>
1 parent a56d634 commit 54d4e46

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

datajoint/table.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -230,11 +230,12 @@ def external(self):
230230
def update1(self, row):
231231
"""
232232
update1 updates one existing entry in the table.
233-
Caution: In DataJoint the primary modes for data manipulation is to insert and delete
233+
Caution: In DataJoint the primary modes for data manipulation is to ``insert`` and ``delete``
234234
entire records since referential integrity works on the level of records, not fields.
235235
Therefore, updates are reserved for corrective operations outside of main workflow.
236236
Use UPDATE methods sparingly with full awareness of potential violations of assumptions.
237-
:param row: a dict containing the primary key values and the attributes to update.
237+
238+
:param row: a ``dict`` containing the primary key values and the attributes to update.
238239
Setting an attribute value to None will reset it to the default value (if any)
239240
The primary key attributes must always be provided.
240241
Examples:
@@ -284,8 +285,7 @@ def insert(self, rows, replace=False, skip_duplicates=False, ignore_extra_fields
284285
:param skip_duplicates: If True, silently skip duplicate inserts.
285286
:param ignore_extra_fields: If False, fields that are not in the heading raise error.
286287
:param allow_direct_insert: applies only in auto-populated tables.
287-
If False (default), insert are allowed only from inside
288-
the make callback.
288+
If False (default), insert are allowed only from inside the make callback.
289289
Example::
290290
>>> relation.insert([
291291
>>> dict(subject_id=7, species="mouse", date_of_birth="2014-09-01"),
@@ -596,7 +596,7 @@ def describe(self, context=None, printout=True):
596596
def _update(self, attrname, value=None):
597597
"""
598598
This is a deprecated function to be removed in datajoint 0.14.
599-
Use .update1 instead.
599+
Use ``.update1`` instead.
600600
601601
Updates a field in one existing tuple. self must be restricted to exactly one entry.
602602
In DataJoint the principal way of updating data is to delete and re-insert the

0 commit comments

Comments
 (0)