Skip to content

fix smart graph creation #165

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

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions arango/database.py
Original file line number Diff line number Diff line change
Expand Up @@ -1209,7 +1209,7 @@ def create_graph(
'to_vertex_collections': ['lectures']
}
"""
data: Json = {"name": name}
data: Json = {"name": name, "options": dict()}
if edge_definitions is not None:
data["edgeDefinitions"] = [
{
Expand All @@ -1224,9 +1224,9 @@ def create_graph(
if smart is not None: # pragma: no cover
data["isSmart"] = smart
if smart_field is not None: # pragma: no cover
data["smartGraphAttribute"] = smart_field
data["options"]["smartGraphAttribute"] = smart_field
if shard_count is not None: # pragma: no cover
data["numberOfShards"] = shard_count
data["options"]["numberOfShards"] = shard_count

request = Request(method="post", endpoint="/_api/gharial", data=data)

Expand Down