You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Just a quick issue to track that we might want to revert #1114.
It adds set like views for headers but fails to implement the "views should reflect mutations of the mapping" part, leading to more ambiguous / buggy behavior than when we were obviously returning plain lists.
Then maybe we should just treat this "header views" idea as a "no"...?
I'm pretty okay with our status there. We're annotating the interface, not the behaviour.
And yes there's a minor gotcha there, for advanced Python users who try to do something that's a bit too clever for their own good but it's an issue that's there either way around.
Obviously we could accept PRs that switched those out to being actual live views, rather than copies, but I'd rather we had a proper Mapping-like interface, than not.
Sure, I'm on the fence because of this as well - overall #1114 felt like progress, even though there's now this gotcha about some part of the mapping API we weren't implementing yet anyway.
Well, then maybe let's close this, and if/when someone hits the somewhat very niche "my header views aren't updated when I update the headers instance" use case and reports it we can track that separately.
Activity
lovelydinosaur commentedon Aug 6, 2020
I'm pretty okay with our status there. We're annotating the interface, not the behaviour.
And yes there's a minor gotcha there, for advanced Python users who try to do something that's a bit too clever for their own good but it's an issue that's there either way around.
Obviously we could accept PRs that switched those out to being actual live views, rather than copies, but I'd rather we had a proper Mapping-like interface, than not.
florimondmanca commentedon Aug 6, 2020
Sure, I'm on the fence because of this as well - overall #1114 felt like progress, even though there's now this gotcha about some part of the mapping API we weren't implementing yet anyway.
florimondmanca commentedon Aug 6, 2020
Well, then maybe let's close this, and if/when someone hits the somewhat very niche "my header views aren't updated when I update the headers instance" use case and reports it we can track that separately.