Cannot upload files with maas-cli
Bug #1187826 reported by
Gavin Panella
This bug affects 4 people
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
MAAS |
Fix Released
|
High
|
Gavin Panella | ||
1.5 |
Fix Released
|
High
|
Gavin Panella | ||
maas (Ubuntu) |
New
|
Undecided
|
Unassigned |
Bug Description
{{{
$ bin/maascli login foo http://
$ bin/maascli foo files add filename=fred -d < my_file
400 BAD REQUEST
Transfer-
File not supplied
}}}
(The same happens when passing "file=$(< my_file)".)
This is because the server is looking at request.FILES, and maas-cli is not sending anything that'll get put in there. MAAS ought to learn how to do this.
Related branches
lp:~allenap/maas/cli-upload-files--bug-1187826
- Jeroen T. Vermeulen (community): Approve
-
Diff: 366 lines (+149/-50)4 files modifiedsrc/apiclient/multipart.py (+21/-1)
src/apiclient/tests/test_multipart.py (+14/-11)
src/maascli/api.py (+50/-15)
src/maascli/tests/test_api.py (+64/-23)
lp:~allenap/maas/cli-upload-files--bug-1187826--1.5
- Gavin Panella (community): Approve
-
Diff: 366 lines (+149/-50)4 files modifiedsrc/apiclient/multipart.py (+21/-1)
src/apiclient/tests/test_multipart.py (+14/-11)
src/maascli/api.py (+50/-15)
src/maascli/tests/test_api.py (+64/-23)
Changed in maas: | |
milestone: | none → 13.10 |
Changed in maas: | |
milestone: | 13.10 → 14.04 |
tags: | added: landscape |
Changed in maas: | |
status: | Triaged → In Progress |
assignee: | nobody → Gavin Panella (allenap) |
Changed in maas: | |
milestone: | 14.04 → none |
Changed in maas: | |
status: | In Progress → Fix Committed |
Changed in maas: | |
milestone: | none → 14.10 |
Changed in maas: | |
status: | Fix Committed → Fix Released |
milestone: | 14.10 → none |
To post a comment you must log in.
Workaround: http:// blog.allenap. me/2013/ 06/workaround- for-uploading- files-to- maas.html