Darglint2

Latest version: v1.8.2

Safety actively analyzes 685670 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 4 of 10

1.2.3

Changed

- Made ordering of error messages more strict. Error messages
are grouped by function, then sorted alphabetically, then
sorted in place by their line numbers within the function
groups.

Fixed

- Handle the else branch of try-except statements when searching
for raise statements during analysis.
- Handle empty type in Google-style arguments (previously raised
an exception, now it's a darglint error with a description.)
- Handle exceptions raised by the Python module, ast.
- Handle a bare raise statement within an exception handler.
For example, if you have

try:
raise SyntaxError('Wrong!')
except SyntaxError:
raise

Then you know that you really have to document a syntax
error.

1.2.2

Fixed

- Certain versions of Python failed with in analysis,
complaining of a missing 'id' attribute.

1.2.1

Added

- Merged in a configuration file for the pre-commit project.
Thanks to mikaelKvalvaer for the PR and nioncode for
pointing out the advantages of this configuration.

Changed

- Made error analysis more robust. Previously, errors were
compared simply by looking a the name in the `raises` statement.
Now analysis builds contexts around try-except blocks, and
accounts for the catch-and-throw pattern. Anything unusual
will still raise an error, but it's more robust than previously.

Fixed

- Fixed the handling of breaks in item descriptions. Thanks to
lvermue for the pull request and submitting the bug.

1.2.0

Added

- Added initial implementation for the numpy docstring format to
darglint. Support for this docstring format is not yet stable,
and may have performance problems specific to the format.

1.1.3

Fixed

- Add error number to exceptions raised when using the flake8
runner. This allows flake8 to report the error without
incorrectly unpacking the string.
- Fix sphinx return type annotation. Previously, there was an
inline return type which was accepted, in the format
`:return x: Explanation.` where `x` is the type returned.
However, this should really only be handled by the `:rtype:`
section. This incorrect return type was labelled using the
same node name as the normal return type, leading to an
assertion being raised. The inline return type was removed.

1.1.2

Changed

- Allow for two-space indentation.
- Make the asterisk(s) in star arguments optional.

Page 4 of 10

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.