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

Upgraded deepl-cli code #267

Merged
merged 9 commits into from
Nov 30, 2024
Merged

Conversation

Monsterovich
Copy link
Contributor

@Monsterovich Monsterovich commented Nov 30, 2024

I wanted to make one change at first, but decided to put everything into one PR. This PR improves the following:

  • Added support for skeleton display of translated text. Fixes Partial translation error #253.
  • Fixed a bug using the wrong button locator when use_dom_submit = True.
  • The code now also closes the Chrome extension popup that possibly can prevent clicking on language buttons (also for use_dom_submit = True).
  • Update: also changed the max chars limit from 3000 to 1500.

@Monsterovich
Copy link
Contributor Author

ping @eggplants

deepl/deepl.py Outdated Show resolved Hide resolved
deepl/deepl.py Outdated Show resolved Hide resolved
deepl/deepl.py Outdated Show resolved Hide resolved
@eggplants eggplants merged commit 1d621be into eggplants:master Nov 30, 2024
1 of 4 checks passed
@Monsterovich
Copy link
Contributor Author

Monsterovich commented Nov 30, 2024

@eggplants Now the code doesn't run:

Traceback (most recent call last):
  File "/home/monsterovich/Scripts/deepl_translate_clipboard.py", line 7, in <module>
    from deepl import deepl
  File "/home/monsterovich/.local/lib/python3.10/site-packages/deepl/__init__.py", line 3, in <module>
    from .deepl import DeepLCLI, DeepLCLIError
  File "/home/monsterovich/.local/lib/python3.10/site-packages/deepl/deepl.py", line 203
    const t )
    ^^^^^^^
SyntaxError: f-string: invalid syntax. Perhaps you forgot a comma?

@eggplants
Copy link
Owner

Thank you for your contribution,

This codebase is corrupt for a while due to deepl's update and lack of maintenance for deepl-cli. Inappropriate fixtures will be fixed and be published to PyPI with some fixture to make translation successfully soon.

@Monsterovich
Copy link
Contributor Author

Monsterovich commented Nov 30, 2024

Thank you for your contribution,

This codebase is corrupt for a while due to deepl's update and lack of maintenance for deepl-cli. Inappropriate fixtures will be fixed and be published to PyPI with some fixture to make translation successfully soon.

@eggplants Eh, just quickly merge this -> #268

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Partial translation error
2 participants