I just released version 0.3 of Hep, my multiprotocol message server.
The big change in this release is that Hep is now using Twisted for all
its networking stuff: HTTP and XMLRPC clients, POP3, SMTP, and web
The Hep web page is:
Thanks for the nice software!
I was looking to run IM on a Win32 machine, but both scripts, im.py and t-im.py, require GTK. According to the documentation that accompanies Twisted, IM should run with Tkinter. Does anyone have a copy that does?
I am newbie with some background using zope. I am trying to use twisted in a web application that is going to be launched in my office. Problem now is that i cannot get the example to work ( Example ) .....
1. os --> windows 98
2. python --> python-2.2.2
This is my autoexec.bat :
i can't seem to get the Example even to compile and looking through the docs doesn't seem to help much. One question can i use the --personal option on a windows machine ?
I get an error that says it cannot find the pwd module. Can someone please help me or at least point me somewhere where there are some docs ???
Thanks in advance
iRepublics.com - Free Web Hosting for Businesses
33MB webspace free, SMS messaging, 30 email accounts, your own domain name
Sign up Now at http://www.iRepublics.com
I just set up a basic demo new server using twisted. Some initial comments:
1. It took me almost no time to put together a basic dummy NNTP
server. Just create the backend, put a mktap driver in, and it's
2. There seems to be a problem with the server class. It translates
\r\n.. to \r\n. in the data the backend supplies - this should be
the other way round (it should be *doubling* the dots, so that they
don't look like the end of data marker to the client).
3. It would be nice if the server handled the translation to CRLF, so
that backends could return data with lines separated by \n, and the
server class would convert that to \r\n. After all, \n is the
"normal" end of line character internal to Python code, and \r\n is
a feature of the NNTP protocol, so the protocol driver should be
responsible for the conversion (IMHO). Of course, this is a
behaviour change, which could break existing backends, so maybe
it's not practical to make this change.
4. The implementation of STAT requests the article from the
backend. This could be inefficient if getting the message ID is
cheap, but getting the full article is expensive for a particular
backend (it will be for me). In my partly-implemented NNTP server
written in "raw" Python (before I found Twisted) I had a backend
method getArticle(..., head=1, body=1) which was used to implement
all of HEAD, BODY, ARTICLE and STAT, just by setting different
values for the head and body parameters (so the backend could check
for the case where neither was required, and act accordingly).
(2) is obviously fairly trivial. I think I could implement (3) and
(4), if it would be useful. I could submit a patch, which would alter
the server code and the 2 existing backends (I couldn't test the
database backend, as I don't have a database to test with, but I could
test the pickle-based code). Would this be helpful? Are there likely
to be 3rd party nntp backends which would be broken by such a change?
This signature intentionally left blank
On Thu, Oct 31, 2002 at 11:33:01AM +1100, Jonathan M. Lange wrote:
With reference to twisted.enterprise.reflector not making a Deferred available
on construction, despite it being an asynchronous operation...
> Suggestions include having a populatedDeferred as a member (rather than
I've been having troubles with my mail recently. In case this did not come
through, here is the patch again.
Comments appreciated. Commits even more so.
RCS file: /cvs/Twisted/twisted/enterprise/reflector.py,v
retrieving revision 1.9
diff -u -r1.9 reflector.py
--- twisted/enterprise/reflector.py 16 Oct 2002 04:27:29 -0000 1.9
+++ twisted/enterprise/reflector.py 31 Oct 2002 00:57:59 -0000
@@ -20,6 +20,7 @@
from twisted.enterprise import adbapi
from twisted.enterprise.util import DBError, getKeyColumn, quote, _TableInfo,
from twisted.enterprise.row import RowObject
+from twisted.internet import defer
"""Base class for enterprise reflectors. This implements rowCacheing.
@@ -61,6 +62,7 @@
from twisted.internet import reactor
+ self.populatedDeferred = defer.Deferred()
"""Implement me to populate schema information for the reflector.
RCS file: /cvs/Twisted/twisted/enterprise/sqlreflector.py,v
retrieving revision 1.10
diff -u -r1.10 sqlreflector.py
--- twisted/enterprise/sqlreflector.py 14 Oct 2002 22:34:21 -0000 1.10
+++ twisted/enterprise/sqlreflector.py 31 Oct 2002 00:58:00 -0000
@@ -49,6 +49,7 @@
defe = self.runInteraction(self._transPopulateSchema)
def _transPopulateSchema(self, transaction):
"""Used to construct the row classes in a single interaction.
just wondered if it would be acceptable to add either grouping and e.g. OR
to whereClause or to make it possible to specify the WHERE CLAUSE
manually(which could be abused for other things too .. i know..)
another thing is an 'ORDER BY' Clause ..
both should be easy to add afaik .. (code for where-clause starting at
line 129 of sqlreflector.py)
what do u think?
-----BEGIN GEEK CODE BLOCK-----
GCS/CC/E/M/MU/S d- s: a--- C++++(++) UL++++ P+ L++++ E W+++ N+++ o-- K w-- O
M-- V- PS+ PE-- Y++ PGP+++ t+++ 5+ X- R tv b++++ DI- D+ G++ e-->+++++ h-- !r
------END GEEK CODE BLOCK------
This email was sent using SquirrelMail.
"Webmail for nuts!"
I'm setting up a site using Woven, and I've hit a strange problem.
I've got a subclass of woven.widget.Widget called VolumeWidget, and that
widget is used to display a list of links within a page. I've got another
class called VolumeListWidget, the only purpose of which is to display a
list of these VolumeWidgets.
def setUp(self, request, node, data):
for volume in data.get('volumes') or :
volume_model = VolumeModel(volume)
volume_div = VolumeWidget(volume_model)
volume_div.tagName = 'div'
VolumeListWidget's not working. Instead of displaying a <div> that
contains all the stuff VolumeWidget is supposed to contain [as defined in
VolumeWidget's setUp() function], it's displaying an empty <div/>. I'm not
sure what I'm doing wrong, if anything, but it's too strange to tell.
Example (along with some code) is available here:
To see a working example of VolumeWidget, go here:
I will appreciate any help anyone can lend me.
While developing my twisted.im bot (new this week! database access and
an infobot-style plugin!) I've come up against two seperate
annoyances. This patch fixes both of them.
Number 1: the IRC protocol defines (among other things) two message
types - privmsg and notice. They are identical in every respect except
that a notice must not be automatically replied to. Currently,
twisted.protocol.irc.IRCClient maps notice onto privmsg, which is
dangerous but acceptible, because you're supposed to subclass
However, twisted.im.ircsupport subclasses IRCClient and does not
override the 'noticed' method, so all twisted.im clients cannot tell
the difference between a privmsg and a notice. This is really not a
good thing, especially for an IM bot like mine. The attached patch
fixes this in a brute force manner by making twisted.im.ircsupport
drop all notices on the floor.
Number 2: The IRC protocol defines a certain bunch of commands that
the server can send the client. twisted.protocol.irc.IRCClient calls
self.irc_COMMAND to handle an incoming command 'COMMAND', and if no
such method exists, it calles self.irc_unknown.
twisted.im.ircsupport by default prints an error message for each
unknown command it recieves. Slashnet in particular seems to like to
send a lot of them, and it clutters up my screen. This patch simply
comments out the print statement and adds a 'pass'.
| Screwtape | Reply-To: munged on Usenet |________ ______ ____ __ _ _ _
| "I've got this brilliant idea but I don't know where it is." -- Beth Allen
Yes, another raw tarball of my code.
New in this update:
- infobot plugin with an SQL backend - currently uses sqlite and
pysqlite (see http://pysqlite.sf.net), but porting it to some other
SQL database should be trivial.
- A README file.
- Properly ignores NOTICEs and ACTIONs (requires Twisted from current
CVS to ignore NOTICEs.
Currently, the bot is lurking in #afda on irc.slashnet.org under the
name of 'Mooby', if you want to poke at it.
...still waiting for his first bug report.
| Screwtape | Reply-To: munged on Usenet |________ ______ ____ __ _ _ _
| "You seem cool for a naked chick in a booth - let's be pals someday." -- PUSA
In a message of Sat, 02 Nov 2002 19:27:40 EST, Itamar Shtull-Trauring writes:
>On Sat, 02 Nov 2002 18:35:44 +0100
>Anders Hammarquist <iko(a)cd.chalmers.se> wrote:
>> $ python2.2 pyunit/unittest.py
>> twisted.test.test_smtp.AnotherSMTPTestCase.testBuffer---- Running
>> Test: twisted.test.test_smtp.AnotherSMTPTestCase.testBuffer
>Please note that Twisted needs to support 2.1 as well, it's recommended
>you run tests under both 2.1 and 2.2. Though that may be totally
>unrelated to the issue here.
There shouldn't be any 2.2-specific stuff in there, using 2.2 is just
habbit (as the stuff we're using it for needs 2.2). Running the same
test using python 2.1 works, so there shouldn't be any major 2.1
-- Of course I'm crazy, but that doesn't mean I'm wrong.
Anders Hammarquist | iko(a)cd.chalmers.se
Physics student, Chalmers University of Technology, | Hem: +46 31 88 48 50
G|teborg, Sweden. RADIO: SM6XMM and N2JGL | Mob: +46 707 27 86 87