Received: by 10.50.33.180 with SMTP id s20mr3534090igi.5.1349210059663; Tue, 02 Oct 2012 13:34:19 -0700 (PDT) X-BeenThere: mongoose-orm@googlegroups.com Received: by 10.50.140.40 with SMTP id rd8ls6031884igb.2.canary; Tue, 02 Oct 2012 13:34:18 -0700 (PDT) Received: by 10.42.63.72 with SMTP id b8mr10403556ici.29.1349210058473; Tue, 02 Oct 2012 13:34:18 -0700 (PDT) Received: by 10.42.63.72 with SMTP id b8mr10403555ici.29.1349210058461; Tue, 02 Oct 2012 13:34:18 -0700 (PDT) Return-Path: Received: from mail-ie0-f174.google.com (mail-ie0-f174.google.com [209.85.223.174]) by gmr-mx.google.com with ESMTPS id s15si144283igi.1.2012.10.02.13.34.17 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 02 Oct 2012 13:34:17 -0700 (PDT) Received-SPF: temperror (google.com: error in processing during lookup of rich...@batemansr.us: DNS timeout) client-ip=209.85.223.174; Authentication-Results: gmr-mx.google.com; spf=temperror (google.com: error in processing during lookup of rich...@batemansr.us: DNS timeout) smtp.mail=rich...@batemansr.us Received: by mail-ie0-f174.google.com with SMTP id k13so15686297iea.19 for ; Tue, 02 Oct 2012 13:34:17 -0700 (PDT) d=google.com; s=20120113; h=content-type:mime-version:subject:from:in-reply-to:date :content-transfer-encoding:message-id:references:to:x-mailer :x-gm-message-state; bh=AF+yl0+hplpM46Br/9juFrGG9ySYZDdBzjnHzZPKJsg=; b=FHQCSwnNvyTn9yqbcFpSOwCHb2YcRxar91p7Spor3uE0QghWdZgWLgRZ22jcg/4KFs m+pEVkIQCue3YYJR4f1p1T63GOI5w2jLHR4OT29+zOXLj/Acvvoth+6MFJDEMy97kUs1 zxwYNuCZrLHvyIvu0DUC0W44h8Wbm+fihcE2edEQEO5a3NzCb7QsEmjhFN9TzZtoYgF0 tm70J8TY0ak0p1owJ/d9405PEQ3BbrViKj8Uykj0P8cWGBnarU5ETKaCJnx2gMjwhO/B /HoLOF+UA18yLvdZqBaeYhFsf0Xe5I0T2YqKa+ZiJtb0UyJxnfTuNqe71RHbhBH9856r 4cWg== Received: by 10.50.154.168 with SMTP id vp8mr10000544igb.3.1349210057405; Tue, 02 Oct 2012 13:34:17 -0700 (PDT) Return-Path: Received: from [172.19.42.2] (50-73-40-249-utah.hfc.comcastbusiness.net. [50.73.40.249]) by mx.google.com with ESMTPS id o7sm576202igd.15.2012.10.02.13.34.16 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 02 Oct 2012 13:34:16 -0700 (PDT) Content-Type: text/plain; charset=iso-8859-1 Mime-Version: 1.0 (Apple Message framework v1278) Subject: Re: [mongoose] No matching document found From: Richard Bateman In-Reply-To: Date: Tue, 2 Oct 2012 14:34:14 -0600 Content-Transfer-Encoding: quoted-printable Message-Id: References: To: mongoose-orm@googlegroups.com X-Mailer: Apple Mail (2.1278) X-Gm-Message-State: ALoCoQmWP4SMVguVFETmVoJH18aHpsTj6b0lBAKKPK4oOXUvOo/9M81G5Ou5//UDVwSLZpmD0BfO I'll see if I can find time to throw something together. The other = issue turned out to be a document that was mistakenly saved twice in a = row. Does the version change *every* time the document is updated, or only = when changes are made to an array? Richard On Oct 1, 2012, at 3:25 PM, Aaron Heckmann wrote: > It would be nice to have code to test. >=20 > "No matching document found" comes when attempting to make changes to > an array by index position and the documents version already changed > in the db. = http://aaronheckmann.posterous.com/mongoose-v3-part-1-versioning >=20 > You can disable versioning (not recommended) by setting your schema > option: new Schema({..}, { versionKey: false }) >=20 > On Mon, Sep 24, 2012 at 1:38 PM, Richard Bateman = wrote: >>=20 >> Okay, I found one of the issues was caused by two saves called in the = same request. The first only changes one field and it's not an array, = the second changes an array. Not sure why it should matter which occurs = first since they dont' modify the same parts of the document; any = thoughts? One is just updating a "last seen" timestamp and it's in our = middleware and doesn't know about other modifications that might need to = be made. >>=20 >> Richard >>=20 >> On Sep 13, 2012, at 3:30 PM, Aaron Heckmann wrote: >>=20 >>> Odd indeed. Would you mind opening an issue with code to reproduce? >>>=20 >>> https://github.com/LearnBoost/mongoose/issues/new >>>=20 >>> On Sep 13, 2012, at 1:02 PM, Richard Bateman = wrote: >>>=20 >>>>=20 >>>> We recently updated to the 3.1.x branch and are using 3.1.2 from = npm. I noticed recently that some of our models are now behaving a = little oddly; every time I save after changing an array from our = document I get the error "No matching document found". The weirdest = thing, though, is that it still saves the document. >>>>=20 >>>> Doing a little research it looks like this could be related to = versioning, but nothing else is changing that document while I'm doing = this (it's local on my dev box currently). Also the fact that it saves = anyway but throws an error is really odd. >>>>=20 >>>> Any ideas? >>>>=20 >>>> Richard >>>>=20 >>>> -- >>>> -- >>>> http://mongoosejs.com - docs >>>> http://plugins.mongoosejs.com - plugins search >>>> http://github.com/learnboost/mongoose - source code >>>>=20 >>>> You received this message because you are subscribed to the Google >>>> Groups "Mongoose Node.JS ORM" group. >>>> To post to this group, send email to mongoose-orm@googlegroups.com >>>> To unsubscribe from this group, send email to >>>> mongoose-orm+unsubscribe@googlegroups.com >>>> For more options, visit this group at >>>> http://groups.google.com/group/mongoose-orm?hl=3Den >>>>=20 >>>>=20 >>>=20 >>> -- >>> -- >>> http://mongoosejs.com - docs >>> http://plugins.mongoosejs.com - plugins search >>> http://github.com/learnboost/mongoose - source code >>>=20 >>> You received this message because you are subscribed to the Google >>> Groups "Mongoose Node.JS ORM" group. >>> To post to this group, send email to mongoose-orm@googlegroups.com >>> To unsubscribe from this group, send email to >>> mongoose-orm+unsubscribe@googlegroups.com >>> For more options, visit this group at >>> http://groups.google.com/group/mongoose-orm?hl=3Den >>>=20 >>>=20 >>=20 >> -- >> -- >> http://mongoosejs.com - docs >> http://plugins.mongoosejs.com - plugins search >> http://github.com/learnboost/mongoose - source code >>=20 >> You received this message because you are subscribed to the Google >> Groups "Mongoose Node.JS ORM" group. >> To post to this group, send email to mongoose-orm@googlegroups.com >> To unsubscribe from this group, send email to >> mongoose-orm+unsubscribe@googlegroups.com >> For more options, visit this group at >> http://groups.google.com/group/mongoose-orm?hl=3Den >>=20 >>=20 >=20 >=20 >=20 > --=20 > Aaron > @aaronheckmann >=20 > --=20 > --=20 > http://mongoosejs.com - docs > http://plugins.mongoosejs.com - plugins search > http://github.com/learnboost/mongoose - source code >=20 > You received this message because you are subscribed to the Google > Groups "Mongoose Node.JS ORM" group. > To post to this group, send email to mongoose-orm@googlegroups.com > To unsubscribe from this group, send email to > mongoose-orm+unsubscribe@googlegroups.com > For more options, visit this group at > http://groups.google.com/group/mongoose-orm?hl=3Den >=20 >=20