trailing whitespace in IP addresses causes error #305

Closed
bitprophet opened this Issue Aug 19, 2011 · 2 comments

1 participant

@bitprophet
Member

Description

Trailing whitespace in IP address values causes name lookup failure, which is counterintuitive and should be cared for. NB: leading whitespace doesn't seem to matter.

Test case:

pantouflejr:tmp mbravo$ cat fabfile.py
from fabric.api import *

env.hosts = ['127.0.0.1 ']

def test():
    run('uname -r');
pantouflejr:tmp mbravo$ fab test
[127.0.0.1 ] Executing task 'test'
[127.0.0.1 ] run: uname -r

Fatal error: Name lookup failed for 127.0.0.1 

Aborting.
pantouflejr:tmp mbravo$ 

Tested with fabric 0.9.4


Originally submitted by **** (mbravo) on 2011-03-07 at 05:33pm EST


Closed as Done on 2011-03-20 at 05:00pm EDT

@bitprophet bitprophet was assigned Aug 19, 2011
@bitprophet
Member

Rick Harding (mitechie) posted:


Submitted a patch in the github fork: https://github.com/mitechie/fabric/tree/feature/strip_hostnames


on 2011-03-13 at 10:21pm EDT

@bitprophet
Member

Jeff Forcier (bitprophet) posted:


Applied in changeset commit:41ba00310789f598dc3a69ed9cc61d55f90a53e2.


on 2011-03-20 at 05:00pm EDT

@bitprophet bitprophet closed this Aug 19, 2011
@richid richid pushed a commit to richid/fabric that referenced this issue Aug 1, 2012
@bitprophet bitprophet Fixes #305 - Strip spaces from hostnames.
Rework of Rick Hardin's master-based patch to fit 0.9.
41ba003
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment