[Zope] random.choice()

Nathan Valentine nathan@nathanvalentine.org
21 Aug 2002 20:31:19 -0400


--=-jwEL394s799UbXWKlLHD
Content-Type: text/plain
Content-Transfer-Encoding: quoted-printable


import random
print random.choice(["true", "false"])

In a stand-alone .py file, this will print either "true" or "false". In
a Python script in the ZODB, it prints "None". What gives?=20



--=20
---
Nathan Valentine - nathan@nathanvalentine.org
Jabber: NRVesKY AIM: NRVesKY ICQ: 39023424

--=-jwEL394s799UbXWKlLHD
Content-Type: application/pgp-signature; name=signature.asc
Content-Description: This is a digitally signed message part

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (GNU/Linux)

iD8DBQA9ZC+xOtuGVF5JE5ARAjXOAKCkizd3NW48e/ct4JBROSVcCy+x0gCeK7gD
ARU0WT/02I2xgpV9/BkhZro=
=Cr7z
-----END PGP SIGNATURE-----

--=-jwEL394s799UbXWKlLHD--