Reason:
ssname present in the text file - print(*objects, sep=' ', end='\n', file=sys.stdout, flush=False)
ssname in the content kind:
- String value -> "print(*objects, sep=' ', end='\\n', file=sys.stdout, flush=False)"
ssname in the query to fetch the document from content kind:
select * from content where documentProcessingId = '68881601-b3dc-484e-ba5f-01246c2457b0' and ssname = 'Built-in Functions' and sssname = 'print(*objects, sep=\' \', end=\'\n\', file=sys.stdout, flush=False)'
we are doing escape SingleQuotation for the sname( ' to \'). If we don't escape single quotation, it will throw this error
SEVERE: com.google.cloud.datastore.DatastoreException: Encountered "r" at line 1, column 157.
Was expecting one of:
<EOF>
"and" ...
"group" ...
"limit" ...
"offset" ...
"order" ...
That's why the single quotation is escaped as the sssname is included in the query string. After the query, the filter looks like this,
filters {
property_filter {
property {
name: "sssname"
}
op: EQUAL
value {
string_value: "print(*objects, sep=\' \', end=\'\n\', file=sys.stdout, flush=False)"
}
}
}
So, the sssname present in the filter and the sssname present in the content kind will not match. I thinks that's why it can't able find the matching document.
If we don't do escape single quotation, it will throw this error
SEVERE: com.google.cloud.datastore.DatastoreException: Encountered "r" at line 1, column 157., If we do escape single quotation, it will not find the comaparable document for document 60 of Lib ref DT.