Skip to content

Commit

Permalink
Clarify Optional use case.
Browse files Browse the repository at this point in the history
  • Loading branch information
Matthew Judy committed Nov 6, 2024
1 parent 650af61 commit e307156
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions docs/contributors/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,8 @@ Any Jamf Pro API added to the clients must have the following elements code comp

* The API method has been added to the appropriate client, has a complete docstring, and has an interface in-line with other methods of that client.
* The API must have matching and complete Pydantic models.
* Provide ``@overload`` interfaces for API methods with dynamic return types (e.g. ``Union[List[Computer], Iterator[Page]]``) which be determined from the value of an argument.
* If the value of an argument or variable can be ``None``, inform the type checker by wrapping its type with ``Optional[]``.
* Provide ``@overload`` interfaces for API methods with dynamic return types (e.g. ``Union[list[Computer], Iterator[Page]]``) which be determined from the value of an argument.
* If the value of a variable, method argument, or return parameter can be ``None``, inform the type checker by wrapping its type with ``Optional[]``, e.g. ``description: Optional[str] = None``
* Unless your code is covered by another automated test you will need to add tests to ensure coverage.

The SDK references in the documentation automatically include all public method on the clients and no documentation changes may be required as a part of the contribution.
Expand Down

0 comments on commit e307156

Please sign in to comment.