carderne/signal-export

RuntimeError: Type not yet supported: pathlib.Path | None

Closed this issue · 3 comments

Desktop (please complete the following information):

  • Ubuntu 20.04
  • bash

Describe the bug
Installed signal-export, tried to export all chats, got the above error message and no export.

To reproduce
$ sigexport /tmp/signal
...
Using Docker to extract data, this may take a while the first time!
Docker process failed, see logs below:
Unable to find image 'carderne/sigexport:v1.8.2' locally
v1.8.2: Pulling from carderne/sigexport
8a1e25ce7c4f: Pulling fs layer
1103112ebfc4: Pulling fs layer
e71929d49167: Pulling fs layer
c529235f83c8: Pulling fs layer
a47354887c31: Pulling fs layer
2aa6cd6484d0: Pulling fs layer
97169c4e7ff4: Pulling fs layer
0df10c098b93: Pulling fs layer
dea520c54d7a: Pulling fs layer
b0037bbdcfa3: Pulling fs layer
aa6fdf064091: Pulling fs layer
4e6f23c2e966: Pulling fs layer
ec348b1ba91b: Pulling fs layer
2aa6cd6484d0: Waiting
97169c4e7ff4: Waiting
aa6fdf064091: Waiting
4e6f23c2e966: Waiting
0df10c098b93: Waiting
dea520c54d7a: Waiting
b0037bbdcfa3: Waiting
ec348b1ba91b: Waiting
a47354887c31: Waiting
1103112ebfc4: Verifying Checksum
1103112ebfc4: Download complete
c529235f83c8: Download complete
a47354887c31: Verifying Checksum
a47354887c31: Download complete
e71929d49167: Verifying Checksum
e71929d49167: Download complete
2aa6cd6484d0: Download complete
8a1e25ce7c4f: Verifying Checksum
8a1e25ce7c4f: Download complete
dea520c54d7a: Download complete
8a1e25ce7c4f: Pull complete
1103112ebfc4: Pull complete
b0037bbdcfa3: Verifying Checksum
b0037bbdcfa3: Download complete
e71929d49167: Pull complete
c529235f83c8: Pull complete
a47354887c31: Pull complete
2aa6cd6484d0: Pull complete
aa6fdf064091: Verifying Checksum
aa6fdf064091: Download complete
4e6f23c2e966: Download complete
0df10c098b93: Verifying Checksum
0df10c098b93: Download complete
97169c4e7ff4: Verifying Checksum
97169c4e7ff4: Download complete
97169c4e7ff4: Pull complete
0df10c098b93: Pull complete
dea520c54d7a: Pull complete
b0037bbdcfa3: Pull complete
aa6fdf064091: Pull complete
4e6f23c2e966: Pull complete
ec348b1ba91b: Pull complete
Digest: sha256:
Status: Downloaded newer image for carderne/sigexport:v1.8.2
╭───────────────────── Traceback (most recent call last) ──────────────────────╮
│ /usr/local/bin/sigexport:8 in │
│ │
│ 5 from sigexport.main import cli │
│ 6 if name == 'main': │
│ 7 │ sys.argv[0] = re.sub(r'(-script.pyw|.exe)?$', '', sys.argv[0]) │
│ ❱ 8 │ sys.exit(cli()) │
│ 9 │
│ │
│ ╭────────────────────────────── locals ───────────────────────────────╮ │
│ │ cli = <function cli at 0x7fb5787a3e20> │ │
│ │ re = <module 're' from '/usr/local/lib/python3.12/re/init.py'> │ │
│ │ sys = <module 'sys' (built-in)> │ │
│ ╰─────────────────────────────────────────────────────────────────────╯ │
│ │
│ /usr/local/lib/python3.12/site-packages/sigexport/main.py:512 in cli │
│ │
│ 509 │
│ 510 def cli() -> None: │
│ 511 │ """cli.""" │
│ ❱ 512 │ run(main) │
│ 513 │
│ 514 │
│ 515 if name == "main": │
│ │
│ /usr/local/lib/python3.12/site-packages/typer/main.py:1056 in run │
│ │
│ /usr/local/lib/python3.12/site-packages/typer/main.py:328 in call
│ │
│ /usr/local/lib/python3.12/site-packages/typer/main.py:311 in call
│ │
│ /usr/local/lib/python3.12/site-packages/typer/main.py:364 in get_command │
│ │
│ /usr/local/lib/python3.12/site-packages/typer/main.py:577 in │
│ get_command_from_info │
│ │
│ /usr/local/lib/python3.12/site-packages/typer/main.py:553 in │
│ get_params_convertors_ctx_param_name_from_function │
│ │
│ /usr/local/lib/python3.12/site-packages/typer/main.py:850 in get_click_param │
│ │
│ /usr/local/lib/python3.12/site-packages/typer/main.py:779 in get_click_type │
╰──────────────────────────────────────────────────────────────────────────────╯
RuntimeError: Type not yet supported: pathlib.Path | None

I get a similar error with "sigexport --list-chats", every time.

It seems like you're using an old version of signal-export, can you please try to install the latest with:

pip install 'signal-export>=2.3.4'

@carderne , thank you for a blazingly fast response. This is what I get:

ERROR: Could not find a version that satisfies the requirement signal-export>=2.3.4 (from versions: 1.1.0, 1.1.1, 1.1.2, 1.2.0, 1.2.1, 1.2.2, 1.2.3, 1.2.4, 1.3.0, 1.3.1, 1.4.2, 1.5.0, 1.5.1, 1.5.2, 1.5.3, 1.5.4, 1.5.5, 1.6.0, 1.6.1, 1.7.0, 1.7.1, 1.8.0, 1.8.1, 1.8.2)
ERROR: No matching distribution found for signal-export>=2.3.4

Oh sorry you must be on Python 3.8, the signal-export after v2.0.0 require Python >= 3.9
(You can run python --version to confirm.)

Are you able to install Python 3.9 or a newer version?

If you're not able to, you can try following these instructions to do it without Python:
https://github.com/carderne/signal-export?tab=readme-ov-file#-no-python-install