<?xml version="1.0" encoding="utf-8" ?><rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:admin="http://webns.net/mvcb/" xmlns="http://purl.org/rss/1.0/">
<channel rdf:about="http://betabug.ch/blogs/ch-athens">
  <title>ch-athens - zope</title>  <link>http://betabug.ch/blogs/ch-athens</link>
  <description>a swiss geek in Athens</description>
  <dc:date>2010-06-23T15:37:35Z</dc:date>
  <dc:creator />
<items>
 <rdf:Seq>
    <rdf:li rdf:resource="http://betabug.ch/blogs/ch-athens/1093" />
    <rdf:li rdf:resource="http://betabug.ch/blogs/ch-athens/1067" />
    <rdf:li rdf:resource="http://betabug.ch/blogs/ch-athens/1048" />
    <rdf:li rdf:resource="http://betabug.ch/blogs/ch-athens/1034" />
    <rdf:li rdf:resource="http://betabug.ch/blogs/ch-athens/1029" />
    <rdf:li rdf:resource="http://betabug.ch/blogs/ch-athens/1019" />
    <rdf:li rdf:resource="http://betabug.ch/blogs/ch-athens/1012" />
    <rdf:li rdf:resource="http://betabug.ch/blogs/ch-athens/979" />
    <rdf:li rdf:resource="http://betabug.ch/blogs/ch-athens/948" />
    <rdf:li rdf:resource="http://betabug.ch/blogs/ch-athens/926" />
    <rdf:li rdf:resource="http://betabug.ch/blogs/ch-athens/890" />
    <rdf:li rdf:resource="http://betabug.ch/blogs/ch-athens/860" />
    <rdf:li rdf:resource="http://betabug.ch/blogs/ch-athens/857" />
    <rdf:li rdf:resource="http://betabug.ch/blogs/ch-athens/845" />
    <rdf:li rdf:resource="http://betabug.ch/blogs/ch-athens/840" />
   </rdf:Seq>
</items>
</channel>
<item rdf:about="http://betabug.ch/blogs/ch-athens/1093">
  <title>Running Python's subprocess.Popen with a timeout from within Zope</title>
  <link>http://betabug.ch/blogs/ch-athens/1093</link>
  <description>There are moments when you go outside the world of Python to run something
on the command line in a shell. Python's subprocess module makes this doable.
But even though `Guido van Rossum suggested to add a timeout option`_ to that,
subprocess.Popen doesn't have it. There are a couple of suggestions for
crafting such a thing in, some more complicated, some less, some extra
complicated for working in Windows, some not. I did not have the Windows
requirement here, but I ran into another stumbling block.

One of the simplest solutions seems to have been to use the signal
module to send a timed SIGALRM to itself. Unfortunately signals in
python can be only received in the main thread. That makes the signal solution
solution not work in Zope. With some help from mgedmin on #zope, I
came up with another solution. I've used threading to spin of a
&quot;watchdog&quot; thread that will kill my potentially stuck subprocess
after a timeout. Meanwhile, if the main thread finds that the
subprocess finished normally, it can cancel out the watchdog. There's
even a flag that will be set so the main thread knows if there's
been success or a kill...</description>
      <dc:subject>zope</dc:subject>
    <dc:creator>betabug</dc:creator>
  <dc:date>2010-06-23T15:37:35Z</dc:date>
</item>
<item rdf:about="http://betabug.ch/blogs/ch-athens/1067">
  <title>ValueError: The permission XYZ is invalid</title>
  <link>http://betabug.ch/blogs/ch-athens/1067</link>
  <description>Oh, and while I'm at the topic of &quot;stupid little things I've left off half finished&quot;, let me add a
note to self: When you get an error &quot;ValueError: The permission XYZ is invalid&quot; in Zope 2, it's
because you've set up a permission (e.g. with manage_pe...</description>
      <dc:subject>zope</dc:subject>
    <dc:creator>betabug</dc:creator>
  <dc:date>2010-04-06T16:12:02Z</dc:date>
</item>
<item rdf:about="http://betabug.ch/blogs/ch-athens/1048">
  <title>Zope 2.12 eggified Installation Stuff Learned</title>
  <link>http://betabug.ch/blogs/ch-athens/1048</link>
  <description>There was a short zope-dev meeting on #zope today. I'm not a zope-dev, but after they were done,
I asked a question^W^W^Wgriped a bit about the new &quot;eggified&quot; Zope 2.12 install procedure. A
big discussion ensued. I learned / noticed a couple of things:</description>
      <dc:subject>zope</dc:subject>
    <dc:creator>betabug</dc:creator>
  <dc:date>2010-03-02T22:12:16Z</dc:date>
</item>
<item rdf:about="http://betabug.ch/blogs/ch-athens/1034">
  <title>Having Fun with ZEO</title>
  <link>http://betabug.ch/blogs/ch-athens/1034</link>
  <description>While it's cold (for our standards) with even a bit of snow on the higher hills around town, I'm
having fun with ZEO. The thing is, I've got to run a one-off script in one of our instance, doing a
catalog query and changing something on every found object. This is ideal to do with a plain old
Python Script in the ZMI... except of course I have blocked any attempts to change those
objects except through proper class code. Now I could change the permission and restart Zope
and edit the objects and go back... and in the process kick out all users twice for the downtime.
Don't like. Our ZEO setup offers a fun way of doing this without bothering users:</description>
      <dc:subject>zope</dc:subject>
    <dc:creator>betabug</dc:creator>
  <dc:date>2010-02-03T15:35:35Z</dc:date>
</item>
<item rdf:about="http://betabug.ch/blogs/ch-athens/1029">
  <title>DateTime SyntaxError on PDT Timezone</title>
  <link>http://betabug.ch/blogs/ch-athens/1029</link>
  <description>My MiniPlanet gave me SyntaxErrors on one feed, due to the feed in question being in the
timezone &quot; PDT &quot; . Problem is that Zope's DateTime module does not know that timezone. A quick
search and some reading up suggested the following patch to
$SOFTW...</description>
      <dc:subject>zope</dc:subject>
    <dc:creator>betabug</dc:creator>
  <dc:date>2010-01-13T10:46:54Z</dc:date>
</item>
<item rdf:about="http://betabug.ch/blogs/ch-athens/1019">
  <title>Compile Python 2.4 on Mac OS X 10.6 Snow Leopard</title>
  <link>http://betabug.ch/blogs/ch-athens/1019</link>
  <description>For older Zope versions it is still necessary to use Python 2.4 versions. To compile Python 2.4
on Mac OS X Snow Leopard, I had to jump through a few little hoops: First I downloaded and
unpacked the python tarball, then I applied the following patch...</description>
      <dc:subject>zope</dc:subject>
    <dc:creator>betabug</dc:creator>
  <dc:date>2009-12-14T12:46:15Z</dc:date>
</item>
<item rdf:about="http://betabug.ch/blogs/ch-athens/1012">
  <title>Catching Python xmlrpclib Exceptions</title>
  <link>http://betabug.ch/blogs/ch-athens/1012</link>
  <description>When using Zope, you don't want to have bare &quot; except: &quot; clauses lying around [1] and when using
xmlrpclib in Zope, you will have to guard against whatever connection trouble there may be.
Problem is, xmlrpclib seems to sometimes report errors by rai...</description>
      <dc:subject>zope</dc:subject>
    <dc:creator>betabug</dc:creator>
  <dc:date>2009-11-18T11:35:54Z</dc:date>
</item>
<item rdf:about="http://betabug.ch/blogs/ch-athens/979">
  <title>Authenticating Multiple Subdomains with CookieCrumbler</title>
  <link>http://betabug.ch/blogs/ch-athens/979</link>
  <description>When Zope 2 devs want to provide users with an HTML login form, the tool to use is Shane
Hathaway's CookieCrumbler product. On one of our sites, I wanted users to be able to
authenticate with one login form to multiple subdomains: www.example.com, do...</description>
      <dc:subject>zope</dc:subject>
    <dc:creator>betabug</dc:creator>
  <dc:date>2009-07-24T09:48:16Z</dc:date>
</item>
<item rdf:about="http://betabug.ch/blogs/ch-athens/948">
  <title>Connect Zope to ZEO across Europe</title>
  <link>http://betabug.ch/blogs/ch-athens/948</link>
  <description>Just did an interesting test setup here... installed a ZEO server on a machine I have in a housing with good bandwidth in Austria, then connected a Zope instance as a ZEO client to it, from here in Greece. Took me a couple of minutes to setup. I can say it works at least for a first test setup. What this means is that the local machine renders web pages with data from a database that is 1288 km away...</description>
      <dc:subject>zope</dc:subject>
    <dc:creator>betabug</dc:creator>
  <dc:date>2009-04-29T15:34:19Z</dc:date>
</item>
<item rdf:about="http://betabug.ch/blogs/ch-athens/926">
  <title>Move a Python module from one Zope Product to another</title>
  <link>http://betabug.ch/blogs/ch-athens/926</link>
  <description>Last December I started on a another refactoring of our company's Zope Application. This time I was going to split out some of the stuff into separate Products, so I could install them only when needed. All nice and clean, but the instances of those classes / products in the ZODB didn't like their code to be moved out from under their feet. I asked around on #zope and TresEquis showed me what to do. Since this stuff is kind of hard to find, here is a little writeup.</description>
      <dc:subject>zope</dc:subject>
    <dc:creator>betabug</dc:creator>
  <dc:date>2009-02-18T09:34:49Z</dc:date>
</item>
<item rdf:about="http://betabug.ch/blogs/ch-athens/890">
  <title>Zwiki 0.61 Released - Cleanup and Catchup</title>
  <link>http://betabug.ch/blogs/ch-athens/890</link>
  <description>Woke up this lazy Weekend noon to find Simon has released 0.61 of the stable branch of Zwiki.
This is not some bombastic feature release, rather a version that's catching up and cleaning
up some stuff. I'm happy that Simon did this, since I've been s...</description>
      <dc:subject>zwiki</dc:subject>
      <dc:subject>zope</dc:subject>
    <dc:creator>betabug</dc:creator>
  <dc:date>2008-10-25T12:01:59Z</dc:date>
</item>
<item rdf:about="http://betabug.ch/blogs/ch-athens/860">
  <title>Zope Incremental Backup Script</title>
  <link>http://betabug.ch/blogs/ch-athens/860</link>
  <description>With your Zope installation comes the repozo.py script, that allows you to do incremental
backups of the ZODB (the ``Data.fs`` file). Around that script most people build a shell
script and run it through a cron job. Since I just did a new installation (yeah, that's rare for
me), I brushed up what I use so far. I'm now automatically keeping 2 generations of backups,
whenever a &quot;generation switch&quot; is done, all the moving, deleting etc. is done by the script.
The resulting main folder I rsync to a remote machine. Here comes the script...</description>
      <dc:subject>zope</dc:subject>
    <dc:creator>betabug</dc:creator>
  <dc:date>2008-07-09T14:13:17Z</dc:date>
</item>
<item rdf:about="http://betabug.ch/blogs/ch-athens/857">
  <title>PNG, Transparency, IE6, AlphaImageLoader, and SSL</title>
  <link>http://betabug.ch/blogs/ch-athens/857</link>
  <description>In case you try to run one of the AlphaImageLoader fixes out there in order to teach Internet
Explorer 6 to handle PNG images with transparent alpha channel information somehow
gracefully... and in case you try to run this over SSL (https), you might...</description>
      <dc:subject>digital</dc:subject>
      <dc:subject>zope</dc:subject>
    <dc:creator>betabug</dc:creator>
  <dc:date>2008-07-02T16:19:40Z</dc:date>
</item>
<item rdf:about="http://betabug.ch/blogs/ch-athens/845">
  <title>Patch fun: have a look</title>
  <link>http://betabug.ch/blogs/ch-athens/845</link>
  <description>A few days ago I reported about Wu's &quot; learning Zope product &quot; , where I helped out with patches
and advice. In the meantime Wu has put some resources online: There's svn public access and a
little project description on his trac (with instructions t...</description>
      <dc:subject>zope</dc:subject>
    <dc:creator>betabug</dc:creator>
  <dc:date>2008-06-13T09:01:21Z</dc:date>
</item>
<item rdf:about="http://betabug.ch/blogs/ch-athens/840">
  <title>Patch Fun</title>
  <link>http://betabug.ch/blogs/ch-athens/840</link>
  <description>For a few days now I've been hacking with Wu on a fun project of his. It's nothing too serious or
even too useful, but that's not the point. For him it's a project to learn a bit more about Zope 2,
while for me... for me it's just fun to show him how...</description>
      <dc:subject>zope</dc:subject>
    <dc:creator>betabug</dc:creator>
  <dc:date>2008-06-07T22:35:59Z</dc:date>
</item>
</rdf:RDF>
