[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [tor-bugs] #6417 [Stem]: Controller wrapper method for USEFEATURE messages



#6417: Controller wrapper method for USEFEATURE messages
--------------------+-------------------------------------------------------
 Reporter:  neena   |          Owner:  neena       
     Type:  defect  |         Status:  needs_review
 Priority:  normal  |      Milestone:              
Component:  Stem    |        Version:              
 Keywords:          |         Parent:              
   Points:          |   Actualpoints:              
--------------------+-------------------------------------------------------
Changes (by neena):

  * status:  needs_revision => needs_review


Comment:

 Replying to [comment:3 atagar]:

 > Lets not copy the control-spec. I agree that it's nice to have this in
 our documentation, but if we do this then we get into the business of
 mirroring this section (or getting stale). Maybe just list the options
 with a short summary and mention that users can read the control-spec for
 details?
 Fixed. Didn't mention the control-spec, I think this should suffice.

 > Usually I'd ask for these requirements to be added to version.py (and
 spotted that you did for FEATURE_VERBOSENAMES), but 0.1.2.2 and 0.1.2.3
 are so incredibly ancient that my humble opinion is that this note should
 be removed from the control-spec instead. The 0.2.2.1 always-on part might
 be interesting though.

 Removed FEATURE_VERBOSENAMES and added EXTENDED_EVENTS_DEFAULTED and
 VERBOSE_NAMES_DEFAULTED to stem.version.Requirement. (Though, I left a
 check for 0.1.2.2 in the test)


 > {{{
 > def is_feature_enabled(self, feature):
 >   defaulted_version = None
 >
 >   if feature == "EXTENDED_EVENTS":
 >     defaulted_version =
 stem.version.Requirement.EXTENDED_EVENTS_DEFAULTED
 >   elif feature == "VERBOSE_NAMES":
 >     defaulted_version = stem.version.Requirement.VERBOSE_NAMES_DEFAULTED
 >
 >   if defaulted_version and
 default_version.meets_requirements(self.get_version()):
 >     return True
 >   else:
 >     return feature in self.enabled_features
 > }}}

 Added, with a few modifications

 > > +      if test.runner.require_version(self,
 stem.version.Requirement.FEATURE_VERBOSENAMES):
 > > +        controller.enable_feature("VERBOSE_NAMES")
 >
 > Can we do something that requires VERBOSE_NAMES so we can confirm that
 it is now on?

 Yup. Done.

-- 
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/6417#comment:4>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
_______________________________________________
tor-bugs mailing list
tor-bugs@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs