records icon indicating copy to clipboard operation
records copied to clipboard

Connections no longer close prematurely.

Open gdtroszak opened this issue 6 years ago • 8 comments

This should fix the issue outlined in https://github.com/kennethreitz/records/issues/128. Essentially, SQLAlchemy connections were being closed prior to their results being consumed by RecordCollections.

Connections spawned by Database query methods are configured to automatically close once their results are consumed. Otherwise, just calling db.get_connection() will return a Connection that must be managed by the user. I also made it a point to check for stray connections prior to closing the DB, but that may be overridden.

Sorry for the delay on this.

gdtroszak avatar Jun 16 '18 21:06 gdtroszak

Thanks for handling this, I was just about to start looking at it!

techalchemy avatar Jun 29 '18 18:06 techalchemy

Shouldn't this be merged?

mostafazh avatar Dec 26 '18 21:12 mostafazh

I believe so. I just need someone with the appropriate privileges to review and merge.

gdtroszak avatar Dec 30 '18 20:12 gdtroszak

@vlcinsky

kittenswolf avatar Jan 11 '19 20:01 kittenswolf

I plan to check it by Monday. Thanks for reminding.

vlcinsky avatar Jan 11 '19 20:01 vlcinsky

hey @vlcinsky, is this good to go?

Projjol-zz avatar Feb 14 '19 12:02 Projjol-zz

Bueller... Bueller... Buelller...

gdtroszak avatar Apr 17 '19 12:04 gdtroszak

Any updates? @vlcinsky

chuangbo avatar May 25 '21 06:05 chuangbo