#compdef python

_auto_argcomplete_python () {
  local -a reply
  local ret=1

  if [ $CURRENT -eq 2 ]; then
    _python
  elif [ "`basename ${words[2]}`" = "setup.py" ]; then
    _python
  else
    reply=( $(auto_argcomplete ${words[2]}) )
    _describe -t reply "options" reply && ret=0
  fi
}
compdef _auto_argcomplete_python python
