meejah / txtorcon

Twisted-based asynchronous Tor control protocol implementation. Includes unit-tests, examples, state-tracking code and configuration abstraction.
http://fjblvrw2jrxnhtg67qpbzi45r7ofojaoo3orzykesly2j3c2m3htapid.onion/
MIT License
250 stars 72 forks source link

Accept `Dependent` for Tor >= 0.3.0.2-alpha #219

Closed felipedau closed 7 years ago

felipedau commented 7 years ago

As I was reading the specs recently, I noticed the following note and thought it wouldn't hurt to add this other conditional.

Note: The incorrect spelling "Dependant" was used from the time this key was introduced in Tor 0.1.1.4-alpha until it was corrected in Tor 0.3.0.2-alpha. It is recommended that clients accept both spellings.

Could this be useful?

codecov-io commented 7 years ago

Codecov Report

Merging #219 into master will not change coverage. The diff coverage is 100%.

@@           Coverage Diff           @@
##           master     #219   +/-   ##
=======================================
  Coverage   99.88%   99.88%           
=======================================
  Files          20       20           
  Lines        3566     3566           
=======================================
  Hits         3562     3562           
  Misses          4        4
Impacted Files Coverage Δ
txtorcon/torconfig.py 100% <100%> (ø) :white_check_mark:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 959f6ac...be8bcc2. Read the comment docs.

coveralls commented 7 years ago

Coverage Status

Coverage remained the same at 99.888% when pulling be8bcc2cf18b632cd2ddc894d2f6cb6f5cfdf128 on felipedau:dependent-type into 959f6ac921ece6088b17680c48104fe9e2482d2e on meejah:master.

meejah commented 7 years ago

Yeah, your fix is probably good. See also: https://trac.torproject.org/projects/tor/ticket/20956#comment:25

meejah commented 7 years ago

(personally I think they should just keep the original spelling to avoid breaking things, but hey ;)

felipedau commented 7 years ago

See also: https://trac.torproject.org/projects/tor/ticket/20956#comment:25

Oh thanks, very interesting!

(personally I think they should just keep the original spelling to avoid breaking things, but hey ;)

I agree - good thing it is very easy to fix. A bigger problem is when an expected LineList becomes Depend[ae]nt :P

Thanks!