Skip to content

Make it easier (more obious how) to use github features when using EasyBuild on a shared system with EESSI #919

@adammccartney

Description

@adammccartney

Trying to --upload-test-report when building a piece of software on a shared system using EESSI-extend is really difficult.

Tried to follow the docs, which advise to use --install-github-token, which requires pip install keyring and (python-pass + pass) to set up a backend. Pass uses gpg for decryption and signing, so it's not all that obvious that we want to leave a key with those sorts of abilities lying around on a shared system. Whatever, there is also the unsafe option of installing keyrings.alt which lets us use plaintext or light encryption on a file. Good, that's fine we can delete the file after we upload the bug report.

The questions is where to install those pacakges, assuming we're on a system using easybuild from EESSI-extend.
Tried to install them into a dedicated virtualenv, and it is activated in before the call below, but fails with the following output:

> eb --github-user adammccartney --install-github-token
== Temporary log file in case of crash /tmp/eb-loqmolm5/easybuild-pj5wz1gg.log
Token:
Validating token...
Token seems to be valid, installing it.
EasyBuild crashed! Please consider reporting a bug, this should not happen...

Traceback (most recent call last):
  File "<frozen runpy>", line 198, in _run_module_as_main
  File "<frozen runpy>", line 88, in _run_code
  File "/cvmfs/software.eessi.io/versions/2023.06/software/linux/x86_64/amd/zen4/software/EasyBuild/5.1.0/lib/python3.11/site-packages/easybuild/main.py", line 829, in <module>
    main_with_hooks()
  File "/cvmfs/software.eessi.io/versions/2023.06/software/linux/x86_64/amd/zen4/software/EasyBuild/5.1.0/lib/python3.11/site-packages/easybuild/main.py", line 815, in main_with_hooks
    main(args=args, prepared_cfg_data=(init_session_state, eb_go, cfg_settings))
  File "/cvmfs/software.eessi.io/versions/2023.06/software/linux/x86_64/amd/zen4/software/EasyBuild/5.1.0/lib/python3.11/site-packages/easybuild/main.py", line 691, in main
    install_github_token(options.github_user, silent=build_option('silent'))
  File "/cvmfs/software.eessi.io/versions/2023.06/software/linux/x86_64/amd/zen4/software/EasyBuild/5.1.0/lib/python3.11/site-packages/easybuild/tools/github.py", line 2614, in install_github_token
    keyring.set_password(KEYRING_GITHUB_TOKEN, github_user, token)
  File "/cvmfs/software.eessi.io/versions/2023.06/compat/linux/x86_64/usr/lib/python3.11/site-packages/keyring/core.py", line 60, in set_password
    get_keyring().set_password(service_name, username, password)
    ^^^^^^^^^^^^^
  File "/cvmfs/software.eessi.io/versions/2023.06/compat/linux/x86_64/usr/lib/python3.11/site-packages/keyring/core.py", line 32, in get_keyring
    init_backend()
  File "/cvmfs/software.eessi.io/versions/2023.06/compat/linux/x86_64/usr/lib/python3.11/site-packages/keyring/core.py", line 83, in init_backend
    set_keyring(_detect_backend(limit))
                ^^^^^^^^^^^^^^^^^^^^^^
  File "/cvmfs/software.eessi.io/versions/2023.06/compat/linux/x86_64/usr/lib/python3.11/site-packages/keyring/core.py", line 97, in _detect_backend
    load_env()
  File "/cvmfs/software.eessi.io/versions/2023.06/compat/linux/x86_64/usr/lib/python3.11/site-packages/keyring/core.py", line 143, in load_env
    return load_keyring(os.environ['PYTHON_KEYRING_BACKEND'])
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/cvmfs/software.eessi.io/versions/2023.06/compat/linux/x86_64/usr/lib/python3.11/site-packages/keyring/core.py", line 134, in load_keyring
    class_ = _load_keyring_class(keyring_name)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/cvmfs/software.eessi.io/versions/2023.06/compat/linux/x86_64/usr/lib/python3.11/site-packages/keyring/core.py", line 124, in _load_keyring_class
    __import__(module_name)
ModuleNotFoundError: No module named 'keyrings'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions