github-extended markdown doesn't work on the cookbook site; best way to include code is to put it in a separate file and link it with {% include_code yourscript.py %}

Example: https://raw.github.com/logstash/cookbook/gh-pages/recipes/apache-json-logs/index.md uses '{% include_code apache.conf %}'