piccolo-orm / piccolo

A fast, user friendly ORM and query builder which supports asyncio.
https://piccolo-orm.com/
MIT License
1.41k stars 89 forks source link

Pressing Enter in `Reverse 1 migration? [y/N]` still leads to reversing. #991

Closed metakot closed 4 months ago

metakot commented 4 months ago

When undoing the migration, pressing Enter after the prompt Reverse 1 migration? [y/N] still undoing it regardless of the default N behavior.

dantownsend commented 4 months ago

Ah, weird. I just tried it and I can see what you mean.

Screenshot 2024-05-21 at 10 58 38

I'll have a look at the code.

dantownsend commented 4 months ago

I've figured out the problem. Basically this:

>>> '' in 'yY'
True

I think this is quite unintuitive - I would have expected False.