-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to destroy keypair #2586
Comments
@krames - could you take a look? Thanks! |
@bfosberry How did you create the key? I presume you did it through the key_pairs collection? Something like? c = Fog::Compute.new(...)
c.key_pairs.create(:name => "MYNAME") |
Yep, exactly like that. I couldn't find any difference between keys that could be deleted and keys that could not |
So far, I've tried this with fog HEAD and with fog 1.18.0 without any problem. Granted, I'm on Ruby 2.0. I tried building the same version of Ruby that you're running but the build failed. :-/ |
That said, judging by the 400, I suspect it's a server-side problem. I'll start asking questions here. |
@bfosberry I checked out delete_keypair.rb to look for anything obvious in fog. After all, a 400 could possibly be due to a malformed request. However, from inspection, I don't see how this is likely to be the case. Is I've reached out to our cloud server team too. |
The names I've been giving have upper and lowercase alphanumeric On Tue, Jan 21, 2014 at 1:35 PM, Evan Light notifications@github.comwrote:
|
Btw Im using fog 1.18 and 1.9.3, I'll try using 2.0 when I get a sec On Tue, Jan 21, 2014 at 2:30 PM, Brendan Fosberry <
|
I don't suppose it's the key pairs with spaces in their names that are causing the 400s? I just tried sending an HTTP request using excon, the HTTP library underlying fog, and it doesn't automatically URI encode the path. That could be the problem. Begs the question whether fog-rackspace should be escaping them. As the parameter is a "name", it seems reasonable... |
@bfosberry Try sourcing your fog from here instead of from rubygems. FYI, I created a keypair with a whitespace. That worked. Then I tried to delete it. 400. After this patch, no problem. I suspect this will fix the problem you saw. Sorry about the trouble! |
I'll give that a go, thanks! I plan on standardizing my naming regardless, but its good to be aware of this. Will this patch let me delete the keypair, or prevent me from creating un-deletable keypairs? thanks for the switch response! |
@bfosberry Key pairs with whitespaces will work now. They always should have. That is, we let users create key pairs with white spaces so we should be letting you delete them. Otherwise, shame on us. ;-) |
@bfosberry thanks for the detailed report, should be fixed in the next release. |
As always, you guys are kickass
|
@bfosberry Considering I've been fighting a head cold this week, that comment just made my day. 😊 |
Thanks @elight! |
* 'master' of github.com:fog/fog: (58 commits) make disassociate_address mock idempotent, by not requiring instance data Fixes fog#2586 A hack to fix the Claim#messages= hack on 1.8.7. Replace the JSON round-trip with #stringify. Missed a chance to use queue.claim!. Include the oldest and newest message in stats. I guess there isn't really a better place. Don't use `&:to_h` style enumerations. Only extend the TTL of a MockMessage. Make the delete_message mock consistent. Yep, just did that. Er, actually enable queues_tests, too. Refactor PATH_BASE into a constant. Enable the queues_tests in mocking mode. Er, *actually* enable the messages_tests for mocks. Enable the queue_tests in mocking mode. Enable the messages_tests in mocking mode. Enable the message_tests in mocking mode. Enable the claims_tests in mocking mode. Enable model tests for Claims. ...
I'm sure Im doing something wrong here, but everything is auto-generated so not sure what this is :P
The text was updated successfully, but these errors were encountered: