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

Fix multiple images being generated for the same image #6710

Merged
merged 2 commits into from
Mar 30, 2023

Conversation

Princesseuh
Copy link
Member

@Princesseuh Princesseuh commented Mar 30, 2023

Changes

Previously we used a Map of ImageTransform to string to list all the images to generate, this doesn't work because you cannot compare objects on their values. This PR changes it to a Map of HashedTransform to {path: string, options: ImageTransform} so we can compare based on the hashes instead.

Fix #6489

Testing

Tested manually, this mostly affected the build log moreso than the actual generation (it seemed like there was some kind of caching being done either way?)

Docs

N/A

@changeset-bot
Copy link

changeset-bot bot commented Mar 30, 2023

🦋 Changeset detected

Latest commit: bf18b84

The changes in this PR will be included in the next version bump.

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions github-actions bot added the pkg: astro Related to the core `astro` package (scope) label Mar 30, 2023
@Princesseuh Princesseuh changed the title Fix/duplicate transforms Fix multiple images being generated for the same image Mar 30, 2023
Copy link
Member

@bluwy bluwy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@Princesseuh Princesseuh merged commit a0bdf4c into main Mar 30, 2023
@Princesseuh Princesseuh deleted the fix/duplicate-transforms branch March 30, 2023 09:31
@astrobot-houston astrobot-houston mentioned this pull request Mar 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pkg: astro Related to the core `astro` package (scope)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

astro build shows duplicate lines in the log
2 participants