keystone
keystone copied to clipboard
Next.js Compile is Re-organizing List Imports causing keystone dev to quit
Hey I'm getting the same error after upgrading to the newest release, from the version before
It's building the app correctly but after the point Admin UI ready
it fails with the message
Your prisma schema has changed, please restart Keystone
Any idea what could be causing this?
Originally posted by @PhilBookst in https://github.com/keystonejs/keystone/discussions/7454#discussioncomment-2586848
I'm seeing this same behavior, but have the additional issue in that automatically organizing imports (which many people do on save), doesn't alphabetize them, and then it causes this area each time.
Why is this happening?
export { Agency } from './agency/Agency';
export { AgencyBilling } from './agency/AgencyBilling';
export { AgencyConfig } from './agency/AgencyConfig';
export { AgencyCredentialing } from './agency/AgencyCredentialing';
export { AgencyFacilityDetail } from './agency/AgencyFacilityDetail';
export { AgencyPosting } from './agency/AgencyPosting';
export { AppSetting } from './AppSetting';
export { FeeSchedule } from './billing/FeeSchedule';
export { Contact } from './Contact';
export { Facility } from './facility/Facility';
export { ImportProvider } from './ImportProvider';
export { LockboxEntry } from './posting/LockboxEntry';
export { Payer } from './posting/Payer';
export { Answer } from './qna/Answer';
export { Question } from './qna/Question';
export { Role } from './Role';
export { User } from './User';
event - compiled client and server successfully in 4.2s (1042 modules)
✅ Admin UI ready
wait - compiling /api/__keystone_api_build...
wait - compiling...
event - compiled client and server successfully in 440 ms (1089 modules)
💻 NODE_ENV=development
🕸️ FRONTEND_URL=,http://localhost:3000,https://studio.apollographql.com
🔄 Your prisma schema has changed, please restart Keystone
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
Just to confirm, organizing the list imports by identifier and not path does resolve this...
thanks
@scoussens depending on how you unpack these into your lists
object, the order of definition will define the order of the definitions in schema.prisma
and schema.graphql
.
Potentially, we should ensure that the resulting output for these schemas is stable, and not subject to re-ordering. In any event, this is a question and not an issue, marking as resolved.