Terminal: I can't use keyboard to "create / rename column" (Drizzle, Nodemon)

default discord avatar
steveninety
last month
4

In dev mode (using Nodemon), when making changes to a collection config (which Payload will automatically "push"), Drizzle asks if you want to create or rename columns.



Unfortunately, I can't use my keyboard in the terminal when the dev server is running using Nodemon. So whenever I change fields in a collection, Nodemon restarts the server and Drizzle will ask if each change I made is a column creation/rename.



From there, I can't continue, because I can't select an option.


- Tried every key on my keyboad


- Tried different terminals (Windows 11: Cygwin, Bash)


- Tried the -- -I flag in nodemon.json



My Nodemon config:



{ "ext": "ts,mts,js,json", "exec": "ts-node src/server.ts -- -I", "watch": "./src", "stdin": false }

This issue really messes up my DX, so any help would be greatly appreciated!

  • discord user avatar
    denolfe
    Payload Team
    last month

    Hmm, we tested this rather extensively. I wonder if the combination of cygwin and windows have a particular set of needs from nodemon to allow user input. Are you able to test this through something like WSL in your env to see if it behaves any different?

  • default discord avatar
    mbale
    4 weeks ago

    @steveninety I've had the same issue on Mac. Add -I flag to the nodemon script so it does allow pass-through

    CleanShot_2023-10-29_at_11.13.13.png
  • default discord avatar
    steveninety
    4 weeks ago

    Unfortunately passing the I flag doesn't do anything for me. I think this is not even nodemon related, I'm afraid it's on an OS level (damn windows...)



    I digged deep into this stuff and quite sure it's got something to do with windows. So I will give WSL a try to see if anything's different.



    I've tried WSL (Ubuntu) and it works! I knew it was a Windows OS issue that I'd never figure out, so I'm really happy to see that this is working. Now I can comfortably prototype using Drizzle push 🙂 thanks for the help!

  • discord user avatar
    denolfe
    Payload Team
    4 weeks ago

    That's great! We have one teammate that uses windows that we tested with. However, I know he doesn't use Cygwin.

Open the post
Continue the discussion in Discord
Like what we're doing?
Star us on GitHub!

Star

Connect with the Payload Community on Discord

Discord

online

Can't find what you're looking for?

Get help straight from the Payload team with an Enterprise License.