Merge lp:~chmouel/burrow/lp771506 into lp:burrow

Proposed by Chmouel Boudjnah
Status: Merged
Approved by: Eric Day
Approved revision: 14
Merged at revision: 15
Proposed branch: lp:~chmouel/burrow/lp771506
Merge into: lp:burrow
Diff against target: 14 lines (+2/-2)
1 file modified
burrow/frontend/wsgi.py (+2/-2)
To merge this branch: bzr merge lp:~chmouel/burrow/lp771506
Reviewer Review Type Date Requested Status
Eric Day (community) Approve
Review via email: mp+59138@code.launchpad.net

Commit message

Cast to integer the default_ttl and the hide values.

To post a comment you must log in.
Revision history for this message
Eric Day (eday) wrote :

Good catch! The issue is actually only in the WSGI frontend module, as the API into the backend modules should be passing ints already. The default_ttl in the WSGI module is the root of the issue, as that is what is causing the str value. Instead of putting int()s around all those places in the backend modules, we can instead put just two around the initial default_ttl values being set in the wsgi module.

review: Needs Fixing
Revision history for this message
Chmouel Boudjnah (chmouel) wrote :

Ok, I have updated the branch with your comment, not being a launchpad/bzr
wizzard I have tried a bzr uncommit;revert;$EDIT;commit;push --overwrite
hope I haven't screwed anything.

Cheers,
Chmouel.

On Wed, Apr 27, 2011 at 12:39 AM, Eric Day <email address hidden> wrote:

> Review: Needs Fixing
> Good catch! The issue is actually only in the WSGI frontend module, as the
> API into the backend modules should be passing ints already. The default_ttl
> in the WSGI module is the root of the issue, as that is what is causing the
> str value. Instead of putting int()s around all those places in the backend
> modules, we can instead put just two around the initial default_ttl values
> being set in the wsgi module.
> --
> https://code.launchpad.net/~chmouel/burrow/lp771506/+merge/59138
> You are the owner of lp:~chmouel/burrow/lp771506.
>

Revision history for this message
Eric Day (eday) wrote :

lgtm

That process you mentioned works fine, or you could just delete the old branch, branch new again from trunk, and bzr push --overwrite the new changes.

review: Approve
Revision history for this message
OpenStack Infra (hudson-openstack) wrote :
Download full text (7.6 KiB)

The attempt to merge lp:~chmouel/burrow/lp771506 into lp:burrow failed. Below is the output from the failed tests.

running test
running egg_info
creating burrow.egg-info
writing burrow.egg-info/PKG-INFO
writing top-level names to burrow.egg-info/top_level.txt
writing dependency_links to burrow.egg-info/dependency_links.txt
writing manifest file 'burrow.egg-info/SOURCES.txt'
reading manifest file 'burrow.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
warning: no files found matching 'ChangeLog'
writing manifest file 'burrow.egg-info/SOURCES.txt'
running build_ext

test_account (test.frontend.test_wsgi.TestWSGIMemory) ... ok
test_message (test.frontend.test_wsgi.TestWSGIMemory) ... ok
test_message_delete_limit (test.frontend.test_wsgi.TestWSGIMemory) ... ok
test_message_delete_limit_marker (test.frontend.test_wsgi.TestWSGIMemory) ... ok
test_message_delete_marker (test.frontend.test_wsgi.TestWSGIMemory) ... ok
test_message_get_limit (test.frontend.test_wsgi.TestWSGIMemory) ... ok
test_message_get_limit_marker (test.frontend.test_wsgi.TestWSGIMemory) ... ok
test_message_get_marker (test.frontend.test_wsgi.TestWSGIMemory) ... ok
test_message_hide (test.frontend.test_wsgi.TestWSGIMemory) ... ok
test_message_post (test.frontend.test_wsgi.TestWSGIMemory) ... ok
test_message_post_limit (test.frontend.test_wsgi.TestWSGIMemory) ... ok
test_message_post_limit_marker (test.frontend.test_wsgi.TestWSGIMemory) ... ok
test_message_post_marker (test.frontend.test_wsgi.TestWSGIMemory) ... ok
test_message_post_wait (test.frontend.test_wsgi.TestWSGIMemory) ... ok
test_message_post_wait_queue (test.frontend.test_wsgi.TestWSGIMemory) ... ok
test_message_put (test.frontend.test_wsgi.TestWSGIMemory) ... ok
test_message_put_wait (test.frontend.test_wsgi.TestWSGIMemory) ... ok
test_message_put_wait_cleanup (test.frontend.test_wsgi.TestWSGIMemory) ... ok
test_message_put_wait_overwrite (test.frontend.test_wsgi.TestWSGIMemory) ... ok
test_message_ttl (test.frontend.test_wsgi.TestWSGIMemory) ... ok
test_queue (test.frontend.test_wsgi.TestWSGIMemory) ... ok
test_account (test.frontend.test_wsgi.TestWSGISQLite) ... ok
test_message (test.frontend.test_wsgi.TestWSGISQLite) ... ok
test_message_delete_limit (test.frontend.test_wsgi.TestWSGISQLite) ... ok
test_message_delete_limit_marker (test.frontend.test_wsgi.TestWSGISQLite) ... ok
test_message_delete_marker (test.frontend.test_wsgi.TestWSGISQLite) ... ok
test_message_get_limit (test.frontend.test_wsgi.TestWSGISQLite) ... ok
test_message_get_limit_marker (test.frontend.test_wsgi.TestWSGISQLite) ... ok
test_message_get_marker (test.frontend.test_wsgi.TestWSGISQLite) ... ok
test_message_hide (test.frontend.test_wsgi.TestWSGISQLite) ... ok
test_message_post (test.frontend.test_wsgi.TestWSGISQLite) ... ok
test_message_post_limit (test.frontend.test_wsgi.TestWSGISQLite) ... ok
test_message_post_limit_marker (test.frontend.test_wsgi.TestWSGISQLite) ... ok
test_message_post_marker (test.frontend.test_wsgi.TestWSGISQLite) ... ok
test_message_post_wait (test.frontend.test_wsgi.TestWSGISQLite) ... ok
test_message_post_wait_queue (test.frontend.test_wsgi.TestWSGISQLite) ... ok
test_message_put (test.frontend.test_wsgi.T...

Read more...

Revision history for this message
Chmouel Boudjnah (chmouel) wrote :

Is there any reason why this is fail under hudson and not on my dev box :

http://paste.openstack.org/show/1293/

Thanks,
Chmouel.

On Thu, Apr 28, 2011 at 6:18 AM, OpenStack Hudson <email address hidden>wrote:

> The proposal to merge lp:~chmouel/burrow/lp771506 into lp:burrow has been
> updated.
>
> Status: Approved => Needs review
>
> For more details, see:
> https://code.launchpad.net/~chmouel/burrow/lp771506/+merge/59138
> --
> https://code.launchpad.net/~chmouel/burrow/lp771506/+merge/59138
> You are the owner of lp:~chmouel/burrow/lp771506.
>

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'burrow/frontend/wsgi.py'
2--- burrow/frontend/wsgi.py 2011-04-24 22:47:02 +0000
3+++ burrow/frontend/wsgi.py 2011-04-27 19:14:22 +0000
4@@ -68,8 +68,8 @@
5
6 def __init__(self, config, backend):
7 super(Frontend, self).__init__(config, backend)
8- self.default_ttl = self.config.get('default_ttl', DEFAULT_TTL)
9- self.default_hide = self.config.get('default_hide', DEFAULT_HIDE)
10+ self.default_ttl = int(self.config.get('default_ttl', DEFAULT_TTL))
11+ self.default_hide = int(self.config.get('default_hide', DEFAULT_HIDE))
12 mapper = routes.Mapper()
13 mapper.connect('/', action='root')
14 mapper.connect('/v1.0', action='version')

Subscribers

People subscribed via source and target branches