maas api "device update <id>" requires setting parent= in addition to hostname=, but it's not documented as required

Bug #1440998 reported by Dimiter Naydenov
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
MAAS
Fix Released
High
Mike Pontillo

Bug Description

Using the same scenario described in bug 1440994, I've tried running:

$ maas maas-user device update node-a13335fa-dcf1-11e4-82db-525400355a63 hostname=juju-machine-0-lxc-0-newhost

But despite the documentation of the "update" method only mentioning "hostname=" as accepted argument it appears "parent=" is also required. Response I got:

{"parent": ["Select a valid choice. That choice is not one of the available choices."]}

Trying again with parent=foo reports the same error (as expected). Trying with "parent=<system-id-of-another-ready-node>" works: http://paste.ubuntu.com/10758933/

It will help to document "parent=" as accepted argument to "device update", but also make it optional.

Tags: api doc juju-net

Related branches

Raphaël Badin (rvb)
Changed in maas:
milestone: none → 1.8.0
status: New → Triaged
Changed in maas:
assignee: nobody → Mike Pontillo (mpontillo)
Raphaël Badin (rvb)
Changed in maas:
importance: Undecided → High
Revision history for this message
Mike Pontillo (mpontillo) wrote :

Confirmed.

Devices that have no parent work as expected, but devices that previously had a parent exhibit this behavior.

Changed in maas:
status: Triaged → Fix Committed
Revision history for this message
Dimiter Naydenov (dimitern) wrote :

Confirmed as fixed in 1.8.0~beta2+bzr3814-0ubuntu1~trusty1 - parent is no longer required.

Changed in maas:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.