-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Using Knex Adapter with KeystoneJS 5 and Postgresql: AdminUI keeps showing “GraphQL error: Cannot read property 'refListKey' of undefined ” #2610
Comments
Hey @ra-external, looks like you maybe found a fix here. What was the resolution? |
@molomby -- I don't think I did in the end. I think moving forward to newer versions of the packages did solve this error but introduced new ones. Sorry to be so vague -- trying to upgrade the packages together with using Postgresql has been a hassle and I've spent many hours trying many different combinations and getting many different errors, so I can't remember what worked and when. But I wasn't able to move forward, so for the moment I'm using Mongo and waiting for the latest version of the packages to appear soon. I'll upgrade and see if it fixes 'everything'. |
Oh jeez, yeah.. just read your other issues. Sounds like you've hit a lot of snags :( Sorry about that This iteration of Keystone's still pretty young so there will be occasional breaking changes. We use semver pretty conservatively, so the dependancies specified by a package should be fine, but if you have an old-ish You probably want to either install package version that were released around the same time (they will have all been tested against each other at release) or wait until all the latest packages work for you then upgrade them all at once. For this specific case I'd actually advise the latter -- there's been some really important work done on relationships in the knex adapter recently; probably worth holding out for the new stuff. |
@molomby -- Thanks. I was told that there was a large PR that was going to be merged very shortly, so I'm hoping that that will solve many of my issues. When you say "You probably want to either install package version that were released around the same time (they will have all been tested against each other at release": is there any way to get a |
We have a KeystoneJS app which up until now has used MongoDB. Our DevOps want use to move to Postgresql, which KeystoneJS 5 supports through the Knex adapter.
I don't know much about Postgresql (I've used Mongo), but I followed the instructions at the above link and the DB is set up and running. I removed the authentication for Keystone as instructed and created a new User. However when I add the authentication back and login to the AdminUI I get the following error, not only on the user page, where it's repeated twice, but on other pages as well.
The relevant portion of code, where I connect the Knex adapter, is
To get the DB set up the first time I had to use
I get these errors in the browser console
The application was running fine with Mongo and I have hardly changed anything. I have no references to
refListKey
in my code -- the only ones I could find were in the Keystone libraries.This is my User list
I am not using the just-released versions of the Keystone libraries, as there were problems with them that need to be resolved (this was another issue) -- but instead these
Any clues on how to move forward would be much appreciated. Do I need to do something the Postgresql DB, and if so, what/how?
The text was updated successfully, but these errors were encountered: