This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author giampaolo.rodola
Recipients cmcginty, ggenellina, giampaolo.rodola
Date 2010-05-19.13:50:50
SpamBayes Score 0.032048583
Marked as misclassified No
Message-id <1274277053.66.0.253583843522.issue6589@psf.upfronthosting.co.za>
In-reply-to
Content
Could you provide an actual example code which reproduces this problem?
It's not clear to me how the dispatcher instance can end up in an "invalid state" since handle_error() should automatically remove the invalid dispatcher instance from the socket_map if anything unexpected happens.
If this doesn't happen it might be a problem related with what you've done in your subclass (e.g. you have overridden handle_error and avoided to call close() yourself).

Furthermore the use case you have described it's pretty uncommon as you shouldn't run SMTPServer in a thread in the first place.

If you intend to bind two servers simultaneously you just have to instantiate two STMPServer sub/classes and finally call asyncore.loop().
Both instances will automatically be served by asyncore itself.
History
Date User Action Args
2010-05-19 13:50:53giampaolo.rodolasetrecipients: + giampaolo.rodola, ggenellina, cmcginty
2010-05-19 13:50:53giampaolo.rodolasetmessageid: <1274277053.66.0.253583843522.issue6589@psf.upfronthosting.co.za>
2010-05-19 13:50:50giampaolo.rodolalinkissue6589 messages
2010-05-19 13:50:50giampaolo.rodolacreate