maas crashes because of a missing power_type, even though I provided one
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
MAAS |
Fix Released
|
Critical
|
Julian Edwards | ||
1.5 |
Fix Released
|
Critical
|
Julian Edwards | ||
maas (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned | ||
Trusty |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
I get:
ERROR 2014-04-09 07:56:07,314 maasserver #######
ERROR 2014-04-09 07:56:07,315 maasserver Traceback (most recent call last):
File "/usr/lib/
response = wrapped_
File "/usr/lib/
response = func(*args, **kwargs)
File "/usr/lib/
result = self.error_
File "/usr/lib/
result = meth(request, *args, **kwargs)
File "/usr/lib/
return function(self, request, *args, **kwargs)
File "/usr/lib/
node = create_
File "/usr/lib/
if form.is_valid():
File "/usr/lib/
valid = super(WithMACAd
File "/usr/lib/
is_valid = super(NodeForm, self).is_valid()
File "/usr/lib/
return self.is_bound and not bool(self.errors)
File "/usr/lib/
self.
File "/usr/lib/
super(
File "/usr/lib/
self.
File "/usr/lib/
self.
File "/usr/lib/
no_power_type = cleaned_
KeyError: u'power_type'
When I do the following:
node_data = {
# TODO: use cluster_id when maas changes land
}
resp = client.
This used to work in the r1977 maas that was in trusty (and lots of previous maases), but does not work in the 2227 maas that is there now, so I suppose it is a regression.
[Impact]
* Fix regression of raised error when power_type not properly checked for existence
[Testcase]
* included testcase test_POST_
[Regression Potential]
* Minimal, will allow power_type to be properly detected as existent or not, whether key is available or not.
Related branches
- Julian Edwards (community): Approve
-
Diff: 64 lines (+29/-1)2 files modifiedsrc/maasserver/forms.py (+1/-1)
src/maasserver/tests/test_api_nodes.py (+28/-0)
- Raphaël Badin (community): Approve
-
Diff: 64 lines (+29/-1)2 files modifiedsrc/maasserver/forms.py (+1/-1)
src/maasserver/tests/test_api_nodes.py (+28/-0)
Changed in maas: | |
status: | Triaged → Incomplete |
Changed in maas: | |
status: | Incomplete → Triaged |
Changed in maas: | |
assignee: | nobody → Julian Edwards (julian-edwards) |
status: | Triaged → In Progress |
milestone: | none → 14.10 |
Changed in maas: | |
status: | In Progress → Fix Committed |
Changed in maas: | |
milestone: | 1.6.0 → none |
Changed in maas: | |
status: | Fix Committed → Fix Released |
Changed in maas (Ubuntu): | |
status: | New → Fix Released |
copy of pserv.log as per irc: http:// paste.ubuntu. com/7226244/