amimof/ansible-websphere

Not compatible with Python3

skacfjin opened this issue · 3 comments

When I am installing IBMIM, I am getting following error:

The full traceback is:
Traceback (most recent call last):
  File "/home/ec2-user/.ansible/tmp/ansible-tmp-1619715629.36-10262-81603055390095/AnsiballZ_ibmim.py", line 102, in <module>
    _ansiballz_main()
  File "/home/ec2-user/.ansible/tmp/ansible-tmp-1619715629.36-10262-81603055390095/AnsiballZ_ibmim.py", line 94, in _ansiballz_main
    invoke_module(zipped_mod, temp_path, ANSIBALLZ_PARAMS)
  File "/home/ec2-user/.ansible/tmp/ansible-tmp-1619715629.36-10262-81603055390095/AnsiballZ_ibmim.py", line 40, in invoke_module
    runpy.run_module(mod_name='ansible.modules.ibmim', init_globals=None, run_name='__main__', alter_sys=True)
  File "/usr/lib64/python3.6/runpy.py", line 205, in run_module
    return _run_module_code(code, init_globals, run_name, mod_spec)
  File "/usr/lib64/python3.6/runpy.py", line 96, in _run_module_code
    mod_name, mod_spec, pkg_name, script_name)
  File "/usr/lib64/python3.6/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/tmp/ansible_ibmim_payload_pgyrj4uj/ansible_ibmim_payload.zip/ansible/modules/ibmim.py", line 361, in <module>
  File "/tmp/ansible_ibmim_payload_pgyrj4uj/ansible_ibmim_payload.zip/ansible/modules/ibmim.py", line 348, in main
  File "/tmp/ansible_ibmim_payload_pgyrj4uj/ansible_ibmim_payload.zip/ansible/modules/ibmim.py", line 221, in install
  File "/tmp/ansible_ibmim_payload_pgyrj4uj/ansible_ibmim_payload.zip/ansible/modules/ibmim.py", line 169, in isProvisioned
  File "/tmp/ansible_ibmim_payload_pgyrj4uj/ansible_ibmim_payload.zip/ansible/modules/ibmim.py", line 199, in getVersion
TypeError: a bytes-like object is required, not 'str'

Running into the same error. Did you ever resolve this?

If I remember it correctly, I had it when I was testing installation on RHEL8.. so we switched temporarily back to RHEL7

Sadly it seems that amimof is not active any more. I send him a pull request which fixes some other bug last year, it's still not merged like many other PRs. So I continued to develop my own fork of the repository, where I fixed the lack of Python3 support. I'm currently testing this, because Python2 is EOL since 2020 so I'd like to completely move to Python3.

Maybe the fork is interesting for you since it seems you'd like to use the maintained Python3 too instead of 2.