Quantcast
Channel: Planet Plone - Where Developers And Integrators Write
Viewing all articles
Browse latest Browse all 3535

Fred van Dijk: Buildout and the case of case sensitive eggs

$
0
0

Yes We Are Sensitive

This bites me now and then: if you add a python package to your instance eggs, please pay attention to upper/lower case. Especially if you ever want to version pin your buildout to keep it repeatable.

Example: I wanted to install WindowZ, a plone addon that allow you to insert content that acts as an iFrame doorway to another site. Cool. But DON’T add it to your eggs listing as “Products.WindowZ”.

  • This will get version 1.3-beta in your buildout. From 2007. But the latest version is 1.3b2. Check it on pypi.
  • Even prettier: if you you use the buildout.dumppickedversions extensions for buildout, it will happily report to you that 1.3-beta is indeed the latest version. But it’s not
  • And if you dare to add Products.windowZ = 1.3-beta to your versions.cfg to pin it, as dumppickedversions suggested,  “allow-picked-versions = false” will still abort every bin/buildout run, because your windowZ egg was not pinned. But you… yes…

It’s Products.windowZ. Use this as the reference in your instance eggs listing and everything will be allright? Why? I’m not sure. It could be that:

  1. http://pypi.python.org/pypi/Products.WindowZ and
  2. http://pypi.python.org/simple/Products.WindowZ

report different results. (1) is what you see when you try to look up an egg in the PyPI repository through the human friendly website. But (2) is what buildout is using to download an egg to save server cpu cycles and bandwidth. You get redirected. And so buildout thinks that Products.WindowZ is there, when it’s not.

We’ve been pinning for a while. More about repeatable buildouts by my colleague Maurits van Rees.


Viewing all articles
Browse latest Browse all 3535

Trending Articles