Opened 6 years ago

Closed 6 years ago

#6257 defect closed fixed (fixed)

twisted.conch.client.knownhosts has many coding standard violations

Reported by: Jean-Paul Calderone Owned by: Jean-Paul Calderone
Priority: normal Milestone:
Component: conch Keywords:
Cc: z3p, Thijs Triemstra Branch: branches/knownhosts-standards-6257
branch-diff, diff-cov, branch-cov, buildbot
Author: exarkun

Description

As reported by twistedchecker. Most -- or, who knows, perhaps even all -- of these should be fixed.

Change History (10)

comment:1 Changed 6 years ago by DefaultCC Plugin

Cc: z3p added

comment:2 Changed 6 years ago by Jean-Paul Calderone

Author: exarkun
Branch: branches/knownhosts-standards-6257

(In [36815]) Branching to 'knownhosts-standards-6257'

comment:3 Changed 6 years ago by Jean-Paul Calderone

Keywords: review added
Owner: Jean-Paul Calderone deleted

I fixed many, but not all. I think some of the remaining errors may not make sense. For convenience, here they are as reported by a twistedchecker build of the branch:

************* Module twisted.conch.client.knownhosts
W9207: 75,0:_BaseEntry: Missing a blank line before epytext markups
W9207:111,0:PlainEntry: Missing a blank line before epytext markups
W9202:206,4:UnparsedEntry.matchesHost: Missing epytext markup @param for argument "hostname"
W9204:206,4:UnparsedEntry.matchesHost: Missing epytext markup @return for return value
W9202:213,4:UnparsedEntry.matchesKey: Missing epytext markup @param for argument "key"
W9204:213,4:UnparsedEntry.matchesKey: Missing epytext markup @return for return value
W9208:419,16:KnownHostsFile.verifyHostKey.gotHasKey.promptResponse: Missing docstring

Complete build results

comment:4 Changed 6 years ago by Thijs Triemstra

Keywords: review removed
Owner: set to Jean-Paul Calderone
  1. @rtype is missing for _extractCommon
  2. @param opener in ConsoleUI is missing a @type opener
  3. the empty line on 405 isn't needed
  4. @type should be @rtype on line 452

Please merge after that, thanks.

comment:5 Changed 6 years ago by Jean-Paul Calderone

(In [36854]) Address most review feedback

refs #6257

comment:6 Changed 6 years ago by Jean-Paul Calderone

Cc: Thijs Triemstra added

@param opener in ConsoleUI is missing a @type opener

There's neither a type nor an interface that could be put there. Do you have a suggestion?

comment:7 Changed 6 years ago by Jean-Paul Calderone

Keywords: review added
Owner: Jean-Paul Calderone deleted

comment:8 in reply to:  6 Changed 6 years ago by Glyph

Keywords: review removed
Owner: set to Jean-Paul Calderone

Replying to exarkun:

@param opener in ConsoleUI is missing a @type opener

There's neither a type nor an interface that could be put there. Do you have a suggestion?

"callable taking no arguments, returning L{None}"

Other than that this looks fine to me; please land.

comment:9 Changed 6 years ago by Jean-Paul Calderone

(In [36996]) some stuff for the @type of opener

refs #6257

comment:10 Changed 6 years ago by Jean-Paul Calderone

Resolution: fixed
Status: newclosed

(In [36997]) Merge knownhosts-standards-6257

Author: exarkun Reviewer: thijs, glyph Fixes: #6257

Improve twisted.conch.client.knownhosts compliance with API documentation standards.

Note: See TracTickets for help on using tickets.