Skip to content
This repository was archived by the owner on Jul 6, 2023. It is now read-only.

Conversation

@pontusmelke
Copy link
Collaborator

In the situation when running non-interactively without when a password change
was required, such as running the following on a vanilla db

cypher-shell -u neo4j -p neo4j "RETURN 1"

the user was first prompted for a password but then failed with the error

This procedure is no longer available, use: 'ALTER CURRENT USER SET PASSWORD'

This was due to a recent change how we handle interactive commands, what happens
is we never run the ping so we never get a chance to set the version field
in BoltStateHandler which in turn messes up the updating of the password since
it thinks we are communicating with an older db.

In the situation when running non-interactively without when a password change
was required, such as running the following on a vanilla db

```
cypher-shell -u neo4j -p neo4j "RETURN 1"
```

the user was first prompted for a password but then failed with the error

>This procedure is no longer available, use: 'ALTER CURRENT USER SET PASSWORD'

This was due to a recent change how we handle interactive commands, what happens
is we never run the `ping` so we never get a chance to set the `version` field
in `BoltStateHandler` which in turn messes up the updating of the password since
it thinks we are communicating with an older db.
Copy link
Collaborator

@sherfert sherfert left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it possible to recreate the previously failing case in an integration test?

@pontusmelke
Copy link
Collaborator Author

@sherfert There was an integration test that attempted to test this very thing but the test wasn't setting the version back to null, which makes the test unrealistic. Adding that to to tests made that test fail, and so there is no need to add one more test since that would basically be the exact same test.

@pontusmelke pontusmelke merged commit e78b0ab into neo4j:4.0 Apr 14, 2020
@pontusmelke pontusmelke deleted the 4.0-non-interactive-bug branch April 14, 2020 08:28
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants