Can't make the compose() works
See original GitHub issueTo me is impossible to make the composer method work. So I wrote this basic example anda everything works mostly fine for my needs, but the compose don’t. Is There anything wrong with the way I’m using it?
from datetime import timedelta
import srt
td = timedelta(seconds=1)
a = srt.Subtitle(index=1, start=td, end=td, content='Word 1')
b = srt.Subtitle(index=2, start=td, end=td, content='Word 2')
c = [a, b]
print(srt.compose(c))
c = a.to_srt() + b.to_srt()
print("========")
print(c)
print("====")
d = list(srt.parse(c))
print(d)
Issue Analytics
- State:
- Created 3 years ago
- Comments:9 (5 by maintainers)
Top Results From Across the Web
Why won't my modifiers work in jetpack compose
I'd imported some java.lang thing. Make sure you've got import androidx.compose.ui.Modifier . Hope your solution is something as simple as that ...
Read more >Can't get compose to work with remote hosts #6059 - GitHub
Description of the issue When following the instructions from Running Compose on a single server I am unable to connect to a remote...
Read more >Compose link not working. No problem opening messages in ...
Went into Task Mgr to stop CHrome and went back in fresh, Cleared history and temp files, Closed computer and restarted, I have...
Read more >Thinking in Compose | Jetpack Compose - Android Developers
A simple composable function. Using Compose, you can build your user interface by defining a set of composable functions that take in data...
Read more >Troubleshooting - Composer
Make sure you have no problems with your setup by running the installer's checks via curl -sS https://getcomposer.org/installer | php -- --check ....
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
The creators of this module may want to adjust the docs as the same example is given there. https://srt.readthedocs.io/en/latest/api.html#srt.compose
The output shown in the docs will not in fact be produced unless
reindex=False
is passed.It’s filtered because it’s never displayed (end <= start). If you want to just verbatim print the Subtitle objects, you need to pass
reindex=False
tosrt.compose
.