Skip to content
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

Fix graph query in Cassandra #168

Merged
merged 1 commit into from
Nov 21, 2024
Merged
Show file tree
Hide file tree
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
2 changes: 1 addition & 1 deletion trustgraph-flow/trustgraph/api/gateway/service.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ def to_value(x):
if x.startswith("http:") or x.startswith("https:"):
return Value(value=x, is_uri=True)
else:
return Value(value=x, is_uri=True)
return Value(value=x, is_uri=False)

def to_subgraph(x):
return [
Expand Down
2 changes: 1 addition & 1 deletion trustgraph-flow/trustgraph/direct/cassandra.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ def get_sp(self, s, p, limit=10):

def get_po(self, p, o, limit=10):
return self.session.execute(
f"select s from {self.table} where p = %s and o = %s allow filtering limit {limit}",
f"select s from {self.table} where p = %s and o = %s limit {limit} allow filtering",
(p, o)
)

Expand Down
Loading