1747 Commits

Author SHA1 Message Date
David Bordeynik
d4f6ef4f1b Merge pull request #1113 from DavidBord/fix-1105
fix-#1105: StrictDict & SemiStrictDict are shadowed at init time
2015-10-11 21:14:05 +03:00
Kirill Kuzminykh
11024deaae Fixed detection of shared connections 2015-10-05 22:40:44 +03:00
Lars Butler
5a038de1d5 fields.ReferenceField: add integer values to reverse_delete_rule docs
When I first tried to use the `reverse_delete_rule` feature of
`ReferenceField`, I had to dig through the source code to find what the
actual integer values were expected to be for DO_NOTHING, NULLIFY,
CASCADE, DENY, and PULL (or at least, where these constants were defined
so that I could import and use them). This patch adds the integer values
for those constants (which are defined in mongoengine.queryset.base) to
the docs so that users can easily choose the correct integer value.

Note: A possible improvement on this change would be to include
`mongoengine.queryset.base` module documentation in the generated docs,
and then update the `ReferenceField` docs to link to the documentation
of these constants (DO_NOTHING, NULLIFY, etc.).
2015-10-05 14:37:03 +02:00
Emmanuel Leblond
903982e896 Merge pull request #1088 from touilleMan/bug-1058
Fix DictField with '_cls' field is converted to Document on access
2015-09-21 12:10:23 +02:00
David Bordeynik
6355c404cc fix-#1105: StrictDict & SemiStrictDict are shadowed at init time 2015-09-16 20:27:52 +03:00
Catstyle
a6a1021521 use obj._data instead of self._fields_ordered since DynamicDocument missing some attributes 2015-09-02 18:42:30 +02:00
Emmanuel Leblond
6cf630c74a Merge pull request #1096 from vasion/save-condition-for-2.4
save_condition uses "n" instead of "nModified"
2015-09-02 18:23:37 +02:00
Emmanuel Leblond
736fe5b84e Fix unwanted dereference in DictField (issue #1058) 2015-08-30 10:01:24 +02:00
Omer Katz
4241bde6ea Merge pull request #1055 from zxhuang/master
comply to pymongo MongoClient constructor host
2015-08-16 11:52:27 +03:00
Momchil Rogelov
b4ce14d744 use n instead of nModified in save_condition 2015-08-13 10:11:42 +01:00
Momchil Rogelov
10832a2ccc save_condition falls back to "n" if "nModified" is not found to support mongo 2.4 2015-08-12 10:57:20 +01:00
Emmanuel Leblond
91aca44f67 Merge pull request #1093 from touilleMan/bug-1069
Replace disconnect with close method in pymongo
2015-08-10 18:40:59 +02:00
Emmanuel Leblond
96cfbb201a Replace use close method in pymongo 2015-08-04 18:02:57 +02:00
Emmanuel Leblond
0752c6b24f Update changelog for #1070 2015-07-19 10:33:54 +02:00
Emmanuel Leblond
a3e0fbd606 Add SaveConditionError exception 2015-07-15 11:15:40 +02:00
Emmanuel Leblond
bebce2c053 Clean ununsed variables in iterations 2015-07-09 10:51:04 +02:00
Emmanuel Leblond
34c6790762 Simplify implementation of choices in GenericReferenceField 2015-07-06 10:10:05 +02:00
Emmanuel Leblond
a5fb009b62 Fix GenericReferenceField choices with DBRef and let it possible to set Document choice as string 2015-07-06 02:33:43 +02:00
David Bordeynik
5334ea393e fix-#842: Fix ignored chained options 2015-07-02 23:08:09 +03:00
Zeke Huang
2aaacc02e3 comply to pymongo MongoClient constructor host
Only MongoReplicaSetClient use hosts_or_uri param and it will be deprecated soon.
2015-07-01 12:39:30 -07:00
amitlicht
9ce605221a Suggested fix for #1047: CachedReferenceField creates DBRef on to_python, but can't save them on to_mongo.
Dereferencing DBRef to document type before returning it from to_python.
2015-06-28 17:53:20 +03:00
emilecaron
56a2e07dc2 always store docs in cascade_refs 2015-06-26 10:45:07 +00:00
emilecaron
9b7fe9ac31 restore broken behavior 2015-06-26 09:31:07 +00:00
emilecaron
b691a56d51 late set instanciation 2015-06-26 08:52:30 +00:00
emilecaron
646baddce4 fix cascade delete cycle issuue 2015-06-25 18:27:22 +00:00
emilecaron
1e3d2df9e7 fix illogicality 2015-06-25 15:40:12 +00:00
Matthieu Rigal
c6151e34e0 Bumped version to 0.10.0 2015-06-24 12:39:21 +02:00
Matthieu Rigal
0aeb1ca408 Various fixes again 2015-06-24 00:50:36 +02:00
mrigal
217c9720ea added iterkeys method and optimized repr, still very ugly 2015-06-23 23:15:44 +02:00
mrigal
778c7dc5f2 general pep8 and more clean-up 2015-06-23 23:15:44 +02:00
Vicky Donchenko
6bd9529a66 Allow to add custom metadata to fields 2015-06-23 16:25:56 +03:00
Matthieu Rigal
9063b559c4 Fix for PyMongo3+ 2015-06-22 16:40:50 +02:00
Matthieu Rigal
40f6df7160 Adapted one more test for MongoDB < 3 2015-06-22 14:57:59 +02:00
Matthieu Rigal
95165aa92f Logic and test adaptations for MongoDB < 3 2015-06-22 14:57:59 +02:00
Matthieu Rigal
d96fcdb35c Fixed problem of ordering when using near_sphere operator 2015-06-22 14:57:58 +02:00
Matthieu Rigal
5efabdcea3 Added tests, documentation and simplified code 2015-06-22 14:57:58 +02:00
Liam Horne
2d57dc0565 Fixed an indentation mistake 2015-06-22 14:57:30 +02:00
lihorne
576629f825 Added support for $minDistance query 2015-06-22 14:57:30 +02:00
Matthieu Rigal
49c0c9f44c Simplified lookup-field method, allowing dynamic lookup for more than two parts 2015-06-22 14:55:06 +02:00
Matthieu Rigal
ef5fa4d062 Merge pull request #1037 from MRigal/fix/1008-delete-returns-none-allowed
Added test and fix for delete with write_concern w:0
2015-06-22 14:50:04 +02:00
Matthieu Rigal
bcc4d4e8c6 Added test and fix for delete with write_concern w:0 2015-06-21 03:40:45 +02:00
Breeze.kay
41bff0b293 remove testcase:test_signals_with_switch_sharding_db() and fix code style error for pull#1020 2015-06-21 09:32:31 +08:00
Breeze.kay
dfc7f35ef1 add testcase and changelog for pull:#1020 'improve _created status when switch collection and db' 2015-06-19 15:40:05 +08:00
Breeze.kay
0bbbbdde80 Merge remote-tracking branch 'MongoEngine/master' 2015-06-19 11:14:51 +08:00
Stefan Wojcik
b7ef82cb67 style tweaks + changelog entry 2015-06-18 11:02:11 -07:00
Stefan Wojcik
1233780265 make aggregate_sum/average compatible with pymongo 3.x 2015-06-18 11:01:37 -07:00
Stefan Wojcik
dd095279c8 aggregate_sum/average + unit tests 2015-06-18 11:01:37 -07:00
Matthieu Rigal
1bcd675ead Python 3 fix, uses floor division 2015-06-15 13:44:11 +02:00
Matthieu Rigal
2a3d3de0b2 CappedCollection max_size normalized to multiple of 256 2015-06-15 00:22:07 +02:00
Matthieu Rigal
b124836f3a Merge pull request #936 from MRigal/fix/712-avoid-crash-looping-on-corrupted-obj-id
changed ObjectIdField to_python() method to avoid crash, issue 712
2015-06-14 23:31:22 +02:00