sqlobject-cvs Mailing List for SQLObject (Page 30)
SQLObject is a Python ORM.
Brought to you by:
ianbicking,
phd
You can subscribe to this list here.
2003 |
Jan
|
Feb
|
Mar
(9) |
Apr
(74) |
May
(29) |
Jun
(16) |
Jul
(28) |
Aug
(10) |
Sep
(57) |
Oct
(9) |
Nov
(29) |
Dec
(12) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2004 |
Jan
(7) |
Feb
(14) |
Mar
(6) |
Apr
(3) |
May
(12) |
Jun
(34) |
Jul
(9) |
Aug
(29) |
Sep
(22) |
Oct
(2) |
Nov
(15) |
Dec
(52) |
2005 |
Jan
(47) |
Feb
(78) |
Mar
(14) |
Apr
(35) |
May
(33) |
Jun
(16) |
Jul
(26) |
Aug
(63) |
Sep
(40) |
Oct
(96) |
Nov
(96) |
Dec
(123) |
2006 |
Jan
(159) |
Feb
(144) |
Mar
(64) |
Apr
(31) |
May
(88) |
Jun
(48) |
Jul
(16) |
Aug
(64) |
Sep
(87) |
Oct
(92) |
Nov
(56) |
Dec
(76) |
2007 |
Jan
(94) |
Feb
(103) |
Mar
(126) |
Apr
(123) |
May
(85) |
Jun
(11) |
Jul
(130) |
Aug
(47) |
Sep
(65) |
Oct
(70) |
Nov
(12) |
Dec
(11) |
2008 |
Jan
(30) |
Feb
(55) |
Mar
(88) |
Apr
(20) |
May
(50) |
Jun
|
Jul
(38) |
Aug
(1) |
Sep
(9) |
Oct
(5) |
Nov
(6) |
Dec
(39) |
2009 |
Jan
(8) |
Feb
(16) |
Mar
(3) |
Apr
(33) |
May
(44) |
Jun
(1) |
Jul
(10) |
Aug
(33) |
Sep
(74) |
Oct
(22) |
Nov
|
Dec
(15) |
2010 |
Jan
(28) |
Feb
(22) |
Mar
(46) |
Apr
(29) |
May
(1) |
Jun
(1) |
Jul
(27) |
Aug
(8) |
Sep
(5) |
Oct
(33) |
Nov
(24) |
Dec
(41) |
2011 |
Jan
(4) |
Feb
(12) |
Mar
(35) |
Apr
(29) |
May
(19) |
Jun
(16) |
Jul
(32) |
Aug
(25) |
Sep
(5) |
Oct
(11) |
Nov
(21) |
Dec
(12) |
2012 |
Jan
(3) |
Feb
(4) |
Mar
(20) |
Apr
(4) |
May
(25) |
Jun
(13) |
Jul
|
Aug
|
Sep
(2) |
Oct
(25) |
Nov
(9) |
Dec
(1) |
2013 |
Jan
(6) |
Feb
(8) |
Mar
|
Apr
(10) |
May
(31) |
Jun
(7) |
Jul
(18) |
Aug
(33) |
Sep
(4) |
Oct
(16) |
Nov
|
Dec
(27) |
2014 |
Jan
(2) |
Feb
|
Mar
|
Apr
(11) |
May
(39) |
Jun
(8) |
Jul
(11) |
Aug
(4) |
Sep
|
Oct
(27) |
Nov
|
Dec
(71) |
2015 |
Jan
(17) |
Feb
(47) |
Mar
(33) |
Apr
|
May
|
Jun
(9) |
Jul
(7) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(8) |
2016 |
Jan
(4) |
Feb
(4) |
Mar
|
Apr
|
May
(12) |
Jun
(7) |
Jul
(9) |
Aug
(31) |
Sep
(8) |
Oct
(3) |
Nov
(15) |
Dec
(1) |
2017 |
Jan
(13) |
Feb
(7) |
Mar
(14) |
Apr
(8) |
May
(10) |
Jun
(4) |
Jul
(2) |
Aug
(1) |
Sep
|
Oct
(8) |
Nov
(4) |
Dec
(5) |
2018 |
Jan
(2) |
Feb
(8) |
Mar
|
Apr
(4) |
May
|
Jun
(6) |
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
(1) |
Dec
|
2019 |
Jan
(1) |
Feb
(16) |
Mar
(1) |
Apr
(3) |
May
(5) |
Jun
(1) |
Jul
|
Aug
|
Sep
(2) |
Oct
|
Nov
(1) |
Dec
(3) |
2020 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
(1) |
Jun
|
Jul
|
Aug
(1) |
Sep
|
Oct
(2) |
Nov
|
Dec
(2) |
2021 |
Jan
|
Feb
(2) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
(1) |
Dec
|
2022 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(6) |
Oct
(1) |
Nov
(1) |
Dec
(4) |
2023 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(1) |
Aug
(3) |
Sep
(2) |
Oct
(2) |
Nov
(4) |
Dec
|
2024 |
Jan
|
Feb
(2) |
Mar
|
Apr
|
May
|
Jun
|
Jul
(1) |
Aug
|
Sep
(1) |
Oct
|
Nov
|
Dec
(9) |
2025 |
Jan
|
Feb
(4) |
Mar
(2) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: SourceForge.net <no...@so...> - 2012-09-21 18:48:57
|
Bugs item #3567422, was opened at 2012-09-13 09:18 Message generated for change (Comment added) made by phd You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=540672&aid=3567422&group_id=74338 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: General Group: SQLObject release (specify) Status: Open >Resolution: Works For Me Priority: 5 Private: No Submitted By: Vroo () >Assigned to: Oleg Broytman (phd) Summary: lazyUpdate is resetting fields to default values when read Initial Comment: I'm trying to use SQLObject's lazyUpdate feature and my data is getting clobbered. Here's the class definition class T(sqlobject.SQLObject): class sqlmeta: lazyUpdate = True def __enter__(self): return self def __exit__(self, type, value, traceback): if self.sqlmeta.dirty: self.syncUpdate() return False foo = IntCol() bar = IntCol(default=None) The context manager functions are so I can write something like: with T.select().getOne() as t: # update t Everything seems to work fine when I'm creating the objects. However, when I'm just reading the objects, fields with default values (like bar above) are getting reset to their default values. For example, given def get_rows(): rows = T.select() return list(repr(r) for r in rows) If I call get_rows repeatedly, I find that the first time I get the correct data and subsequent times some or all of the rows have their values replaced by their defaults. Eventually all the rows are reset to defaults. Fields without default values are not touched. If I comment out the line that sets lazyUpdate in the class definition, it works fine (presumably with many more writes to the db). If I comment out the call to syncUpdate it still fails. Changing the default to a different value (like -1) still fails (and values get reset to -1 not None). It's not some lingering schema setting as I've deleted the table and recreated it multiple times as I've been trying to resolve the problem. FWIW, I'm using SQLObject 1.3.1, Python 2.7 and PostreSQL 9.1. ---------------------------------------------------------------------- >Comment By: Oleg Broytman (phd) Date: 2012-09-21 11:48 Message: I cannot reproduce the problem; SQLObject 1.3.0, SQLite, Postgres. Can you write a simple test scripts (or a pair of scripts -- an initialization and a test) that demonstrates the problem? As simple as possible, i.e. without making the table a context manager and so on. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=540672&aid=3567422&group_id=74338 |
From: SourceForge.net <no...@so...> - 2012-09-13 16:18:26
|
Bugs item #3567422, was opened at 2012-09-13 09:18 Message generated for change (Tracker Item Submitted) made by You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=540672&aid=3567422&group_id=74338 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: General Group: SQLObject release (specify) Status: Open Resolution: None Priority: 5 Private: No Submitted By: Vroo () Assigned to: Nobody/Anonymous (nobody) Summary: lazyUpdate is resetting fields to default values when read Initial Comment: I'm trying to use SQLObject's lazyUpdate feature and my data is getting clobbered. Here's the class definition class T(sqlobject.SQLObject): class sqlmeta: lazyUpdate = True def __enter__(self): return self def __exit__(self, type, value, traceback): if self.sqlmeta.dirty: self.syncUpdate() return False foo = IntCol() bar = IntCol(default=None) The context manager functions are so I can write something like: with T.select().getOne() as t: # update t Everything seems to work fine when I'm creating the objects. However, when I'm just reading the objects, fields with default values (like bar above) are getting reset to their default values. For example, given def get_rows(): rows = T.select() return list(repr(r) for r in rows) If I call get_rows repeatedly, I find that the first time I get the correct data and subsequent times some or all of the rows have their values replaced by their defaults. Eventually all the rows are reset to defaults. Fields without default values are not touched. If I comment out the line that sets lazyUpdate in the class definition, it works fine (presumably with many more writes to the db). If I comment out the call to syncUpdate it still fails. Changing the default to a different value (like -1) still fails (and values get reset to -1 not None). It's not some lingering schema setting as I've deleted the table and recreated it multiple times as I've been trying to resolve the problem. FWIW, I'm using SQLObject 1.3.1, Python 2.7 and PostreSQL 9.1. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=540672&aid=3567422&group_id=74338 |
From: SourceForge.net <no...@so...> - 2012-06-24 12:20:24
|
Bugs item #3536492, was opened at 2012-06-19 21:45 Message generated for change (Comment added) made by phd You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=540672&aid=3536492&group_id=74338 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: General Group: SQLObject release (specify) >Status: Closed >Resolution: Fixed Priority: 5 Private: No Submitted By: je...@im... () Assigned to: Oleg Broytman (phd) Summary: sqlbuilder.Select.filter does not filter, just replaces Initial Comment: def filter(self, filter_clause): if filter_clause is None: # None doesn't filter anything, it's just a no-op: return self clause = self.ops['clause'] if isinstance(clause, basestring): clause = SQLConstant('(%s)' % clause) if clause == SQLTrueClause: <---- always evaluates to true newClause = filter_clause else: newClause = AND(clause, filter_clause) return self.newClause(newClause) if clause == SQLTrueClause always evaluates to true so the clause is never ANDed just replaced which means filter is useless. SQLExpression.__eq__ returns an SQLOp which evalutes to true. Removing this conditional statement works as expected since ANDing with a true clause will work as one expects. ---------------------------------------------------------------------- >Comment By: Oleg Broytman (phd) Date: 2012-06-24 05:20 Message: Fixed in the revisions 4545-4547 (branches 1.2, 1.3 and the trunk). Thank you! ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=540672&aid=3536492&group_id=74338 |
From: <sub...@co...> - 2012-06-24 12:19:32
|
Author: phd Date: Sun Jun 24 06:19:26 2012 New Revision: 4547 Log: Merged revision 4546 from branch 1.3: fixed a bug in sqlbuilder.Select.filter - removed comparison with SQLTrueClause. Modified: SQLObject/trunk/docs/News.txt SQLObject/trunk/sqlobject/sqlbuilder.py SQLObject/trunk/sqlobject/sresults.py Modified: SQLObject/trunk/docs/News.txt ============================================================================== --- SQLObject/trunk/docs/News.txt Sun Jun 24 06:17:40 2012 (r4546) +++ SQLObject/trunk/docs/News.txt Sun Jun 24 06:19:26 2012 (r4547) @@ -10,6 +10,11 @@ SQLObject (trunk) ================= +SQLObject 1.3.2 +=============== + +* A bugfix was ported from `SQLObject 1.2.4`_. + SQLObject 1.3.1 =============== @@ -32,6 +37,12 @@ rewritten and extended; ``charset`` was renamed to ``dbEncoding``; a longstanding bug was fixed - pass port to connect(). +SQLObject 1.2.4 +=============== + +* Fixed a bug in sqlbuilder.Select.filter - removed comparison with + SQLTrueClause. + SQLObject 1.2.3 =============== Modified: SQLObject/trunk/sqlobject/sqlbuilder.py ============================================================================== --- SQLObject/trunk/sqlobject/sqlbuilder.py Sun Jun 24 06:17:40 2012 (r4546) +++ SQLObject/trunk/sqlobject/sqlbuilder.py Sun Jun 24 06:19:26 2012 (r4547) @@ -618,12 +618,7 @@ clause = self.ops['clause'] if isinstance(clause, basestring): clause = SQLConstant('(%s)' % clause) - - if clause == SQLTrueClause: - newClause = filter_clause - else: - newClause = AND(clause, filter_clause) - return self.newClause(newClause) + return self.newClause(AND(clause, filter_clause)) def __sqlrepr__(self, db): Modified: SQLObject/trunk/sqlobject/sresults.py ============================================================================== --- SQLObject/trunk/sqlobject/sresults.py Sun Jun 24 06:17:40 2012 (r4546) +++ SQLObject/trunk/sqlobject/sresults.py Sun Jun 24 06:19:26 2012 (r4547) @@ -122,7 +122,7 @@ return self clause = self.clause if isinstance(clause, basestring): - clause = sqlbuilder.SQLConstant('(%s)' % self.clause) + clause = sqlbuilder.SQLConstant('(%s)' % clause) return self.newClause(sqlbuilder.AND(clause, filter_clause)) def __getitem__(self, value): |
From: <sub...@co...> - 2012-06-24 12:17:50
|
Author: phd Date: Sun Jun 24 06:17:40 2012 New Revision: 4546 Log: Merged revision 4545 from branch 1.2: fixed a bug in sqlbuilder.Select.filter - removed comparison with SQLTrueClause. Modified: SQLObject/branches/1.3/docs/News.txt SQLObject/branches/1.3/sqlobject/sqlbuilder.py SQLObject/branches/1.3/sqlobject/sresults.py Modified: SQLObject/branches/1.3/docs/News.txt ============================================================================== --- SQLObject/branches/1.3/docs/News.txt Sun Jun 24 06:14:24 2012 (r4545) +++ SQLObject/branches/1.3/docs/News.txt Sun Jun 24 06:17:40 2012 (r4546) @@ -7,6 +7,11 @@ .. _start: +SQLObject 1.3.2 +=============== + +* A bugfix was ported from `SQLObject 1.2.4`_. + SQLObject 1.3.1 =============== @@ -29,6 +34,12 @@ rewritten and extended; ``charset`` was renamed to ``dbEncoding``; a longstanding bug was fixed - pass port to connect(). +SQLObject 1.2.4 +=============== + +* Fixed a bug in sqlbuilder.Select.filter - removed comparison with + SQLTrueClause. + SQLObject 1.2.3 =============== Modified: SQLObject/branches/1.3/sqlobject/sqlbuilder.py ============================================================================== --- SQLObject/branches/1.3/sqlobject/sqlbuilder.py Sun Jun 24 06:14:24 2012 (r4545) +++ SQLObject/branches/1.3/sqlobject/sqlbuilder.py Sun Jun 24 06:17:40 2012 (r4546) @@ -618,12 +618,7 @@ clause = self.ops['clause'] if isinstance(clause, basestring): clause = SQLConstant('(%s)' % clause) - - if clause == SQLTrueClause: - newClause = filter_clause - else: - newClause = AND(clause, filter_clause) - return self.newClause(newClause) + return self.newClause(AND(clause, filter_clause)) def __sqlrepr__(self, db): Modified: SQLObject/branches/1.3/sqlobject/sresults.py ============================================================================== --- SQLObject/branches/1.3/sqlobject/sresults.py Sun Jun 24 06:14:24 2012 (r4545) +++ SQLObject/branches/1.3/sqlobject/sresults.py Sun Jun 24 06:17:40 2012 (r4546) @@ -122,7 +122,7 @@ return self clause = self.clause if isinstance(clause, basestring): - clause = sqlbuilder.SQLConstant('(%s)' % self.clause) + clause = sqlbuilder.SQLConstant('(%s)' % clause) return self.newClause(sqlbuilder.AND(clause, filter_clause)) def __getitem__(self, value): |
From: <sub...@co...> - 2012-06-24 12:14:32
|
Author: phd Date: Sun Jun 24 06:14:24 2012 New Revision: 4545 Log: Fixed a bug in sqlbuilder.Select.filter - removed comparison with SQLTrueClause. Modified: SQLObject/branches/1.2/docs/News.txt SQLObject/branches/1.2/sqlobject/sqlbuilder.py SQLObject/branches/1.2/sqlobject/sresults.py Modified: SQLObject/branches/1.2/docs/News.txt ============================================================================== --- SQLObject/branches/1.2/docs/News.txt Fri Jun 22 14:43:54 2012 (r4544) +++ SQLObject/branches/1.2/docs/News.txt Sun Jun 24 06:14:24 2012 (r4545) @@ -7,6 +7,12 @@ .. _start: +SQLObject 1.2.4 +=============== + +* Fixed a bug in sqlbuilder.Select.filter - removed comparison with + SQLTrueClause. + SQLObject 1.2.3 =============== Modified: SQLObject/branches/1.2/sqlobject/sqlbuilder.py ============================================================================== --- SQLObject/branches/1.2/sqlobject/sqlbuilder.py Fri Jun 22 14:43:54 2012 (r4544) +++ SQLObject/branches/1.2/sqlobject/sqlbuilder.py Sun Jun 24 06:14:24 2012 (r4545) @@ -618,12 +618,7 @@ clause = self.ops['clause'] if isinstance(clause, basestring): clause = SQLConstant('(%s)' % clause) - - if clause == SQLTrueClause: - newClause = filter_clause - else: - newClause = AND(clause, filter_clause) - return self.newClause(newClause) + return self.newClause(AND(clause, filter_clause)) def __sqlrepr__(self, db): Modified: SQLObject/branches/1.2/sqlobject/sresults.py ============================================================================== --- SQLObject/branches/1.2/sqlobject/sresults.py Fri Jun 22 14:43:54 2012 (r4544) +++ SQLObject/branches/1.2/sqlobject/sresults.py Sun Jun 24 06:14:24 2012 (r4545) @@ -122,7 +122,7 @@ return self clause = self.clause if isinstance(clause, basestring): - clause = sqlbuilder.SQLConstant('(%s)' % self.clause) + clause = sqlbuilder.SQLConstant('(%s)' % clause) return self.newClause(sqlbuilder.AND(clause, filter_clause)) def __getitem__(self, value): |
From: SourceForge.net <no...@so...> - 2012-06-24 11:59:34
|
Bugs item #3532549, was opened at 2012-06-06 12:38 Message generated for change (Comment added) made by phd You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=540672&aid=3532549&group_id=74338 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: General Group: SQLObject from repository Status: Open >Resolution: Works For Me Priority: 5 Private: No Submitted By: Ian Delaney (idella) Assigned to: Oleg Broytman (phd) Summary: tests faling in sqlobject-1.3.1 Initial Comment: first is sqlobject/tests/test_sqlbuilder_joins_instances.py line 36. assert list(SBAddress.select(AND(SBPerson.q.id==SBAddress.q.personID, SBPerson.q.name=='Julia'))) == \ list(SBPerson.selectBy(name='Julia').throughTo.addresses) Julia is the second name listed in mod.ppl = inserts(SBPerson, [('James',), ('Julia',)], Unless I'm wrong the test data has it wrong. It should have the 1st name and then read through .throughTo.addresses). Repalcing Julia with James sees the test pass. Second is similar, line :56. E assert [<SBAddress 2...' personID=2>] == [<SBAddress 3 ...' personID=2>] E At index 0 diff: <SBAddress 2 city='Chicago' personID=2> != <SBAddress 3 city='Abu Dhabi' personID=2> Replacing Jilia with James sees it pass. Third; sqlobject/tests/test_transactions.py line 27 This 1 is REALLY cute. Run it in isolation; # PYTHONPATH=.:sqlobject/tests/ py.test sqlobject/tests/test_transactions.py It passes. ======================================================= 2 failed, 2 passed in 0.23 seconds ================== run the whole test suite archtester SQLObject-1.3.1 # PYTHONPATH=.:sqlobject/tests/ py.test sqlobject/tests/ TestSOTrans._connection.autoCommit = 'exception' TestSOTrans(name='joe', connection=trans) trans.rollback() trans.begin() > assert ([n.name for n in TestSOTrans.select(connection=trans)] == ['bob','tim']) E assert [] == ['bob', 'tim'] E Right contains more items, first extra item: 'bob' sqlobject/tests/test_transactions.py:26: AssertionError and it fails. go figure. As for the last two I can't figure what's going on here; ____________________________________________________________ test_transaction_delete ____________________________ close = False def test_transaction_delete(close=False): if not supports('transactions'): return setupClass(TestSOTrans) trans = TestSOTrans._connection.transaction() try: TestSOTrans(name='bob') bIn = TestSOTrans.byName('bob', connection=trans) bIn.destroySelf() bOut = TestSOTrans.select(TestSOTrans.q.name=='bob') > assert bOut.count() == 1 E assert 0 == 1 E + where 0 = <bound method SelectResults.count of <SelectResults at 19c9810>>() E + where <bound method SelectResults.count of <SelectResults at 19c9810>> = <SelectResults at 19c9810>.count sqlobject/tests/test_transactions.py:64: AssertionError _______________________________________________________ test_transaction_delete_with_close __________________________ def test_transaction_delete_with_close(): > test_transaction_delete(close=True) sqlobject/tests/test_transactions.py:76: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ close = True def test_transaction_delete(close=False): if not supports('transactions'): return setupClass(TestSOTrans) trans = TestSOTrans._connection.transaction() try: TestSOTrans(name='bob') bIn = TestSOTrans.byName('bob', connection=trans) bIn.destroySelf() bOut = TestSOTrans.select(TestSOTrans.q.name=='bob') > assert bOut.count() == 1 E assert 0 == 1 E + where 0 = <bound method SelectResults.count of <SelectResults at 1ca8c50>>() E + where <bound method SelectResults.count of <SelectResults at 1ca8c50>> = <SelectResults at 1ca8c50>.count sqlobject/tests/test_transactions.py:64: AssertionError set close = True OR False, && it fails. The real problem is in > assert bOut.count() == 1 E assert 0 == 1 so the error msg indicates assert bOut.count() evaluates to 0. set assert bOut.count() == 0 and it goes completely carzy reporting an out of index error from another core sqlobject func. I gather test_transaction_delete failure invokes test_transaction_delete_with_close failure, and I have no idea what assert bOut.count() need be set to for success. I can't find a value. ---------------------------------------------------------------------- >Comment By: Oleg Broytman (phd) Date: 2012-06-24 04:59 Message: Hi. Both tests work for me: ============================= test session starts ============================== platform linux2 -- Python 2.6.6 -- pytest-1.3.3 test path 1: test_sqlbuilder_joins_instances.py test_sqlbuilder_joins_instances.py ....... =========================== 7 passed in 0.57 seconds =========================== ============================= test session starts ============================== platform linux2 -- Python 2.6.6 -- pytest-1.3.3 test path 1: test_transactions.py test_transactions.py .... =========================== 4 passed in 0.19 seconds =========================== So you problems might be somewhere else. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=540672&aid=3532549&group_id=74338 |
From: SourceForge.net <no...@so...> - 2012-06-22 21:59:49
|
Bugs item #3536492, was opened at 2012-06-19 21:45 Message generated for change (Settings changed) made by phd You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=540672&aid=3536492&group_id=74338 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: General Group: SQLObject release (specify) Status: Open Resolution: None Priority: 5 Private: No Submitted By: je...@im... () >Assigned to: Oleg Broytman (phd) Summary: sqlbuilder.Select.filter does not filter, just replaces Initial Comment: def filter(self, filter_clause): if filter_clause is None: # None doesn't filter anything, it's just a no-op: return self clause = self.ops['clause'] if isinstance(clause, basestring): clause = SQLConstant('(%s)' % clause) if clause == SQLTrueClause: <---- always evaluates to true newClause = filter_clause else: newClause = AND(clause, filter_clause) return self.newClause(newClause) if clause == SQLTrueClause always evaluates to true so the clause is never ANDed just replaced which means filter is useless. SQLExpression.__eq__ returns an SQLOp which evalutes to true. Removing this conditional statement works as expected since ANDing with a true clause will work as one expects. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=540672&aid=3536492&group_id=74338 |
From: <sub...@co...> - 2012-06-22 20:44:00
|
Author: phd Date: Fri Jun 22 14:43:54 2012 New Revision: 4544 Log: Merged revision 4542 from branch 1.2: minor optimization. Modified: SQLObject/trunk/sqlobject/converters.py Modified: SQLObject/trunk/sqlobject/converters.py ============================================================================== --- SQLObject/trunk/sqlobject/converters.py Fri Jun 22 14:43:29 2012 (r4543) +++ SQLObject/trunk/sqlobject/converters.py Fri Jun 22 14:43:54 2012 (r4544) @@ -216,7 +216,7 @@ return "'%s'" % s def unquote_str(s): - if s.upper().startswith("E'") and s.endswith("'"): + if s[:2].upper().startswith("E'") and s.endswith("'"): return s[2:-1] elif s.startswith("'") and s.endswith("'"): return s[1:-1] |
From: <sub...@co...> - 2012-06-22 20:43:37
|
Author: phd Date: Fri Jun 22 14:43:29 2012 New Revision: 4543 Log: Merged revision 4542 from branch 1.2: minor optimization. Modified: SQLObject/branches/1.3/sqlobject/converters.py Modified: SQLObject/branches/1.3/sqlobject/converters.py ============================================================================== --- SQLObject/branches/1.3/sqlobject/converters.py Fri Jun 22 14:42:01 2012 (r4542) +++ SQLObject/branches/1.3/sqlobject/converters.py Fri Jun 22 14:43:29 2012 (r4543) @@ -216,7 +216,7 @@ return "'%s'" % s def unquote_str(s): - if s.upper().startswith("E'") and s.endswith("'"): + if s[:2].upper().startswith("E'") and s.endswith("'"): return s[2:-1] elif s.startswith("'") and s.endswith("'"): return s[1:-1] |
From: <sub...@co...> - 2012-06-22 20:42:09
|
Author: phd Date: Fri Jun 22 14:42:01 2012 New Revision: 4542 Log: Minor optimization. Modified: SQLObject/branches/1.2/sqlobject/converters.py Modified: SQLObject/branches/1.2/sqlobject/converters.py ============================================================================== --- SQLObject/branches/1.2/sqlobject/converters.py Fri May 25 13:18:58 2012 (r4541) +++ SQLObject/branches/1.2/sqlobject/converters.py Fri Jun 22 14:42:01 2012 (r4542) @@ -216,7 +216,7 @@ return "'%s'" % s def unquote_str(s): - if s.upper().startswith("E'") and s.endswith("'"): + if s[:2].upper().startswith("E'") and s.endswith("'"): return s[2:-1] elif s.startswith("'") and s.endswith("'"): return s[1:-1] |
From: SourceForge.net <no...@so...> - 2012-06-22 10:19:41
|
Bugs item #3532549, was opened at 2012-06-06 12:38 Message generated for change (Settings changed) made by phd You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=540672&aid=3532549&group_id=74338 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. >Category: General Group: SQLObject from repository Status: Open Resolution: None Priority: 5 Private: No Submitted By: Ian Delaney (idella) >Assigned to: Oleg Broytman (phd) Summary: tests faling in sqlobject-1.3.1 Initial Comment: first is sqlobject/tests/test_sqlbuilder_joins_instances.py line 36. assert list(SBAddress.select(AND(SBPerson.q.id==SBAddress.q.personID, SBPerson.q.name=='Julia'))) == \ list(SBPerson.selectBy(name='Julia').throughTo.addresses) Julia is the second name listed in mod.ppl = inserts(SBPerson, [('James',), ('Julia',)], Unless I'm wrong the test data has it wrong. It should have the 1st name and then read through .throughTo.addresses). Repalcing Julia with James sees the test pass. Second is similar, line :56. E assert [<SBAddress 2...' personID=2>] == [<SBAddress 3 ...' personID=2>] E At index 0 diff: <SBAddress 2 city='Chicago' personID=2> != <SBAddress 3 city='Abu Dhabi' personID=2> Replacing Jilia with James sees it pass. Third; sqlobject/tests/test_transactions.py line 27 This 1 is REALLY cute. Run it in isolation; # PYTHONPATH=.:sqlobject/tests/ py.test sqlobject/tests/test_transactions.py It passes. ======================================================= 2 failed, 2 passed in 0.23 seconds ================== run the whole test suite archtester SQLObject-1.3.1 # PYTHONPATH=.:sqlobject/tests/ py.test sqlobject/tests/ TestSOTrans._connection.autoCommit = 'exception' TestSOTrans(name='joe', connection=trans) trans.rollback() trans.begin() > assert ([n.name for n in TestSOTrans.select(connection=trans)] == ['bob','tim']) E assert [] == ['bob', 'tim'] E Right contains more items, first extra item: 'bob' sqlobject/tests/test_transactions.py:26: AssertionError and it fails. go figure. As for the last two I can't figure what's going on here; ____________________________________________________________ test_transaction_delete ____________________________ close = False def test_transaction_delete(close=False): if not supports('transactions'): return setupClass(TestSOTrans) trans = TestSOTrans._connection.transaction() try: TestSOTrans(name='bob') bIn = TestSOTrans.byName('bob', connection=trans) bIn.destroySelf() bOut = TestSOTrans.select(TestSOTrans.q.name=='bob') > assert bOut.count() == 1 E assert 0 == 1 E + where 0 = <bound method SelectResults.count of <SelectResults at 19c9810>>() E + where <bound method SelectResults.count of <SelectResults at 19c9810>> = <SelectResults at 19c9810>.count sqlobject/tests/test_transactions.py:64: AssertionError _______________________________________________________ test_transaction_delete_with_close __________________________ def test_transaction_delete_with_close(): > test_transaction_delete(close=True) sqlobject/tests/test_transactions.py:76: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ close = True def test_transaction_delete(close=False): if not supports('transactions'): return setupClass(TestSOTrans) trans = TestSOTrans._connection.transaction() try: TestSOTrans(name='bob') bIn = TestSOTrans.byName('bob', connection=trans) bIn.destroySelf() bOut = TestSOTrans.select(TestSOTrans.q.name=='bob') > assert bOut.count() == 1 E assert 0 == 1 E + where 0 = <bound method SelectResults.count of <SelectResults at 1ca8c50>>() E + where <bound method SelectResults.count of <SelectResults at 1ca8c50>> = <SelectResults at 1ca8c50>.count sqlobject/tests/test_transactions.py:64: AssertionError set close = True OR False, && it fails. The real problem is in > assert bOut.count() == 1 E assert 0 == 1 so the error msg indicates assert bOut.count() evaluates to 0. set assert bOut.count() == 0 and it goes completely carzy reporting an out of index error from another core sqlobject func. I gather test_transaction_delete failure invokes test_transaction_delete_with_close failure, and I have no idea what assert bOut.count() need be set to for success. I can't find a value. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=540672&aid=3532549&group_id=74338 |
From: SourceForge.net <no...@so...> - 2012-06-20 04:45:20
|
Bugs item #3536492, was opened at 2012-06-19 21:45 Message generated for change (Tracker Item Submitted) made by You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=540672&aid=3536492&group_id=74338 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: General Group: SQLObject release (specify) Status: Open Resolution: None Priority: 5 Private: No Submitted By: je...@im... () Assigned to: Nobody/Anonymous (nobody) Summary: sqlbuilder.Select.filter does not filter, just replaces Initial Comment: def filter(self, filter_clause): if filter_clause is None: # None doesn't filter anything, it's just a no-op: return self clause = self.ops['clause'] if isinstance(clause, basestring): clause = SQLConstant('(%s)' % clause) if clause == SQLTrueClause: <---- always evaluates to true newClause = filter_clause else: newClause = AND(clause, filter_clause) return self.newClause(newClause) if clause == SQLTrueClause always evaluates to true so the clause is never ANDed just replaced which means filter is useless. SQLExpression.__eq__ returns an SQLOp which evalutes to true. Removing this conditional statement works as expected since ANDing with a true clause will work as one expects. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=540672&aid=3536492&group_id=74338 |
From: SourceForge.net <no...@so...> - 2012-06-06 20:20:54
|
Bugs item #3532549, was opened at 2012-06-06 12:38 Message generated for change (Settings changed) made by idella You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=540672&aid=3532549&group_id=74338 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. >Category: DBM >Group: SQLObject from repository Status: Open Resolution: None Priority: 5 Private: No Submitted By: Ian Delaney (idella) >Assigned to: David Turner (novalis_dt) Summary: tests faling in sqlobject-1.3.1 Initial Comment: first is sqlobject/tests/test_sqlbuilder_joins_instances.py line 36. assert list(SBAddress.select(AND(SBPerson.q.id==SBAddress.q.personID, SBPerson.q.name=='Julia'))) == \ list(SBPerson.selectBy(name='Julia').throughTo.addresses) Julia is the second name listed in mod.ppl = inserts(SBPerson, [('James',), ('Julia',)], Unless I'm wrong the test data has it wrong. It should have the 1st name and then read through .throughTo.addresses). Repalcing Julia with James sees the test pass. Second is similar, line :56. E assert [<SBAddress 2...' personID=2>] == [<SBAddress 3 ...' personID=2>] E At index 0 diff: <SBAddress 2 city='Chicago' personID=2> != <SBAddress 3 city='Abu Dhabi' personID=2> Replacing Jilia with James sees it pass. Third; sqlobject/tests/test_transactions.py line 27 This 1 is REALLY cute. Run it in isolation; # PYTHONPATH=.:sqlobject/tests/ py.test sqlobject/tests/test_transactions.py It passes. ======================================================= 2 failed, 2 passed in 0.23 seconds ================== run the whole test suite archtester SQLObject-1.3.1 # PYTHONPATH=.:sqlobject/tests/ py.test sqlobject/tests/ TestSOTrans._connection.autoCommit = 'exception' TestSOTrans(name='joe', connection=trans) trans.rollback() trans.begin() > assert ([n.name for n in TestSOTrans.select(connection=trans)] == ['bob','tim']) E assert [] == ['bob', 'tim'] E Right contains more items, first extra item: 'bob' sqlobject/tests/test_transactions.py:26: AssertionError and it fails. go figure. As for the last two I can't figure what's going on here; ____________________________________________________________ test_transaction_delete ____________________________ close = False def test_transaction_delete(close=False): if not supports('transactions'): return setupClass(TestSOTrans) trans = TestSOTrans._connection.transaction() try: TestSOTrans(name='bob') bIn = TestSOTrans.byName('bob', connection=trans) bIn.destroySelf() bOut = TestSOTrans.select(TestSOTrans.q.name=='bob') > assert bOut.count() == 1 E assert 0 == 1 E + where 0 = <bound method SelectResults.count of <SelectResults at 19c9810>>() E + where <bound method SelectResults.count of <SelectResults at 19c9810>> = <SelectResults at 19c9810>.count sqlobject/tests/test_transactions.py:64: AssertionError _______________________________________________________ test_transaction_delete_with_close __________________________ def test_transaction_delete_with_close(): > test_transaction_delete(close=True) sqlobject/tests/test_transactions.py:76: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ close = True def test_transaction_delete(close=False): if not supports('transactions'): return setupClass(TestSOTrans) trans = TestSOTrans._connection.transaction() try: TestSOTrans(name='bob') bIn = TestSOTrans.byName('bob', connection=trans) bIn.destroySelf() bOut = TestSOTrans.select(TestSOTrans.q.name=='bob') > assert bOut.count() == 1 E assert 0 == 1 E + where 0 = <bound method SelectResults.count of <SelectResults at 1ca8c50>>() E + where <bound method SelectResults.count of <SelectResults at 1ca8c50>> = <SelectResults at 1ca8c50>.count sqlobject/tests/test_transactions.py:64: AssertionError set close = True OR False, && it fails. The real problem is in > assert bOut.count() == 1 E assert 0 == 1 so the error msg indicates assert bOut.count() evaluates to 0. set assert bOut.count() == 0 and it goes completely carzy reporting an out of index error from another core sqlobject func. I gather test_transaction_delete failure invokes test_transaction_delete_with_close failure, and I have no idea what assert bOut.count() need be set to for success. I can't find a value. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=540672&aid=3532549&group_id=74338 |
From: SourceForge.net <no...@so...> - 2012-06-06 19:38:08
|
Bugs item #3532549, was opened at 2012-06-06 12:38 Message generated for change (Tracker Item Submitted) made by idella You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=540672&aid=3532549&group_id=74338 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: None Group: None Status: Open Resolution: None Priority: 5 Private: No Submitted By: Ian Delaney (idella) Assigned to: Nobody/Anonymous (nobody) Summary: tests faling in sqlobject-1.3.1 Initial Comment: first is sqlobject/tests/test_sqlbuilder_joins_instances.py line 36. assert list(SBAddress.select(AND(SBPerson.q.id==SBAddress.q.personID, SBPerson.q.name=='Julia'))) == \ list(SBPerson.selectBy(name='Julia').throughTo.addresses) Julia is the second name listed in mod.ppl = inserts(SBPerson, [('James',), ('Julia',)], Unless I'm wrong the test data has it wrong. It should have the 1st name and then read through .throughTo.addresses). Repalcing Julia with James sees the test pass. Second is similar, line :56. E assert [<SBAddress 2...' personID=2>] == [<SBAddress 3 ...' personID=2>] E At index 0 diff: <SBAddress 2 city='Chicago' personID=2> != <SBAddress 3 city='Abu Dhabi' personID=2> Replacing Jilia with James sees it pass. Third; sqlobject/tests/test_transactions.py line 27 This 1 is REALLY cute. Run it in isolation; # PYTHONPATH=.:sqlobject/tests/ py.test sqlobject/tests/test_transactions.py It passes. ======================================================= 2 failed, 2 passed in 0.23 seconds ================== run the whole test suite archtester SQLObject-1.3.1 # PYTHONPATH=.:sqlobject/tests/ py.test sqlobject/tests/ TestSOTrans._connection.autoCommit = 'exception' TestSOTrans(name='joe', connection=trans) trans.rollback() trans.begin() > assert ([n.name for n in TestSOTrans.select(connection=trans)] == ['bob','tim']) E assert [] == ['bob', 'tim'] E Right contains more items, first extra item: 'bob' sqlobject/tests/test_transactions.py:26: AssertionError and it fails. go figure. As for the last two I can't figure what's going on here; ____________________________________________________________ test_transaction_delete ____________________________ close = False def test_transaction_delete(close=False): if not supports('transactions'): return setupClass(TestSOTrans) trans = TestSOTrans._connection.transaction() try: TestSOTrans(name='bob') bIn = TestSOTrans.byName('bob', connection=trans) bIn.destroySelf() bOut = TestSOTrans.select(TestSOTrans.q.name=='bob') > assert bOut.count() == 1 E assert 0 == 1 E + where 0 = <bound method SelectResults.count of <SelectResults at 19c9810>>() E + where <bound method SelectResults.count of <SelectResults at 19c9810>> = <SelectResults at 19c9810>.count sqlobject/tests/test_transactions.py:64: AssertionError _______________________________________________________ test_transaction_delete_with_close __________________________ def test_transaction_delete_with_close(): > test_transaction_delete(close=True) sqlobject/tests/test_transactions.py:76: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ close = True def test_transaction_delete(close=False): if not supports('transactions'): return setupClass(TestSOTrans) trans = TestSOTrans._connection.transaction() try: TestSOTrans(name='bob') bIn = TestSOTrans.byName('bob', connection=trans) bIn.destroySelf() bOut = TestSOTrans.select(TestSOTrans.q.name=='bob') > assert bOut.count() == 1 E assert 0 == 1 E + where 0 = <bound method SelectResults.count of <SelectResults at 1ca8c50>>() E + where <bound method SelectResults.count of <SelectResults at 1ca8c50>> = <SelectResults at 1ca8c50>.count sqlobject/tests/test_transactions.py:64: AssertionError set close = True OR False, && it fails. The real problem is in > assert bOut.count() == 1 E assert 0 == 1 so the error msg indicates assert bOut.count() evaluates to 0. set assert bOut.count() == 0 and it goes completely carzy reporting an out of index error from another core sqlobject func. I gather test_transaction_delete failure invokes test_transaction_delete_with_close failure, and I have no idea what assert bOut.count() need be set to for success. I can't find a value. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=540672&aid=3532549&group_id=74338 |
From: <sub...@co...> - 2012-05-25 19:19:05
|
Author: phd Date: Fri May 25 13:18:58 2012 New Revision: 4541 Log: Stable version SQLObject 1.3.1. Modified: SQLObject/tags/1.3.1/README.txt SQLObject/tags/1.3.1/setup.cfg SQLObject/tags/1.3.1/sqlobject/__version__.py Modified: SQLObject/tags/1.3.1/README.txt ============================================================================== --- SQLObject/tags/1.3.1/README.txt Fri May 25 13:17:44 2012 (r4540) +++ SQLObject/tags/1.3.1/README.txt Fri May 25 13:18:58 2012 (r4541) @@ -1,5 +1,5 @@ -SQLObject 1.3 -============= +SQLObject 1.3.1 +=============== Thanks for looking at SQLObject. SQLObject is an object-relational mapper, i.e., a library that will wrap your database tables in Python Modified: SQLObject/tags/1.3.1/setup.cfg ============================================================================== --- SQLObject/tags/1.3.1/setup.cfg Fri May 25 13:17:44 2012 (r4540) +++ SQLObject/tags/1.3.1/setup.cfg Fri May 25 13:18:58 2012 (r4541) @@ -5,10 +5,6 @@ [easy_install] #find_links = http://svn.pythonpaste.org/package_index.html -[egg_info] -tag_build = dev -tag_svn_revision = true - [pudge] theme = pythonpaste.org docs = docs/index.txt docs/Authors.txt docs/DeveloperGuide.txt docs/FAQ.txt Modified: SQLObject/tags/1.3.1/sqlobject/__version__.py ============================================================================== --- SQLObject/tags/1.3.1/sqlobject/__version__.py Fri May 25 13:17:44 2012 (r4540) +++ SQLObject/tags/1.3.1/sqlobject/__version__.py Fri May 25 13:18:58 2012 (r4541) @@ -1,8 +1,8 @@ -version = '1.3' +version = '1.3.1' major = 1 minor = 3 -micro = 0 -release_level = 'trunk' +micro = 1 +release_level = 'final' serial = 0 version_info = (major, minor, micro, release_level, serial) |
From: <sub...@co...> - 2012-05-25 19:17:50
|
Author: phd Date: Fri May 25 13:17:44 2012 New Revision: 4540 Log: Tagging 1.3.1 Added: SQLObject/tags/1.3.1/ - copied from r4539, SQLObject/branches/1.3/ |
From: <sub...@co...> - 2012-05-25 19:13:05
|
Author: phd Date: Fri May 25 13:12:59 2012 New Revision: 4539 Log: Stable version SQLObject 1.2.3. Modified: SQLObject/tags/1.2.3/README.txt SQLObject/tags/1.2.3/setup.cfg SQLObject/tags/1.2.3/sqlobject/__version__.py Modified: SQLObject/tags/1.2.3/README.txt ============================================================================== --- SQLObject/tags/1.2.3/README.txt Fri May 25 13:11:17 2012 (r4538) +++ SQLObject/tags/1.2.3/README.txt Fri May 25 13:12:59 2012 (r4539) @@ -1,5 +1,5 @@ -SQLObject 1.2 -============= +SQLObject 1.2.3 +=============== Thanks for looking at SQLObject. SQLObject is an object-relational mapper, i.e., a library that will wrap your database tables in Python Modified: SQLObject/tags/1.2.3/setup.cfg ============================================================================== --- SQLObject/tags/1.2.3/setup.cfg Fri May 25 13:11:17 2012 (r4538) +++ SQLObject/tags/1.2.3/setup.cfg Fri May 25 13:12:59 2012 (r4539) @@ -5,10 +5,6 @@ [easy_install] #find_links = http://svn.pythonpaste.org/package_index.html -[egg_info] -tag_build = dev -tag_svn_revision = true - [pudge] theme = pythonpaste.org docs = docs/index.txt docs/Authors.txt docs/DeveloperGuide.txt docs/FAQ.txt Modified: SQLObject/tags/1.2.3/sqlobject/__version__.py ============================================================================== --- SQLObject/tags/1.2.3/sqlobject/__version__.py Fri May 25 13:11:17 2012 (r4538) +++ SQLObject/tags/1.2.3/sqlobject/__version__.py Fri May 25 13:12:59 2012 (r4539) @@ -1,8 +1,8 @@ -version = '1.2' +version = '1.2.3' major = 1 minor = 2 -micro = 0 -release_level = 'branch' +micro = 3 +release_level = 'final' serial = 0 version_info = (major, minor, micro, release_level, serial) |
From: <sub...@co...> - 2012-05-25 19:11:23
|
Author: phd Date: Fri May 25 13:11:17 2012 New Revision: 4538 Log: Tagging 1.2.3 Added: SQLObject/tags/1.2.3/ - copied from r4537, SQLObject/branches/1.2/ |
From: <sub...@co...> - 2012-05-25 19:10:19
|
Author: phd Date: Fri May 25 13:10:13 2012 New Revision: 4537 Log: SQLObject 1.2.3 and 1.3.1 were released 25 May 2012. Modified: SQLObject/trunk/docs/News.txt Modified: SQLObject/trunk/docs/News.txt ============================================================================== --- SQLObject/trunk/docs/News.txt Fri May 25 13:09:33 2012 (r4536) +++ SQLObject/trunk/docs/News.txt Fri May 25 13:10:13 2012 (r4537) @@ -13,6 +13,8 @@ SQLObject 1.3.1 =============== +Released 25 May 2012. + * Two bugfixes were ported from `SQLObject 1.2.3`_. SQLObject 1.3.0 @@ -33,6 +35,8 @@ SQLObject 1.2.3 =============== +Released 25 May 2012. + * Fixed a minor bug in PostgreSQL introspection: VIEWs don't have PRIMARY KEYs - use sqlmeta.idName as the key. |
From: <sub...@co...> - 2012-05-25 19:09:39
|
Author: phd Date: Fri May 25 13:09:33 2012 New Revision: 4536 Log: SQLObject 1.2.3 and 1.3.1 were released 25 May 2012. Modified: SQLObject/branches/1.3/docs/News.txt Modified: SQLObject/branches/1.3/docs/News.txt ============================================================================== --- SQLObject/branches/1.3/docs/News.txt Fri May 25 13:07:35 2012 (r4535) +++ SQLObject/branches/1.3/docs/News.txt Fri May 25 13:09:33 2012 (r4536) @@ -10,6 +10,8 @@ SQLObject 1.3.1 =============== +Released 25 May 2012. + * Two bugfixes were ported from `SQLObject 1.2.3`_. SQLObject 1.3.0 @@ -30,6 +32,8 @@ SQLObject 1.2.3 =============== +Released 25 May 2012. + * Fixed a minor bug in PostgreSQL introspection: VIEWs don't have PRIMARY KEYs - use sqlmeta.idName as the key. |
From: <sub...@co...> - 2012-05-25 19:07:41
|
Author: phd Date: Fri May 25 13:07:35 2012 New Revision: 4535 Log: SQLObject 1.2.3 was released 25 May 2012. Modified: SQLObject/branches/1.2/docs/News.txt Modified: SQLObject/branches/1.2/docs/News.txt ============================================================================== --- SQLObject/branches/1.2/docs/News.txt Fri May 25 12:48:01 2012 (r4534) +++ SQLObject/branches/1.2/docs/News.txt Fri May 25 13:07:35 2012 (r4535) @@ -10,6 +10,8 @@ SQLObject 1.2.3 =============== +Released 25 May 2012. + * Fixed a minor bug in PostgreSQL introspection: VIEWs don't have PRIMARY KEYs - use sqlmeta.idName as the key. |
From: <sub...@co...> - 2012-05-25 18:48:07
|
Author: phd Date: Fri May 25 12:48:01 2012 New Revision: 4534 Log: Merged revision 4532 from branch 1.2: use cache.tryGet() instead of cache.get(). Modified: SQLObject/trunk/sqlobject/main.py SQLObject/trunk/sqlobject/tests/test_pickle.py Modified: SQLObject/trunk/sqlobject/main.py ============================================================================== --- SQLObject/trunk/sqlobject/main.py Fri May 25 12:47:15 2012 (r4533) +++ SQLObject/trunk/sqlobject/main.py Fri May 25 12:48:01 2012 (r4534) @@ -1682,15 +1682,14 @@ return d def __setstate__(self, d): - id = d['id'] - cls = self.__class__ - cache = self._connection.cache - if cache.get(id, cls) is not None: - raise ValueError( - "Cannot unpickle %s row with id=%s - the id already exists in the cache" % (cls.__name__, id)) self.__init__(_SO_fetch_no_create=1) self._SO_writeLock = threading.Lock() self.__dict__.update(d) + cls = self.__class__ + cache = self._connection.cache + if cache.tryGet(self.id, cls) is not None: + raise ValueError( + "Cannot unpickle %s row with id=%s - a different instance with the id already exists in the cache" % (cls.__name__, self.id)) cache.created(id, cls, self) Modified: SQLObject/trunk/sqlobject/tests/test_pickle.py ============================================================================== --- SQLObject/trunk/sqlobject/tests/test_pickle.py Fri May 25 12:47:15 2012 (r4533) +++ SQLObject/trunk/sqlobject/tests/test_pickle.py Fri May 25 12:48:01 2012 (r4534) @@ -15,15 +15,16 @@ def test_pickleCol(): setupClass(TestPickle) + connection = TestPickle._connection test = TestPickle(question=test_question, answer=test_answer) pickle_data = pickle.dumps(test, pickle.HIGHEST_PROTOCOL) + connection.cache.clear() test = pickle.loads(pickle_data) assert test.question == test_question assert test.answer == test_answer - connection = TestPickle._connection if (connection.dbName == 'sqlite') and connection._memory: return # The following test requires a different connection |
From: <sub...@co...> - 2012-05-25 18:47:23
|
Author: phd Date: Fri May 25 12:47:15 2012 New Revision: 4533 Log: Merged revision 4532 from branch 1.2: use cache.tryGet() instead of cache.get(). Modified: SQLObject/branches/1.3/sqlobject/main.py SQLObject/branches/1.3/sqlobject/tests/test_pickle.py Modified: SQLObject/branches/1.3/sqlobject/main.py ============================================================================== --- SQLObject/branches/1.3/sqlobject/main.py Fri May 25 12:45:46 2012 (r4532) +++ SQLObject/branches/1.3/sqlobject/main.py Fri May 25 12:47:15 2012 (r4533) @@ -1682,15 +1682,14 @@ return d def __setstate__(self, d): - id = d['id'] - cls = self.__class__ - cache = self._connection.cache - if cache.get(id, cls) is not None: - raise ValueError( - "Cannot unpickle %s row with id=%s - the id already exists in the cache" % (cls.__name__, id)) self.__init__(_SO_fetch_no_create=1) self._SO_writeLock = threading.Lock() self.__dict__.update(d) + cls = self.__class__ + cache = self._connection.cache + if cache.tryGet(self.id, cls) is not None: + raise ValueError( + "Cannot unpickle %s row with id=%s - a different instance with the id already exists in the cache" % (cls.__name__, self.id)) cache.created(id, cls, self) Modified: SQLObject/branches/1.3/sqlobject/tests/test_pickle.py ============================================================================== --- SQLObject/branches/1.3/sqlobject/tests/test_pickle.py Fri May 25 12:45:46 2012 (r4532) +++ SQLObject/branches/1.3/sqlobject/tests/test_pickle.py Fri May 25 12:47:15 2012 (r4533) @@ -15,15 +15,16 @@ def test_pickleCol(): setupClass(TestPickle) + connection = TestPickle._connection test = TestPickle(question=test_question, answer=test_answer) pickle_data = pickle.dumps(test, pickle.HIGHEST_PROTOCOL) + connection.cache.clear() test = pickle.loads(pickle_data) assert test.question == test_question assert test.answer == test_answer - connection = TestPickle._connection if (connection.dbName == 'sqlite') and connection._memory: return # The following test requires a different connection |
From: <sub...@co...> - 2012-05-25 18:45:53
|
Author: phd Date: Fri May 25 12:45:46 2012 New Revision: 4532 Log: Use cache.tryGet() instead of cache.get(). Fixed pickle test. Modified: SQLObject/branches/1.2/sqlobject/main.py SQLObject/branches/1.2/sqlobject/tests/test_pickle.py Modified: SQLObject/branches/1.2/sqlobject/main.py ============================================================================== --- SQLObject/branches/1.2/sqlobject/main.py Fri May 25 10:32:14 2012 (r4531) +++ SQLObject/branches/1.2/sqlobject/main.py Fri May 25 12:45:46 2012 (r4532) @@ -1682,15 +1682,14 @@ return d def __setstate__(self, d): - id = d['id'] - cls = self.__class__ - cache = self._connection.cache - if cache.get(id, cls) is not None: - raise ValueError( - "Cannot unpickle %s row with id=%s - the id already exists in the cache" % (cls.__name__, id)) self.__init__(_SO_fetch_no_create=1) self._SO_writeLock = threading.Lock() self.__dict__.update(d) + cls = self.__class__ + cache = self._connection.cache + if cache.tryGet(self.id, cls) is not None: + raise ValueError( + "Cannot unpickle %s row with id=%s - a different instance with the id already exists in the cache" % (cls.__name__, self.id)) cache.created(id, cls, self) Modified: SQLObject/branches/1.2/sqlobject/tests/test_pickle.py ============================================================================== --- SQLObject/branches/1.2/sqlobject/tests/test_pickle.py Fri May 25 10:32:14 2012 (r4531) +++ SQLObject/branches/1.2/sqlobject/tests/test_pickle.py Fri May 25 12:45:46 2012 (r4532) @@ -15,15 +15,16 @@ def test_pickleCol(): setupClass(TestPickle) + connection = TestPickle._connection test = TestPickle(question=test_question, answer=test_answer) pickle_data = pickle.dumps(test, pickle.HIGHEST_PROTOCOL) + connection.cache.clear() test = pickle.loads(pickle_data) assert test.question == test_question assert test.answer == test_answer - connection = TestPickle._connection if (connection.dbName == 'sqlite') and connection._memory: return # The following test requires a different connection |