[mnet-devel] Re: [mnet-cvs]grmbl
Zooko
zooko at zooko.com
Fri May 23 13:10:21 BST 2003
> @@ -177,7 +177,8 @@
> @NOTIMPLEMENTEDYET: I haven't looked at all the various dict methods and made sure that LRUCache does the right thing in every case. In particular, it might not
> offer iterator behavior properly.
> """
> def __init__(self, initialdata={}, maxsize=128):
> - precondition(DoQ.doq.is_currently_doq(), "You are required to invoke this on the DoQ thread.")
> +# hello zooko. i would really prefer you could stop breaking egtp by changing requirements without making sure it works.
> +# precondition(DoQ.doq.is_currently_doq(), "You are required to invoke this on the DoQ thread.")
> dict.__init__(self, initialdata)
> self._lru = initialdata.keys() # contains keys
> self._maxsize = maxsize
a) I ran the unit tests and I ran the mnetcli manual experiment.
The unit tests sometimes fail, on my machine, but I thought that was due to
something else and not to that precondition.
b) I'm not changing the requirements, I'm adding a precondition to
automatically check the requirements! Even with the precondition commented
out, it is still a requirement that Cache be instantiated on the DoQ, and if
you instantiate it on a different thread then you run the risk of
unreproduceable buggy behavior.
I'll go investigate those unit tests and that precondition and see what's
going on.
--Z
-------------------------------------------------------
This SF.net email is sponsored by: ObjectStore.
If flattening out C++ or Java code to make your application fit in a
relational database is painful, don't do it! Check out ObjectStore.
Now part of Progress Software. http://www.objectstore.net/sourceforge
_______________________________________________
mnet-devel mailing list
mnet-devel at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mnet-devel
More information about the Mnet-devel
mailing list