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

Refactor sshconfig #378

Closed
wants to merge 3 commits into
base: master
from

Conversation

Projects
None yet
3 participants
@lndbrg
Contributor

lndbrg commented Aug 19, 2014

Be more pythonic.

lndbrg added some commits Aug 19, 2014

Use [key] = value syntax rather than .update().
This brings the code more inline with the code around it.
Change signature to (haystack, needle).
This brings the code more inline with the code around it and also
the python stdlib in general.
@coveralls

This comment has been minimized.

coveralls commented Aug 19, 2014

Coverage Status

Coverage increased (+0.05%) when pulling 3e94fc8 on lndbrg:refactor-sshconfig into d8a71fc on paramiko:master.

@bitprophet

This comment has been minimized.

Member

bitprophet commented Aug 25, 2014

The change to _allowed doesn't seem clearly better or worse. Is there an idiom I'm missing re: why func(list_arg, single_value-arg) is better than the inverse?

@lndbrg

This comment has been minimized.

Contributor

lndbrg commented Aug 26, 2014

It's for consistency's sake. Both the code around it and Python's stdlib
usually takes the haystack before the needle. It's an underscore method so
it shouldn't be used by any other code anyway.
On Aug 26, 2014 1:33 AM, "Jeff Forcier" notifications@github.com wrote:

The change to _allowed doesn't seem clearly better or worse. Is there an
idiom I'm missing re: why func(list_arg, single_value-arg) is better than
the inverse?


Reply to this email directly or view it on GitHub
#378 (comment).

@bitprophet

This comment has been minimized.

Member

bitprophet commented Aug 26, 2014

That's fair, thanks :)

@bitprophet

This comment has been minimized.

Member

bitprophet commented Aug 26, 2014

Looks like it can't be automerged and I kinda wanted it have it back in older branch lines anyway, so I will manually apply.

dkhapun pushed a commit to cyberx-labs/paramiko that referenced this pull request Jun 7, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment