puppet-python icon indicating copy to clipboard operation
puppet-python copied to clipboard

Regex doesn't work for version which contains '+' symbol

Open pleochroic opened this issue 6 years ago • 1 comments
trafficstars

Hi, Puppet 4.10.0 Module version: v1.18.2

I try install airflow from url but puppet tries to uninstall it.

ensure_resource(python::pip, 'airflow', {url => https://github.airflow/arhive/1.8.0.zip, pkgname => 'airflow', ensure => '1.8.0+apache.incubating')

Issue is that your regex doesn't like '+' in the version string '1.8.0+apache.incubating'. file: puppet-python/manifests/pip.pp strings: 136 if $ensure =~ /^((19|20)[0-9][0-9]-(0[1-9]|1[1-2])-([0-2][1-9]|3[0-1])|[0-9]+\.\w+\+?\w*(\.\w+)*)$/ { 209 /^((19|20)[0-9][0-9]-(0[1-9]|1[1-2])-([0-2][1-9]|3[0-1])|[0-9]+\.\w+\+?\w*(\.\w+)*)$/: {

Thank Pav

pleochroic avatar Dec 14 '18 16:12 pleochroic

Hi @pleochroic. Could you try the latest release and our master branch? Does the error ocour there as well?

bastelfreak avatar Jan 02 '19 19:01 bastelfreak