Actions
Bug #976
closedNon-existent bucket error code should be NoSuchBucket, not NoSuchKey
Status:
Resolved
Priority:
Normal
Assignee:
-
Target version:
-
% Done:
0%
Source:
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):
Description
s3 test:
def test_bucket_notexist(): name = '{prefix}foo'.format(prefix=prefix) print 'Trying bucket {name!r}'.format(name=name) e = assert_raises(boto.exception.S3ResponseError, s3.main.get_bucket, name) eq(e.status, 404) eq(e.reason, 'Not Found') eq(e.error_code, 'NoSuchBucket')
fails on rgw with
$ S3TEST_CONF=tv.conf ./virtualenv/bin/nosetests test_s3:test_bucket_notexist F ====================================================================== FAIL: test_s3.test_bucket_notexist ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/tv/src/s3-tests.git/virtualenv/lib/python2.6/site-packages/nose/case.py", line 187, in runTest self.test(*self.arg) File "/home/tv/src/s3-tests.git/test_s3.py", line 195, in test_bucket_notexist eq(e.error_code, 'NoSuchBucket') File "/home/tv/src/s3-tests.git/virtualenv/lib/python2.6/site-packages/nose/tools.py", line 31, in eq_ assert a == b, msg or "%r != %r" % (a, b) AssertionError: u'NoSuchKey' != 'NoSuchBucket' -------------------- >> begin captured stdout << --------------------- Trying bucket 'test-tv-1rno38ai3kbm83a9ynpva-foo' --------------------- >> end captured stdout << ---------------------- -------------------- >> begin captured logging << -------------------- boto: DEBUG: path=/ boto: DEBUG: auth_path=/ boto: DEBUG: Canonical: GET Tue, 05 Apr 2011 00:03:23 GMT / boto: DEBUG: Method: GET boto: DEBUG: Path: / boto: DEBUG: Data: boto: DEBUG: Headers: {'Date': 'Tue, 05 Apr 2011 00:03:23 GMT', 'Content-Length': '0', 'Authorization': 'AWS TKKZ1DX83O7ZCTWHE0YD:DQLFVUlNKEp+fpm+wPhcGEIuTOA=', 'User-Agent': 'Boto/2.0b4 (linux2)'} boto: DEBUG: Host: localhost:7280 boto: DEBUG: establishing HTTP connection boto: DEBUG: path=/ boto: DEBUG: auth_path=/ boto: DEBUG: Canonical: GET Tue, 05 Apr 2011 00:03:23 GMT / boto: DEBUG: Method: GET boto: DEBUG: Path: / boto: DEBUG: Data: boto: DEBUG: Headers: {'Date': 'Tue, 05 Apr 2011 00:03:23 GMT', 'Content-Length': '0', 'Authorization': 'AWS O54XVCC9MQ9Q72TWP5Y1:XONqyQSsenhJeR63gY8nm2Q2UDw=', 'User-Agent': 'Boto/2.0b4 (linux2)'} boto: DEBUG: Host: localhost:7280 boto: DEBUG: establishing HTTP connection boto: DEBUG: path=/test-tv-1rno38ai3kbm83a9ynpva-foo/ boto: DEBUG: auth_path=/test-tv-1rno38ai3kbm83a9ynpva-foo/ boto: DEBUG: path=/test-tv-1rno38ai3kbm83a9ynpva-foo/?&max-keys=0 boto: DEBUG: auth_path=/test-tv-1rno38ai3kbm83a9ynpva-foo/?&max-keys=0 boto: DEBUG: Canonical: GET Tue, 05 Apr 2011 00:03:23 GMT /test-tv-1rno38ai3kbm83a9ynpva-foo/ boto: DEBUG: Method: GET boto: DEBUG: Path: /test-tv-1rno38ai3kbm83a9ynpva-foo/?&max-keys=0 boto: DEBUG: Data: boto: DEBUG: Headers: {'Date': 'Tue, 05 Apr 2011 00:03:23 GMT', 'Content-Length': '0', 'Authorization': 'AWS O54XVCC9MQ9Q72TWP5Y1:EgTdfY5JQIs5zQkMid6XyGApUYk=', 'User-Agent': 'Boto/2.0b4 (linux2)'} boto: DEBUG: Host: localhost:7280 boto: DEBUG: <?xml version="1.0" encoding="UTF-8"?><Error><Code>NoSuchKey</Code></Error> --------------------- >> end captured logging << --------------------- ---------------------------------------------------------------------- Ran 1 test in 0.059s FAILED (failures=1)
Updated by Sage Weil about 13 years ago
- Translation missing: en.field_position set to 9
Updated by Yehuda Sadeh about 13 years ago
- Status changed from New to Resolved
Fixed at commit:fd0290a00ac76bbfe15bb12ee35e54dc58cf074f.
Updated by Sage Weil about 13 years ago
- Target version changed from v0.28 to v0.27
Updated by Sage Weil about 13 years ago
- Translation missing: en.field_story_points set to 1
- Translation missing: en.field_position deleted (
12) - Translation missing: en.field_position set to 5
Updated by John Spray over 6 years ago
- Project changed from Ceph to rgw
- Category deleted (
22) - Target version deleted (
v0.27)
Bulk reassign of radosgw category to RGW project.
Actions