Opened 3 years ago

Last modified 18 months ago

#19179 new defect

Refactor functions that handle 'packages' in consensus/votes

Reported by: asn Owned by:
Priority: Medium Milestone: Tor: unspecified
Component: Core Tor/Tor Version:
Severity: Minor Keywords: tor-dirauth, refactor, maybe-obsolete-code
Cc: Actual Points:
Parent ID: Points: 1
Reviewer: Sponsor: SponsorS-can

Description

This is a side issue of #18840.

The code managing packages for consensuses and votes seems to be of particularly low quality.

See compute_consensus_package_lines() doing ad-hoc parsing. And see validate_recommended_package_line() doing more ad-hoc parsing and having wrong return value patterns. Fortunately, both of them are weakly tested in the unittests.

Maybe we should refactor and add more testing for these funcs?

Child Tickets

Change History (7)

comment:1 Changed 3 years ago by nickm

Keywords: 029-proposed added
Sponsor: SponsorS-can

comment:2 Changed 2 years ago by nickm

Keywords: 029-nickm-says-no added

comment:3 Changed 2 years ago by teor

Milestone: Tor: 0.2.???Tor: 0.3.???

Milestone renamed

comment:4 Changed 2 years ago by nickm

Keywords: tor-03-unspecified-201612 added
Milestone: Tor: 0.3.???Tor: unspecified

Finally admitting that 0.3.??? was a euphemism for Tor: unspecified all along.

comment:5 Changed 19 months ago by nickm

Keywords: tor-03-unspecified-201612 removed

Remove an old triaging keyword.

comment:6 Changed 19 months ago by nickm

Keywords: 029-nickm-says-no removed

comment:7 Changed 18 months ago by nickm

Keywords: refactor maybe-obsolete-code added; 029-proposed removed

If we don't wind up using this functionality some time in the next 12 months, we should just throw it away.

Note: See TracTickets for help on using tickets.