Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhance docstrings and add examples #25

Open
namsaraeva opened this issue Jun 15, 2024 · 6 comments
Open

Enhance docstrings and add examples #25

namsaraeva opened this issue Jun 15, 2024 · 6 comments
Assignees
Labels
documentation Improvements or additions to documentation

Comments

@namsaraeva
Copy link
Collaborator

We should check all docstring so that they match in the format. Add examples where needed.

@namsaraeva namsaraeva added the documentation Improvements or additions to documentation label Jun 15, 2024
@namsaraeva namsaraeva self-assigned this Jun 15, 2024
@namsaraeva
Copy link
Collaborator Author

def function_with_pep484_type_annotations(param1: int, param2: str) -> bool:
    """Example function with PEP 484 type annotations.
    Args:
        param1: The first parameter.
        param2: The second parameter.
    Returns:
        The return value. True for success, False otherwise.
    """

I prefer this format over our current. What do you think @sophiamaedler?

@Zethson
Copy link
Collaborator

Zethson commented Jun 19, 2024

@namsaraeva is suggesting Google docstring format instead of numpy.
I can happily switch to whatever when switching to the scverse template.

@sophiamaedler
Copy link
Collaborator

I'm fine with either. What's the preferred standard in scverse packages at the moment?

Would be good if we could implement some sort of check when adding new commits after switching to make sure that all doc strings are in the chosen format. We had some mismatched formats in the past that I went through and homogenized.

@Zethson
Copy link
Collaborator

Zethson commented Jun 19, 2024

It's numpy by default but many use Google (e.g. me). It's more or less a 50/50 split.

Would be good if we could implement some sort of check when adding new commits after switching to make sure that all doc strings are in the chosen format. We had some mismatched formats in the past that I went through and homogenized.

No worries, I got you :)

@sophiamaedler
Copy link
Collaborator

Then let's go with Google :-)

Let me know if you need help with something.

@sophiamaedler
Copy link
Collaborator

this should be addressed as part of #43

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

3 participants