Project

General

Profile

Actions

Feature #22126

closed

PySDK method reference includes defaults

Added by Brett Smith 4 months ago. Updated 3 months ago.

Status:
Resolved
Priority:
Normal
Assigned To:
Category:
SDKs
Story points:
-

Description

In arvados.api_resources none of the methods specify default arguments. This comment explains the rationale:

# In normal Python the presence of a default tells you whether or
# not an argument is required. In the API the `required` flag tells
# us that, and defaults are specified inconsistently. Don't show
# defaults in the signature: it adds noise and makes things more
# confusing for the reader about what's required and what's
# optional. The docstring can explain in better detail, including
# the default value.

Improve this:

  • If there is a useful default, specify that in the parameter.
  • If there isn't, make the parameter Optional[T]=None.
Actions #1

Updated by Brett Smith 4 months ago

  • Status changed from New to In Progress
Actions #2

Updated by Brett Smith 4 months ago

Being bundled with #22079.

Actions #3

Updated by Brett Smith 3 months ago

  • Status changed from In Progress to Resolved
Actions

Also available in: Atom PDF