3meters / proxibase

Patchr web service
1 stars 0 forks source link

addCreateLinks fails for locked patch #416

Closed Jaymassena closed 8 years ago

Jaymassena commented 8 years ago

I'm not sure about whether this is by design or not. Here is the results from the errlog and I don't have the request.

{ code: 401, message: 'Warning, entity update succeded, but related updates failed addCreateLinks. Details: Unauthorized: Locked', name: 'ProxError', status: 401, appStack: 'ProxError: Warning, entity update succeded, but related updates failed addCreateLinks. Details: Unauthorized: Locked at canLinkTo (/usr/local/prox/lib/schemas/link.js:158:22) at runTask (/usr/local/prox/lib/mongosafe/write.js:196:12) at /usr/local/prox/lib/schemas/link.js:141:5 at finish (/usr/local/prox/lib/utils/timeLimit.js:41:8) at send (/usr/local/prox/lib/mongosafe/read.js:330:11) at /usr/local/prox/lib/mongosafe/read.js:324:13 at setCanEdit (/usr/local/prox/lib/schemas/_base.js:65:3) at callAfter (/usr/local/prox/lib/mongosafe/read.js:321:14) at /usr/local/prox/lib/mongosafe/read.js:318:15 at decorate (/usr/local/prox/lib/mongosafe/read.js:540:46) at finish (/usr/local/prox/lib/mongosafe/read.js:282:7) at processResults (/usr/local/prox/lib/mongosafe/read.js:275:12) at runQuery (/usr/local/prox/lib/mongosafe/read.js:204:45) at finish (/usr/local/prox/lib/mongosafe/read.js:531:5) at /usr/local/prox/lib/mongosafe/read.js:524:51 at /usr/local/prox/lib/schemas/_base.js:144:5 at /usr/local/prox/lib/schemas/_base.js:200:32 at /usr/local/prox/lib/schemas/_base.js:416:27 at finish (/usr/local/prox/lib/utils/timeLimit.js:41:8) at send (/usr/local/prox/lib/mongosafe/read.js:330:11) at /usr/local/prox/lib/mongosafe/read.js:324:13 at setCanEdit (/usr/local/prox/lib/schemas/_base.js:65:3) at callAfter (/usr/local/prox/lib/mongosafe/read.js:321:14) at /usr/local/prox/lib/mongosafe/read.js:318:15 at decorate (/usr/local/prox/lib/mongosafe/read.js:540:46) at finish (/usr/local/prox/lib/mongosafe/read.js:282:7) at processResults (/usr/local/prox/lib/mongosafe/read.js:275:12) at readableAddChunk (_stream_readable.js:146:16) at Socket.Readable.push (_stream_readable.js:110:10) at TCP.onread (net.js:523:20)' }

georgesnelling commented 8 years ago

I was not able to repo this by creating a locked patch. The error message was missing the tag property to tie it back to a request, so I added that little hint. I found one possible state that could have cause this problem, and fixed that, but I am unsure why that state did not repro in my test. I'm going to mark this as fixed for now, but that could be wrong. Feel free to reopen if you spot again.

Fix pushed to production with build 3.8.9.