-
Notifications
You must be signed in to change notification settings - Fork 27
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
Too many values to unpack #59
Comments
wtforms looks like they're up to some amateur nonsense -- issue here: pallets-eco/wtforms#692 - @davidism feel free to chime in. Looks like you broke flask-appbuilder (and by proxy apache airflow) with this backwards-incompatible change in a minor release. |
I've put a gross workaround in-place for now, thanks for reporting @Nixellion. This is starting to feel pretty normal from the flask-* "code shufflers" https://blog.miguelgrinberg.com/post/we-have-to-talk-about-flask |
Thanks. Is it on pypi already? Yes, I've read that article and left a comment on it a few hours ago. I am afraid these code shuffling games can kill off flask ecosystem if they don't stop. TLDR I think code shuffling is fine if it helps make working with the project easier, but not at the cost of wasting potentially millions of workhours of other people around the world. I am worried these changes may cause many extensions to die out, and without them flask will lose its main (one of) selling point - modularity and ecosystem of extensions. And its even before we remember that its not limited to just flask. |
Yeah, 3.0.5 should be up on pypi as of now. As an aside, I'm glad I'm not the only who feels that way -- sometimes I wonder if I've just become old and curmudgeonly, but beyond my crustiness, it legitimately does seems like a lot of factors are in play.
I remember getting heated about some changes pallets was proposing a while back -- pallets/jinja#1121 -- and looks like my comment got deleted. Lol glad they walked that one back, that would've been a massive pain. My comment was luckily preserved by wayback: Lol looking more closely it looks like old @davidism was at the helm of that one, too. |
Oh yeah, I'm sure many are on board with this, Miguel for example. However he also said in a follow up blog post that there was a lot of pushback not just from maintainers, but from community at large. Maybe we are getting old 😅 I think this needs to be split into 2 different themes though. One is "fast development pace, many changes", and another is "code shuffling". Miguel described this well in his article, it's fine making changes and breaking changes are ok, but it's not ok making a breaking change just because you didn't like the name of a variable. Or when introducing backwards compatibility is as simple as adding an alias for it. For example I "fixed" the issue of missing # region Patch flask login
import urllib.parse
import werkzeug.urls
werkzeug.urls.url_decode = werkzeug.urls.unquote
werkzeug.urls.url_encode = werkzeug.urls.urlencode
# endregion How hard is it to add:
It's TWO LINES! And they don't even look too gross. At the end of the day I just want things to work, and preferably without constantly re-learning how to do things. I am in the process of upgrading my flask project template and as part of it I considered "finally" switching to a "bigger better more standard" SQLAlchemy. And... I didn't. I am sticking with peewee, because it looks like SQLA released 2.0 version not long ago, and with it changed a lot of APIs and approaches. So it's kinda in this transitional state, not here nor there. Just some praise for the stable and very well documented peewee 🙂 Can't live without it. Easier and more streamlined migrations is probably the only thing that I miss, or examples\best practices about how best to handle and automate migrations in a medium-large project. |
I believe this is an incompatibility with latest updates to WTForms 3.1.0, or maybe to something else in the flask ecosystem. Here's an error I get:
Basically, from what I gather, previously field.iter_choices() didn't have the "render_kw" variable passed in the Select field, now it does.
Using
WTForms<3.1.0
requirement works as a workaround, and does not seem to cause any other conflicts.I will also propose a change to WTForms to retain backwards compatibility (not using unpacking and making render_kw optional)
The text was updated successfully, but these errors were encountered: