Skip to content
Snippets Groups Projects
  • W. Trevor King's avatar
    094d3470
    irkerd: Add kwargs handling to pass data to IRCServerConnection.connect · 094d3470
    W. Trevor King authored
    This makes it easy to pass data down the stack:
    
      Irker() (stored in Irker.kwargs)
      `-- Irker.handle() -> Dispatcher() (stored in Dispatcher.kwargs)
          `-- Dispatcher.dispatch() -> Connection() (stored in Connection.kwargs)
              `-- Connection.dequeue() -> IRCServerConnection.connect()
    
    You can easily add data at every point in the stack (e.g. we add
    'target' in Irker.handle()) and pull it back out when that's
    appropriate (e.g. we tap 'target' back out in Connection()).  With
    this setup we can reduce the number of global variables currently in
    use, because it will be easy to pass data like passwords,
    nickame-fallback-ness, etc. down to the appropriate level, without the
    intermediate levels needing any changes.
    094d3470
    History
    irkerd: Add kwargs handling to pass data to IRCServerConnection.connect
    W. Trevor King authored
    This makes it easy to pass data down the stack:
    
      Irker() (stored in Irker.kwargs)
      `-- Irker.handle() -> Dispatcher() (stored in Dispatcher.kwargs)
          `-- Dispatcher.dispatch() -> Connection() (stored in Connection.kwargs)
              `-- Connection.dequeue() -> IRCServerConnection.connect()
    
    You can easily add data at every point in the stack (e.g. we add
    'target' in Irker.handle()) and pull it back out when that's
    appropriate (e.g. we tap 'target' back out in Connection()).  With
    this setup we can reduce the number of global variables currently in
    use, because it will be easy to pass data like passwords,
    nickame-fallback-ness, etc. down to the appropriate level, without the
    intermediate levels needing any changes.
Code owners
Assign users and groups as approvers for specific file changes. Learn more.