[vlc-commits] [Git][videolan/vlc][master] 2 commits: extras: breakpad: use io types for IO classes

Steve Lhomme (@robUx4) gitlab at videolan.org
Sun Sep 21 14:20:22 UTC 2025



Steve Lhomme pushed to branch master at VideoLAN / VLC


Commits:
4bd5e2ec by Steve Lhomme at 2025-09-21T13:51:24+00:00
extras: breakpad: use io types for IO classes

typing.io doesn't seem to exist anymore.

typing.io was in Python 3.5 [^1] but not in 3.6 [^2].

```
Traceback (most recent call last):
  File "/builds/robUx4/vlc/./extras/breakpad/symb_upload.py", line 146, in <module>
    class OutputStore:
        def store(self, dump: typing.io.TextIO, meta):
            assert(False)
  File "/builds/robUx4/vlc/./extras/breakpad/symb_upload.py", line 147, in OutputStore
    def store(self, dump: typing.io.TextIO, meta):
                          ^^^^^^^^^
  File "/usr/lib/python3.13/typing.py", line 3817, in __getattr__
    raise AttributeError(f"module {__name__!r} has no attribute {attr!r}")
AttributeError: module 'typing' has no attribute 'io'. Did you mean: 'IO'?
```

[^1]: https://docs.python.org/3.5/library/typing.html#typing.io
[^2]: https://docs.python.org/3.6/library/typing.html

- - - - -
104be00c by Steve Lhomme at 2025-09-21T13:51:24+00:00
extras: breakpad: add requirements.txt file describing needed Python modules

- - - - -


2 changed files:

- + extras/breakpad/requirements.txt
- extras/breakpad/symb_upload.py


Changes:

=====================================
extras/breakpad/requirements.txt
=====================================
@@ -0,0 +1 @@
+requests


=====================================
extras/breakpad/symb_upload.py
=====================================
@@ -7,7 +7,6 @@ import logging
 import requests
 import io
 import shutil
-import typing
 
 
 class Dumper:
@@ -147,7 +146,7 @@ class MacDumper(Dumper):
 
 
 class OutputStore:
-    def store(self, dump: typing.io.TextIO, meta):
+    def store(self, dump: io.TextIOBase, meta):
         assert (False)
 
 
@@ -161,7 +160,7 @@ class HTTPOutputStore(OutputStore):
         if prod:
             self.extra_args["prod"] = prod
 
-    def store(self, dump: typing.io.TextIO, meta):
+    def store(self, dump: io.TextIOBase, meta):
         post_args = {**meta, **self.extra_args}
         r = requests.post(self.url, post_args, files={"symfile": dump})
         if not r.ok:
@@ -174,7 +173,7 @@ class LocalDirOutputStore(OutputStore):
         super().__init__()
         self.rootdir = rootdir
 
-    def store(self, dump: typing.io, meta):
+    def store(self, dump: io.IOBase, meta):
         basepath = os.path.join(self.rootdir, meta["debug_file"], meta["debug_identifier"])
         if not os.path.exists(basepath):
             os.makedirs(basepath)



View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/faef6d706d7edda8eb39b532ee74618c1bf8cc8c...104be00c113cd2259d981211408880687ab8f0ce

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/faef6d706d7edda8eb39b532ee74618c1bf8cc8c...104be00c113cd2259d981211408880687ab8f0ce
You're receiving this email because of your account on code.videolan.org.


VideoLAN code repository instance


More information about the vlc-commits mailing list