Get a Python Package Version
Part of maintaining a Django-based application like MDN's kuma is ensuring Python packages are up to date. I was recently testing an upgrade on a remote system and needed to ensure that a given Python package was at the version number it should be. Here's how I retrieved the package version:
import nose # Nose is a test utility. Replace with your desired package here.
# Output: 0.3.1
__version__ property returns the exact version number for a Python package. Some Python packages use a
VERSION property as well, but
__version__ should be the most reliable.
CSS filter support recently landed within WebKit nightlies. CSS filters provide a method for modifying the rendering of a basic DOM element, image, or video. CSS filters allow for blurring, warping, and modifying the color intensity of elements. Let's have...
I'd bet one of the most used MooTools methods is the
setStyle() method, which allows you to set CSS style declarations for an element. One of the limitations of MooTools'
setStyle() method is that it sets the specific style for all medias.
One of the more impressive MooTools plugins to hit the Forge recently was The Wall by Marco Dell'Anna. The Wall creates an endless grid of elements which can be grabbed and dragged, fading in elements as they are encountered. Let me show...