Uploaded image for project: 'RHEL'
  1. RHEL
  2. RHEL-54538

ansible get_url fails on target with Python 3.12

    • Icon: Bug Bug
    • Resolution: Won't Do
    • Icon: Undefined Undefined
    • None
    • CentOS Stream 9
    • ansible-core
    • None
    • No
    • Moderate
    • rhel-sst-ansible
    • None
    • False
    • Hide

      None

      Show
      None
    • None
    • None
    • None
    • None
    • None

      What were you trying to do that didn't work?

      Run the following task on a host with Python 3.12+:

         - name: "Download LsAgent"
           get_url:
             url: https://cdn.lansweeper.com/download/{{ lsagent_linux_version | regex_replace('\.(\d+)$', '/\1') }}/LsAgent-linux.run
             dest: /tmp/lsagent.run
             mode: 0755
           environment:
             http_proxy: "http://{{ webfilter }}:8080"
             https_proxy: "http://{{ webfilter }}:8080"

      Please provide the package NVR for which bug is seen:

      ansible-core-2.14.17-1.el9.x86_64

      How reproducible:

      everytime

      Expected results

      No failure

      Actual results

      FAILED! => {"changed": false, "dest": "/tmp/lsagent.run", "elapsed": 0, "msg": "An unknown error occurred: HTTPSConnection._init_() got an unexpected keyword argument 'cert_file'", "url": "https://cdn.lansweeper.com/download/10.4.2/1/LsAgent-linux.run"}

       

      This was fixed in ansible 2.16 with https://github.com/ansible/ansible/pull/80751

              dsavinea@redhat.com Dimitri Savineau
              opoplawski Orion Poplawski
              Dimitri Savineau Dimitri Savineau
              Matt Clay Matt Clay
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: