Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SyntaxError in Python <3.12 #21

Closed
KennyChenBasis opened this issue Jun 11, 2024 · 5 comments
Closed

SyntaxError in Python <3.12 #21

KennyChenBasis opened this issue Jun 11, 2024 · 5 comments
Labels
bug Something isn't working

Comments

@KennyChenBasis
Copy link

Steps to reproduce:

  1. Run the example usage:
from pypdl import Pypdl

dl = Pypdl()
dl.start('http://example.com/file.txt')

Expected result:

Download starts and completes.

Actual result:

SyntaxError: f-string: expecting '}'

in pypdl/factory.py", line 219,

    download_stats = f"Downloading...{" " * 95}\n"

The new f-string usage is only available in Python 3.12.

Environment:

  • Python 3.9.18
  • pypdl 1.4.0
@mjishnu mjishnu added the bug Something isn't working label Jun 13, 2024
@armin567ip
Copy link

Same

@mjishnu
Copy link
Owner

mjishnu commented Jun 16, 2024

forgot to test it on older versions I was testing on 3.12, sorry for the delay my pc was busted, fixed the issue in this commit 30bac23 (working in python 3.8.10)

@armin567ip
Copy link

forgot to test it on older versions I was testing on 3.12, sorry for the delay my pc was busted, fixed the issue in this commit 30bac23 (working in python 3.8.10)

Should I upgrade now?
pip install --upgrade pypdl
like this?

@mjishnu
Copy link
Owner

mjishnu commented Jun 16, 2024

forgot to test it on older versions I was testing on 3.12, sorry for the delay my pc was busted, fixed the issue in this commit 30bac23 (working in python 3.8.10)

Should I upgrade now? pip install --upgrade pypdl like this?

I didn't publish yet making few more changes. as a temp fix just manually apply the changes I made in the commit

@mjishnu
Copy link
Owner

mjishnu commented Jun 18, 2024

Thanks for reporting, with v1.4.1 this should be fixed.

@mjishnu mjishnu closed this as completed Jun 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants