With a proxy, snap info endpoint fails if "revision" not in requested fields
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Snap Store Server |
Fix Released
|
Low
|
Unassigned |
Bug Description
Given a store proxy.
When a call is made to /v2/snap[
(ie. any set of fields that does not include 'revision')
Then the a 200 response is expected with the specified fields,
but instead we get an error response.
I'm unhelpfully not specifying the error because I haven't reproduced this against a running server, only seen it happen in the tests:
eg. in devicegw source, modify the assignment of 'fields' at the start of OverrideWithLoc
```
ERROR: test_specific_
snapdevicegw.
-------
testtools.
File "/home/
response = self.do_
File "/home/
response = self.fixture.
... [snip] ...
File "/home/
results = _override_
File "/home/
snap_name, snap_id, snap_ident_data, channel_map)
File "/home/
upstream_
File "/home/
'revision': up_item[
KeyError: 'revision'
```
The source there indexes by 'revision', instead of using .get() as is done for other fields on adjacent lines, but a quick skim of the source there looks nontrivial to fix, so I'm filing a bug for now.
I'm a newhire, please shout at me if this bug report is lacking in some way. Thanks.
description: | updated |
description: | updated |
This is fixed. It was tracked in a duplicate of this bug at https:/ /bugs.launchpad .net/snapstore- snap/+bug/ 1942892