Conversation
I copied and adapted the `NamedTupleCursor` tests.
9bd5ba0 to
d309918
Compare
|
Hi, I am not really interested in adding an editable tuple type in the adapter. If you want to champion such object please open a discussion in the mailing list. |
|
No, I'm not going to join your mailing list. I opened a discussion by opening this PR, you chose to close that discussion. The obvious conclusion is that you probably have no intention of ever merging this branch. Since the hybrid row type isn't wanted here I'll put it in postgres.py instead. |
|
This is a bug tracker, pretty much only under my eyes. New ideas ought to be discussed if they want to be included into an industry-standard project, if they are pushed to be used by all the world, if they have to be maintained by others. It's good stuff that you take responsibility for your solely designed object instead of dumping it on us without discussion, yes. Put your class wherever you want. |
|
You are stalling contributions (e.g. #565) and driving away contributors by insisting that everything be discussed in your old-fashioned mailing list. It seems you don't realize that every GitHub repository is also a mailing list, which anyone who already has a GitHub account can subscribe to in two clicks. The psycopg2 repository currently has 64 watchers, it's not “pretty much only under [your] eyes”. Who said that my code would have to be maintained by others? I would have handled the maintenance of this code. |
This branch adds an alternative to representing query results as namedtuples or dicts. The new `Row` class supports both item and attribute lookups and assignments. Unlike namedtuples these hybrid rows are mutable, and they're all instances of a single class. I tried to submit this upstream, but it didn't go well (<psycopg/psycopg2#970>).
This branch introduces a new row type:
HybridRow. Unlike the other types, hybrid rows support both item and attribute lookups and assignments; and unlike namedtuples, hybrid rows are mutable and they're all instances of a single class.