Releases: Chilipp/docrep
v0.3.2: Switch to Apache-2.0 license
v0.3.1: Small patch for DeprecationWarning
Small patch for DeprecationWarning
v0.3.0: Unify methods and simplify the API
This release deprecates multiple methods of the DocstringProcessor API and unifies the method naming. More details can be found in the corresponding PR: #19
The deprecated methods will be removed in version 0.4.
Changed
-
The following methods of the
DocstringProcessor
class have been deprecated:docstring update methods for strings:
dedents
in favor ofDocstringProcessor.dedent
with_indents
in favor ofDocstringProcessor.with_indent
docstring analysis decorators
get_sectionsf
in favor ofDocstringProcessor.get_sections
get_summaryf
in favor ofDocstringProcessor.get_summary
get_full_descriptionf
in favor ofDocstringProcessor.get_full_description
get_extended_summaryf
in favor ofDocstringProcessor.get_extended_summary
save_docstring
in favor ofDocstringProcessorget_docstring
docstring parameter and type extractors for strings
delete_params_s
in favor ofdocrep.delete_params
delete_types_s
in favor ofdocrep.delete_types
delete_kwargs_s
in favor ofdocrep.delete_kwargs
keep_params_s
in favor ofdocrep.keep_params
keep_types_s
in favor ofdocrep.keep_types
Migrating from 0.2.8 to 0.3.0
Migration is possible using the following steps:
- For the deprecated update methods,
just use the above-mentioned replacement. They work for both, as
decorators and with strings. - For the analysis decorators (
get_sectionsf
for instance, use the
replacement) but you need to explicitly state the [base]{.title-ref}
parameter.@get_sectionsf('something')
for instance needs to be
replaced with@get_sections(base='something')
- for the parameter and type extractor functions, just use the
corresponding module level function mentioned
above
v0.2.7: Fixed deprecation warning for regular expression
Fixed deprecation warning for regular expression
v0.2.6: deprecate docrep.dedents
This patch uses inspect.cleandoc
now instead of matplotlib.cbook.dedent
and deprecates docrep.dedents
v0.2.5: Fixed DeprecationWarning
Minor release to fix a DeprecationWarning (see #12)
v0.2.4: Improved docs and python 3.7
This new minor release has an improved documentation considering the
keep_params
and keep_types
section and triggers new builds for python
3.7.
v0.2.3: New decorators handling for classes in python 2.7
This minor release contains some backward incompatible changes on how to handle the decorators for classes in python 2.7. Thanks @lesteve and @guillaumeeb for your input on this.
Changed
-
When using the decorators for classes in python 2.7, e.g. via:
>>> @docstrings ... class Something(object): ... "%(replacement)s"
it does not have an effect anymore. This is because class docstrings cannot be modified in python 2.7 (see issue #5). The original behaviour was to raise an error. You can restore the old behaviour by setting DocstringProcessor.python2_classes = 'raise'.
-
Some docs have been updated (see PR #7)
Added
- the DocstringProcessor.python2_classes to change the handling of classes in python 2.7
v0.2.2: New methods for extracting the docstring summary
Added
- We introduce the
DocstringProcessor.get_extended_summary
and
DocstringProcessor.get_extended_summaryf
methods to extract the
extended summary (see the numpy documentation guidelines). - We introduce the
DocstringProcessor.get_full_description
and
DocstringProcessor.get_full_descriptionf
methods to extract the
full description (i.e. the summary plus extended summary) from a function
docstring