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

[BUG] Module 'PIL' has no attribute Image #3813

Closed
2 tasks done
Benjamintdk opened this issue Jun 29, 2023 · 4 comments
Closed
2 tasks done

[BUG] Module 'PIL' has no attribute Image #3813

Benjamintdk opened this issue Jun 29, 2023 · 4 comments
Labels
bug Something isn't working untriaged This issues has not yet been looked at by the Maintainers

Comments

@Benjamintdk
Copy link

Describe the bug

Attempting to use the ImageRenderer from Flyteplugins.deck.renderer yields the following error at this line: "Module PIL has no attribute Image"

Expected behavior

Don't expect the error to appear as PIL should have been imported at the top of the file.

Additional context to reproduce

  1. Install the library: pip install flytekitplugins-deck-standard
  2. Import ImageRenderer: from flytekitplugins.deck.renderer import ImageRenderer
  3. Create a task function as shown below:
@task
def func(png_path: str):
    ...
    png_file = PNGImageFile(path=png_path, remote_path=some_remote_path)
    flytekit.Deck("demo", ImageRenderer().to_html(png_file)) <--- error occurs here
    ...

Screenshots

image

Are you sure this issue hasn't been raised already?

  • Yes

Have you read the Code of Conduct?

  • Yes
@Benjamintdk Benjamintdk added bug Something isn't working untriaged This issues has not yet been looked at by the Maintainers labels Jun 29, 2023
@welcome
Copy link

welcome bot commented Jun 29, 2023

Thank you for opening your first issue here! 🛠

@Future-Outlier
Copy link
Member

@Benjamintdk
Hi, can you offer the whole code for us to fix the bug?
In flytekit, we've already tested the scenario.
https://github.com/flyteorg/flytekit/blob/master/plugins/flytekit-deck-standard/tests/test_renderer.py#L60-L72

@eapolinario
Copy link
Contributor

@Benjamintdk , can you double-check which version of pyllow you installed when you saw this bug?

@thomasjpfan
Copy link
Member

I am closing, because it has been 5 months without a response from the original author.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working untriaged This issues has not yet been looked at by the Maintainers
Projects
None yet
Development

No branches or pull requests

4 participants