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

The command python3 -m ttkbootstrap does not work to open Themes on mac OS #477

Closed
mas6y6 opened this issue Aug 11, 2023 · 4 comments
Closed
Labels
bug Something isn't working

Comments

@mas6y6
Copy link

mas6y6 commented Aug 11, 2023

Desktop (please complete the following information):

ttkbootstrap Version v1.10.1
Mac OS

Describe the bug

I Have a issue when I open the python3 -m ttkbootstrap command

Command:

python3 -m ttkbootstrap

python -m ttkbootstrap does not work on my laptop

The error is in Additional context area

To Reproduce

  1. Run command
python3 -m ttkcreator
  1. See Error
    The Full error is in Additional context area

Expected behavior

No response

Screenshots

Screenshot 2023-08-10 at 8 46 21 PM

Additional context

The full traceback:

Traceback (most recent call last):
  File "<frozen runpy>", line 198, in _run_module_as_main
  File "<frozen runpy>", line 88, in _run_code
  File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/ttkcreator/__main__.py", line 471, in <module>
    creator = ThemeCreator()
              ^^^^^^^^^^^^^^
  File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/ttkcreator/__main__.py", line 23, in __init__
    self.demo_widgets = DemoWidgets(self, self.style)
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/ttkcreator/__main__.py", line 245, in __init__
    self.create_left_frame()
  File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/ttkcreator/__main__.py", line 445, in create_left_frame
    m = ttk.Meter(
        ^^^^^^^^^^
  File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/ttkbootstrap/widgets.py", line 718, in __init__
    self._setup_widget()
  File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/ttkbootstrap/widgets.py", line 759, in _setup_widget
    self._draw_meter()
  File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/ttkbootstrap/widgets.py", line 856, in _draw_meter
    img.resize((self._metersize, self._metersize), Image.CUBIC)
                                                   ^^^^^^^^^^^
AttributeError: module 'PIL.Image' has no attribute 'CUBIC'. Did you mean: 'BICUBIC'?
@mas6y6 mas6y6 added the bug Something isn't working label Aug 11, 2023
@mas6y6 mas6y6 changed the title enter title of bug here The Themes is broken in Mac OS Aug 11, 2023
@mas6y6 mas6y6 changed the title The Themes is broken in Mac OS The command python3 -m ttkbootstrap does not work to open Themes Aug 11, 2023
@mas6y6 mas6y6 changed the title The command python3 -m ttkbootstrap does not work to open Themes The command python3 -m ttkbootstrap does not work to open Themes on mac OS Aug 11, 2023
@wrogner
Copy link

wrogner commented Aug 19, 2023

Search for the widgets.py file (if installed in a venv, venv/lib/<python3.xx>/site-packages/ttkbootstrap/widgets.py)
and replace it with this version:
widgets.py.zip

@mas6y6
Copy link
Author

mas6y6 commented Aug 19, 2023

Ok lets see if this works

@mas6y6 mas6y6 closed this as completed Aug 19, 2023
@mas6y6 mas6y6 reopened this Aug 19, 2023
@mas6y6
Copy link
Author

mas6y6 commented Aug 19, 2023

Its was fixed

@mas6y6 mas6y6 closed this as completed Aug 19, 2023
@wrogner
Copy link

wrogner commented Aug 20, 2023

I provided a workaround (and of course this works).

However, the problem is not fixed as long as the installation packages are not updated (people still pip install ttkbootstrap and get broken libraries).

I cannot help with the last step.

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

2 participants