Arguably

Latest version: v1.3.0

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

Scan your dependencies

Page 2 of 2

1.2.0

1.1.0

Files can now be run without any integration with `arguably`. Simply call it like this: `python3 -m arguably file_to_run.py`. You'll get a help message with all callable functions. This includes `staticmethod`s and `classmethod`s for classes in the file. As an example:

python
test_script.py
def test(name: str, age: int) -> None:
"""
just a test
:param name: the name
:param age: the age
"""
print(f"name: {name}, age+1: {age + 1}")


class Foo:
def __init__(self, bar: int):
"""
foo!
:param bar: bar!
"""
print(f"{type(self).__name__} initialized with {bar}")

staticmethod
def sm(name: str) -> None:
"""
staticmethod test func
:param name: the name
"""
print(f"{name}")

classmethod
def cm(cls, name: str = "testname") -> None:
"""classmethod test func"""
print(f"{cls}, {name}")

def normal(self, foo: int) -> None:
"""a normal method, should not appear"""
print(f"{self}, foo+1: {foo+1}")

Run it like this:
console
usermachine:~$ python3 -m arguably test_script.py
usage: test_script [-h] command ...

positional arguments:
command
test just a test
foo foo!
foo.sm staticmethod test func
foo.cm classmethod test func

options:
-h, --help show this help message and exit

1.0.2

1.0.1

Version number bumped to fix PyPI readme.

1.0.0

Initial release. Testing publishing workflow.

Page 2 of 2

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.