-
Notifications
You must be signed in to change notification settings - Fork 151
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
Can't access cypherParams from @authorization rule #4634
Comments
Many thanks for raising this bug report @jbhurruth. 🐛 We will now attempt to reproduce the bug based on the steps you have provided. Please ensure that you've provided the necessary information for a minimal reproduction, including but not limited to:
If you have a support agreement with Neo4j, please link this GitHub issue to a new or existing Zendesk ticket. Thanks again! 🙏 |
I've relabelled this as a feature request - this is not a feature we claim to support so we will have to look into adding support for this. |
I think a workaround here is to put |
Amazing, thanks! Unfortunately the workaround doesn't work for me. There was a bug in my repro where |
Many thanks for raising this bug report @jbhurruth. 🐛 We will now attempt to reproduce the bug based on the steps you have provided. Please ensure that you've provided the necessary information for a minimal reproduction, including but not limited to:
If you have a support agreement with Neo4j, please link this GitHub issue to a new or existing Zendesk ticket. Thanks again! 🙏 |
We've been able to confirm this bug using the steps to reproduce that you provided - many thanks @jbhurruth! 🙏 We will now prioritise the bug and address it appropriately. |
So doing a final investigation on this, the feature does work as it should. Your issue seems to be with the fact that it is a I hope that helps! |
@darrellwarde Thanks for that! I forgot to update that I figured it out shortly after my last comment. I didn't expect it to get turned back into a bug ticket based on my overshare of "not your problem" info 😅 It was a bit tricky to debug due to how the debug logging prints JS Dates and neo4j DateTime objects similarly, but all good now. |
Describe the bug
I'm trying to do a node property comparison with a DateTime that is passed as a
cypherParams
field inside an@authorization.filter
rule. The cypherParam doesn't seem to be injected into the query correctly, being interpolated as a reference to a string parameter namedparam1
instead of the DateTime parameter namedyesterday
. Theparam1
string is itself the string"$yesterday"
so it almost worked but wrapped the reference in an unnecessary layer.Type definitions
To Reproduce
Run the following mutation and query
The result is an empty list.
The generated cypher for the query shows the issue
Expected behavior
The query should return any node that was not created more than 24 hours ago.
System:
The text was updated successfully, but these errors were encountered: