flatpak / flatpak-builder-tools

Various helper tools for flatpak-builder
190 stars 107 forks source link

python-pip-generator fails on pexpect #176

Open arteeh opened 3 years ago

arteeh commented 3 years ago

When I try to build a flatpak with pexpect, something fails and I'm not sure what. I tried following the advice in #90 but gave up when I kept having to manually add dependencies to no avail.

JSON made by pip-generator:

{
    "name": "python3-pexpect",
    "buildsystem": "simple",
    "build-commands": [
        "pip3 install --exists-action=i --no-index --find-links=\"file://${PWD}\" --prefix=${FLATPAK_DEST} \"pexpect\""
    ],
    "sources": [
        {
            "type": "file",
            "url": "https://files.pythonhosted.org/packages/e5/9b/ff402e0e930e70467a7178abb7c128709a30dfb22d8777c043e501bc1b10/pexpect-4.8.0.tar.gz",
            "sha256": "fc65a43959d153d0114afe13997d439c22823a27cefceb5ff35c2178c6784c0c"
        },
        {
            "type": "file",
            "url": "https://files.pythonhosted.org/packages/7d/2d/e4b8733cf79b7309d84c9081a4ab558c89d8c89da5961bf4ddb050ca1ce0/ptyprocess-0.6.0.tar.gz",
            "sha256": "923f299cc5ad920c68f2bc0bc98b75b9f838b93b599941a6b63ddbc2476394c0"
        }
    ]
}

Terminal output when running flatpak-builder .builddir com.arteeh.Companion.yml --force-clean:

========================================================================
Building module python3-pexpect in /home/arteeh/git/watch/wasp-companion/flatpak/.flatpak-builder/build/python3-pexpect-2
========================================================================
Running: pip3 install --exists-action=i --no-index --find-links="file://${PWD}" --prefix=${FLATPAK_DEST} "pexpect"
Looking in links: file:///run/build/python3-pexpect
Processing ./pexpect-4.8.0.tar.gz
Processing ./ptyprocess-0.6.0.tar.gz
  Installing build dependencies ... error
  ERROR: Command errored out with exit status 1:
   command: /usr/bin/python3 /usr/lib/python3.8/site-packages/pip install --ignore-installed --no-user --prefix /tmp/pip-build-env-3t99_fhu/overlay --no-warn-script-location --no-binary :none: --only-binary :none: --no-index --find-links file:///run/build/python3-pexpect -- flit
       cwd: None
  Complete output (3 lines):
  Looking in links: file:///run/build/python3-pexpect
  ERROR: Could not find a version that satisfies the requirement flit (from versions: none)
  ERROR: No matching distribution found for flit
  ----------------------------------------
ERROR: Command errored out with exit status 1: /usr/bin/python3 /usr/lib/python3.8/site-packages/pip install --ignore-installed --no-user --prefix /tmp/pip-build-env-3t99_fhu/overlay --no-warn-script-location --no-binary :none: --only-binary :none: --no-index --find-links file:///run/build/python3-pexpect -- flit Check the logs for full command output.
Error: module python3-pexpect: Child process exited with code 1
arteeh commented 3 years ago

Hi, following up on this. I still haven't gotten this to work in any way, and my application won't work without pexpect. The error is extremely unclear for me, so I have no idea how to solve this.

arteeh commented 3 years ago

170 seems to fix this for me.

nanonyme commented 2 years ago

Does this still reproduce?