10000 gcloud.datastore.key.Key.from_path is undocumented, untested · Issue #134 · googleapis/google-cloud-python · GitHub
[go: up one dir, main page]

Skip to content
gcloud.datastore.key.Key.from_path is undocumented, untested #134
Closed
@tseaver

Description

@tseaver

I'm not sure what its contract is, either:

>>> from gcloud.datastore.key import Key
>>> Key.from_path().path()
[{'kind': ''}]
>>> Key.from_path('abc').path()
[{'kind': ''}]
>>> Key.from_path('abc', 'def').path()
[{'kind': 'abc', 'name': 'def'}]
>>> Key.from_path('abc', 'def', 'ghi').path()
[{'kind': 'abc', 'name': 'def'}]
>>> Key.from_path('abc', 'def', 'ghi', 123).path()
[{'kind': 'abc', 'name': 'def'}, {'kind': 'ghi', 'id': 123}]

Dropping the odd last element doesn't seem correct.

Metadata

Metadata

Assignees

Labels

🚨This issue needs some love.api: datastoreIssues related to the Datastore API.triage meI really want to be triaged.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

    0