ansible-role-zsh
ansible-role-zsh copied to clipboard
Version comparison: '<' not supported between instances of 'str' and 'int'
With latest updates of Vagrant, I get this error regarding this line on tasks/configure.yml
:
TASK [zsh : Check commands exists] *********************************************
[DEPRECATION WARNING]: Using tests as filters is deprecated. Instead of using
`result|version` use `result is version`. This feature will be removed in
version 2.9. Deprecation warnings can be disabled by setting
deprecation_warnings=False in ansible.cfg.
fatal: [default]: FAILED! => {"msg": "An unhandled exception occurred while templating
'[{'name': 'command-not-found', 'when': \"{{ ansible_os_family != 'Darwin' }}\"}, {'name': 'brew', 'command': 'brew'},
{'name': 'docker', 'command': 'docker'}, {'name': 'docker-compose', 'command': 'docker-compose'}, 'fancy-ctrl-z',
'git-extras', 'gnu-utils', {'name': 'httpie', 'command': 'http'}, {'name': 'go', 'command': 'go'},
{'name': 'gulp', 'command': 'gulp'}, {'name': 'pip', 'command': 'pip'}, {'name': 'rake', 'command': 'rake'},
{'name': 'symfony2', 'command': 'symfony'}, {'name': 'systemd', 'command': 'systemctl'}, 'python', {'name': 'tmux', 'command': 'tmux'},
{'name': 'vagrant', 'command': 'vagrant'}, {'name': 'viasite/drall', 'command': 'drall'}, {'name': 'viasite/drupal-scripts', 'command': 'drs'},
{'name': 'viasite/server-scripts', 'command': 'dbdump'}, {'name': 'viasite-ansible/zsh-ansible-server', 'command': 'ansible-deploy'}, 'zsh_reload',
{'name': 'zsh-users/zsh-autosuggestions', 'when': \"{{ zsh_version | default(false) | version('5.0', '>=') }}\"}, 'popstas/zsh-command-time',
{'name': 'unixorn/autoupdate-antigen.zshplugin', 'when': '{{ zsh_update_interval > 0 }}'}, 'urbainvaes/fzf-marks', '{{ fzf_widgets }}',
{'name': 'zdharma/[email protected]', 'when': \"{{ zsh_version | default(false) | version('4.3.17', '>=') }}\"}]'. Error was a
<class 'ansible.errors.AnsibleFilterError'>,
original message: Version comparison: '<' not supported between instances of 'str' and 'int'"}
...ignoring
Hello! Have not Vargant installed now.
Can you try to replace in Vagrantfile
in first line 16.04
to 20.04
, maybe old python or ansible in Vagrant...
If it not help, you can edit defaults/main.yml and remove when
options in plugins zsh-users/zsh-autosuggestions
and zdharma-continuum/fast-syntax-highlighting
:
- { name: zsh-users/zsh-autosuggestions, when: "{{ zsh_version is version_compare('5.0', '>=') }}" }
- { name: zdharma-continuum/fast-syntax-highlighting, when: "{{ zsh_version is version_compare('4.3.17', '>=') }}" }
Replace to:
- { name: zsh-users/zsh-autosuggestions }
- { name: zdharma-continuum/fast-syntax-highlighting }
Won't fix