Add timezone disclaimer to docstring
Novice users may be tempted to pass in values such as datetime.datetime.now() as a parameter when querying for usage. Adding a disclaimer to the type hints that inputs are interpreted as UTC may help avoid this mistake. Change-Id: Iad34c15f98538fd12215397cb2d9391189f99f79
This commit is contained in:
parent
4c1dab99e3
commit
ef3856804d
@ -51,8 +51,8 @@ class UsageManager(base.ManagerWithFind):
|
||||
"""
|
||||
Get usage for all tenants
|
||||
|
||||
:param start: :class:`datetime.datetime` Start date
|
||||
:param end: :class:`datetime.datetime` End date
|
||||
:param start: :class:`datetime.datetime` Start date in UTC
|
||||
:param end: :class:`datetime.datetime` End date in UTC
|
||||
:param detailed: Whether to include information about each
|
||||
instance whose usage is part of the report
|
||||
:rtype: list of :class:`Usage`.
|
||||
@ -67,8 +67,8 @@ class UsageManager(base.ManagerWithFind):
|
||||
Get usage for a specific tenant.
|
||||
|
||||
:param tenant_id: Tenant ID to fetch usage for
|
||||
:param start: :class:`datetime.datetime` Start date
|
||||
:param end: :class:`datetime.datetime` End date
|
||||
:param start: :class:`datetime.datetime` Start date in UTC
|
||||
:param end: :class:`datetime.datetime` End date in UTC
|
||||
:rtype: :class:`Usage`
|
||||
"""
|
||||
return self._get("/os-simple-tenant-usage/%s?start=%s&end=%s" %
|
||||
|
Loading…
x
Reference in New Issue
Block a user