Missing step on "How to upgrade to v0.3.2"

Hi team,

There’s one step missing from the instructions under “How to upgrade to v0.3.2” on Release v0.3.2 · redwoodjs/redwood · GitHub.

For this file: api/src/functions/graphql.js, do the following:

  • add this line at the top:

import { db } from 'src/lib/db'

edited: Fixed quotes. Thanks, @olance!

1 Like

Thanks! I’ve updated them!

2 Likes

Gah… who wrote that thing?! :roll_eyes:

Also, I think I’ll make sure the instructions here on the forums are updated as well.

Thanks!

There’s the curly single quote issue again in the instructions :slight_smile:

However, I’ve upgraded to 0.3.0 and then 0.3.2 without adding the db import to graphql.js and everything seems to work perfectly, as far as the tutorial project is concerned.

So I wonder if the instruction is really necessary?

Thanks for the quick answer, core team!

@olance could you try your console please? you should get an error there : (

Yes, I believe it’s a subtle issue but therefore needs to be addressed early! You’ll see console error on Posts (for example) when editing, deleting, etc. But the UI won’t be affected (in the tutorial at least).

And we did make the change in the create-redwood-app template going forward. Here’s the commit where it’s added:

1 Like

:man_facepalming: Markdown is just the worst… Fixing now.

1 Like

@betocmn @thedavid so actually I am seeing a 400 error, but it shows even after adding the import to graphql.js :confused:

Also, from your commit it looks like the release notes are missing the addition of db, to the makeMergedSchema call?

@olance Actually, where did you see it. On GitHub or here? Things seem to be displaying correctly on my end regarding

import { db } from 'src/lib/db'

hmmm… I’ve copied and pasted the line from Github and got curly quotes then… but it’s not the case anymore! :man_shrugging:

Roger that. Thanks for checking.

Carry on!

:slight_smile:

I think the GraphQL error I’m seeing is related to this issue:

@betocmn @thedavid is that error you’re mentioning supposed to break anything? Like prevent data updates to the DB or something?

1 Like

Ah, re: db… yes indeed! Aaaannnnddd, updated. Thanks :tada: