Opened 3 years ago

Closed 3 years ago

#5250 enhancement closed fixed (fixed)

finger15.tac patch

Reported by: anv Owned by: anv
Priority: low Milestone:
Component: core Keywords:
Cc: thijs Branch:
Author: Launchpad Bug:

Description (last modified by exarkun)

In the current version of finger15.tac
the _read method has never been called.
Proposal patch solves the problem.

Index: trunk/doc/core/howto/tutorial/listings/finger/finger15.tac
===================================================================
--- trunk/doc/core/howto/tutorial/listings/finger/finger15.tac	(revision 32505)
+++ trunk/doc/core/howto/tutorial/listings/finger/finger15.tac	(working copy)
@@ -79,6 +79,7 @@
 
 application = service.Application('finger', uid=1, gid=1)
 f = FingerService('/etc/users')
+f.setServiceParent(application)
 serviceCollection = service.IServiceCollection(application)
 internet.TCPServer(79, f.getFingerFactory()
                    ).setServiceParent(serviceCollection)

Attachments (1)

tutorial_finger.patch (5.2 KB) - added by anv 3 years ago.
The whole patch

Download all attachments as: .zip

Change History (6)

comment:1 Changed 3 years ago by anv

Conceptually this is much better:

Index: trunk/doc/core/howto/tutorial/listings/finger/finger15.tac
===================================================================
--- trunk/doc/core/howto/tutorial/listings/finger/finger15.tac	(revision 30844)
+++ trunk/doc/core/howto/tutorial/listings/finger/finger15.tac	(working copy)
@@ -80,6 +80,7 @@
 application = service.Application('finger', uid=1, gid=1)
 f = FingerService('/etc/users')
 serviceCollection = service.IServiceCollection(application)
+f.setServiceParent(serviceCollection)
 internet.TCPServer(79, f.getFingerFactory()
                    ).setServiceParent(serviceCollection)
 internet.TCPServer(8000, server.Site(f.getResource())

comment:2 Changed 3 years ago by thijs

  • Cc thijs added
  • Keywords review added

Putting the patch up for review as described in the ReviewProcess.

comment:3 Changed 3 years ago by exarkun

  • Description modified (diff)
  • Keywords review removed
  • Owner set to anv

Thanks. Due to the construction of the finger tutorial, the mistake is duplicated in every subsequent tac as well. Would you like to attach a patch addressing all of them?

Changed 3 years ago by anv

The whole patch

comment:4 Changed 3 years ago by exarkun

Thanks!

comment:5 Changed 3 years ago by exarkun

  • Resolution set to fixed
  • Status changed from new to closed

(In [32568]) Apply tutorial_finger.patch fixing the finger tutorial listings to correctly construct the service hierarchy.

Author: anv
Reviewer: exarkun
Fixes: #5250

Fix many finger tutorial listings, which did not add the finger service to the
service hierarchy, preventing the service from ever reading the user list.

Note: See TracTickets for help on using tickets.