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: duplicated uploads #7715

Merged
merged 4 commits into from
Aug 9, 2023

Conversation

guohaolay
Copy link
Contributor

Only schedule upload for unique files, otherwise it would try to upload the same files multiple times.

Only schedule upload for unique files, otherwise it would try to upload the same files multiple times.
@changeset-bot
Copy link

changeset-bot bot commented Aug 4, 2023

⚠️ No Changeset found

Latest commit: 7af3db3

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

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

@netlify
Copy link

netlify bot commented Aug 4, 2023

Deploy Preview for car-park-attendant-cleat-11576 ready!

Name Link
🔨 Latest commit b62b054
🔍 Latest deploy log https://app.netlify.com/sites/car-park-attendant-cleat-11576/deploys/64d3a2ac0bc1be0008ebfd25
😎 Deploy Preview https://deploy-preview-7715--car-park-attendant-cleat-11576.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@guohaolay guohaolay changed the title Fix duplicated uploads fis:duplicated uploads Aug 4, 2023
@guohaolay guohaolay changed the title fis:duplicated uploads fis: duplicated uploads Aug 4, 2023
@guohaolay guohaolay changed the title fis: duplicated uploads fix: duplicated uploads Aug 4, 2023
@mmaietta
Copy link
Collaborator

mmaietta commented Aug 5, 2023

Thanks for contributing!

I'd like to delve a little further into this, what are being duplicated during the upload phase?
Are you doing anything within the afterAllArtifactBuild build hook?

@guohaolay
Copy link
Contributor Author

We noticed electron builder was uploading the same file twice.

In the afterAllArtifactBuild hook, we are returning additional files and noticed a mistake where we included files already in the artifacts list. This caused the upload to happen twice for the same file.

The suggested fix is to catch that error in the builder to prevent bad coders (ie myself) from accidentally doing this.

guohaolay and others added 3 commits August 8, 2023 15:09
Only schedule upload for unique files, otherwise it would try to upload the same files multiple times.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants