[2.1] 400 BAD REQUEST: Unrecognised signature: method=GET op=is_registered

Bug #1657471 reported by Nobuto Murata
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
MAAS
Fix Released
High
Blake Rouse

Bug Description

MAAS API client has "machines is-registered" subcommand, but it does not work with "400 BAD REQUEST". "method=GET op=is_registered" is not in the API document either:
https://maas.ubuntu.com/docs2.1/api.html

$ maas "$PROFILE" machines is-registered mac_address='XX:XX:XX:XX:XX:XX' -d
400 BAD REQUEST

         Connection: close
       Content-Type: text/plain; charset=utf-8
               Date: Wed, 18 Jan 2017 14:07:37 GMT
             Server: TwistedWeb/16.0.0
             Status: 400
  Transfer-Encoding: chunked
               Vary: Cookie
    X-Frame-Options: SAMEORIGIN

Unrecognised signature: method=GET op=is_registered

$ apt policy maas
maas:
  Installed: 2.1.2+bzr5555-0ubuntu1~16.04.1
  Candidate: 2.1.2+bzr5555-0ubuntu1~16.04.1
  Version table:
 *** 2.1.2+bzr5555-0ubuntu1~16.04.1 500
        500 http://ppa.launchpad.net/maas/stable/ubuntu xenial/main amd64 Packages
        500 http://ppa.launchpad.net/maas/stable/ubuntu xenial/main i386 Packages
        100 /var/lib/dpkg/status

Related branches

Nobuto Murata (nobuto)
summary: - 400 BAD REQUEST: Unrecognised signature: method=GET op=is_registered
+ [2.1] 400 BAD REQUEST: Unrecognised signature: method=GET
+ op=is_registered
Revision history for this message
Brendan Donegan (brendan-donegan) wrote :

That's really strange, since in theory the CLI is generated from the API

Changed in maas:
status: New → Confirmed
importance: Undecided → Medium
Changed in maas:
importance: Medium → High
milestone: none → 2.2.0rc2
Revision history for this message
Blake Rouse (blake-rouse) wrote :

The issue is that is_registered is on the anonymous handler only. It should also be on the signed in handler as well.

Changed in maas:
status: Confirmed → In Progress
assignee: nobody → Blake Rouse (blake-rouse)
Changed in maas:
status: In Progress → Fix Committed
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.