On Thu, Apr 23, 2009 at 05:53:03PM -0000, Leonard Richardson wrote:
> The culprit is a combination of the unmarshalled_field_cache and the
> ObjectModifiedEvent. The OME modified date_last_updated, but
> lazr.restful didn't hear about it, and only removed the fields the
> client modified from unmarshalled_field_cache. So the old
> date_last_updated stays in there.
>
> I have a fix but since the lazr.restful example service doesn't use OMEs
> at all, a proper test will take a little while.
>
> --
> When adding tag or updating description, lp_save() gives "HTTP Error 412: Precondition Failed"
> https://bugs.launchpad.net/bugs/336866
> You received this bug notification because you are a direct subscriber
> of the bug.
>
> Status in Launchpad web services client library: Triaged
>
> Bug description:
> Getting this error consistently when attempting to add a tag using the following code (which worked last time I ran it a few weeks ago).
>
> if not tag in bug.tags:
> #bug.tags.append(tag)
> # Workaround bug #254901
> tag_list = bug.tags
> tag_list.append(tag)
> bug.tags = tag_list
>
> print " ---> Tagged ",tag
> bug.lp_save()
>
> I also tested with the commented line instead of the workaround code; same error.
>
> Traceback (most recent call last):
> File "./process-new-bugs.py", line 175, in <module>
> bug.append_tag("needs-lspci-vvnn")
> File "/home/bryce/src/Arsenal/arsenal/contrib/arsenal_lib.py", line 125, in append_tag
> self.bug.lp_save()
> File "build/bdist.linux-x86_64/egg/launchpadlib/resource.py", line 489, in lp_save
> File "build/bdist.linux-x86_64/egg/launchpadlib/_browser.py", line 266, in patch
> File "build/bdist.linux-x86_64/egg/launchpadlib/_browser.py", line 212, in _request
> launchpadlib.errors.HTTPError: HTTP Error 412: Precondition Failed
Awesome! Looking forward to trying it out.
On Thu, Apr 23, 2009 at 05:53:03PM -0000, Leonard Richardson wrote: field_cache and the vent. The OME modified date_last_updated, but field_cache. So the old /bugs.launchpad .net/bugs/ 336866 append( tag) append( tag) new-bugs. py", line 175, in <module> tag("needs- lspci-vvnn" ) bryce/src/ Arsenal/ arsenal/ contrib/ arsenal_ lib.py" , line 125, in append_tag bdist.linux- x86_64/ egg/launchpadli b/resource. py", line 489, in lp_save bdist.linux- x86_64/ egg/launchpadli b/_browser. py", line 266, in patch bdist.linux- x86_64/ egg/launchpadli b/_browser. py", line 212, in _request errors. HTTPError: HTTP Error 412: Precondition Failed
> The culprit is a combination of the unmarshalled_
> ObjectModifiedE
> lazr.restful didn't hear about it, and only removed the fields the
> client modified from unmarshalled_
> date_last_updated stays in there.
>
> I have a fix but since the lazr.restful example service doesn't use OMEs
> at all, a proper test will take a little while.
>
> --
> When adding tag or updating description, lp_save() gives "HTTP Error 412: Precondition Failed"
> https:/
> You received this bug notification because you are a direct subscriber
> of the bug.
>
> Status in Launchpad web services client library: Triaged
>
> Bug description:
> Getting this error consistently when attempting to add a tag using the following code (which worked last time I ran it a few weeks ago).
>
> if not tag in bug.tags:
> #bug.tags.
> # Workaround bug #254901
> tag_list = bug.tags
> tag_list.
> bug.tags = tag_list
>
> print " ---> Tagged ",tag
> bug.lp_save()
>
> I also tested with the commented line instead of the workaround code; same error.
>
> Traceback (most recent call last):
> File "./process-
> bug.append_
> File "/home/
> self.bug.lp_save()
> File "build/
> File "build/
> File "build/
> launchpadlib.