Skip to content

Commit b644d7e

Browse files
authored
indent code block
1 parent ceaf1c1 commit b644d7e

File tree

1 file changed

+19
-19
lines changed

1 file changed

+19
-19
lines changed

docs/source/extending/contents.rst

+19-19
Original file line numberDiff line numberDiff line change
@@ -225,25 +225,25 @@ return for a more complete implementation.
225225

226226
.. code-block:: python
227227
228-
class NoOpCheckpoints(GenericCheckpointsMixin, Checkpoints):
229-
"""requires the following methods:"""
230-
def create_file_checkpoint(self, content, format, path):
231-
""" -> checkpoint model"""
232-
def create_notebook_checkpoint(self, nb, path):
233-
""" -> checkpoint model"""
234-
def get_file_checkpoint(self, checkpoint_id, path):
235-
""" -> {'type': 'file', 'content': <str>, 'format': {'text', 'base64'}}"""
236-
def get_notebook_checkpoint(self, checkpoint_id, path):
237-
""" -> {'type': 'notebook', 'content': <output of nbformat.read>}"""
238-
def delete_checkpoint(self, checkpoint_id, path):
239-
"""deletes a checkpoint for a file"""
240-
def list_checkpoints(self, path):
241-
"""returns a list of checkpoint models for a given file,
242-
default just does one per file
243-
"""
244-
return []
245-
def rename_checkpoint(self, checkpoint_id, old_path, new_path):
246-
"""renames checkpoint from old path to new path"""
228+
class NoOpCheckpoints(GenericCheckpointsMixin, Checkpoints):
229+
"""requires the following methods:"""
230+
def create_file_checkpoint(self, content, format, path):
231+
""" -> checkpoint model"""
232+
def create_notebook_checkpoint(self, nb, path):
233+
""" -> checkpoint model"""
234+
def get_file_checkpoint(self, checkpoint_id, path):
235+
""" -> {'type': 'file', 'content': <str>, 'format': {'text', 'base64'}}"""
236+
def get_notebook_checkpoint(self, checkpoint_id, path):
237+
""" -> {'type': 'notebook', 'content': <output of nbformat.read>}"""
238+
def delete_checkpoint(self, checkpoint_id, path):
239+
"""deletes a checkpoint for a file"""
240+
def list_checkpoints(self, path):
241+
"""returns a list of checkpoint models for a given file,
242+
default just does one per file
243+
"""
244+
return []
245+
def rename_checkpoint(self, checkpoint_id, old_path, new_path):
246+
"""renames checkpoint from old path to new path"""
247247
248248
See ``GenericFileCheckpoints`` in :mod:`notebook.services.contents.filecheckpoints`
249249
for a more complete example.

0 commit comments

Comments
 (0)