Commit graph

9294 commits

Author SHA1 Message Date
Masum ULU
8afe5338bd
@uppy/xhr-upload: export Headers type (#4549)
Fixes: https://github.com/transloadit/uppy/issues/4547
2023-07-06 11:23:14 +02:00
Stefan Schonert
8604178bfc
@uppy/aws-s3-multipart: increase priority of abort and complete (#4542) 2023-07-06 11:17:14 +02:00
Antoine du Hamel
169de84654
@uppy/aws-s3: fix remote uploads (#4546) 2023-07-05 16:05:07 +02:00
Antoine du Hamel
eba604e8fb
meta: use corepack yarn instead of npm to launch E2E (#4545) 2023-07-05 16:02:59 +02:00
Antoine du Hamel
6d969a5132
@uppy/aws-s3-multipart: fix upload retry using an outdated ID (#4544) 2023-07-05 15:53:19 +02:00
Artur Paikin
7fcc7a6bbc
@uppy/status-bar: remove throttled component (#4396)
Co-authored-by: Murderlon <merlijn@soverin.net>
2023-07-05 15:31:28 +02:00
Antoine du Hamel
d1697b0cb8
@uppy/aws-s3-multipart: fix Golden Retriever integration (#4526) 2023-06-29 16:50:09 +02:00
Antoine du Hamel
35b4b0e4c0
examples/aws-nodejs: merge multipart and non-multipart examples (#4521) 2023-06-28 16:32:50 +02:00
dependabot[bot]
e660c51b86
@uppy/companion: bump semver from 7.3.7 to 7.5.3 (#4529)
Bumps [semver](https://github.com/npm/node-semver) from 7.3.7 to 7.5.2.
- [Release notes](https://github.com/npm/node-semver/releases)
- [Changelog](https://github.com/npm/node-semver/blob/main/CHANGELOG.md)
- [Commits](https://github.com/npm/node-semver/compare/v7.3.7...v7.5.2)

---
updated-dependencies:
- dependency-name: semver
  dependency-type: direct:production


Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>
2023-06-28 11:40:37 +02:00
Antoine du Hamel
4ee51842b8
@uppy/aws-s3-multipart: add types to internal fields (#4535)
Co-authored-by: Merlijn Vos <merlijn@soverin.net>
2023-06-28 11:06:52 +02:00
Antoine du Hamel
c9e1dfb5b2
examples/aws-nodejs: update README (#4534) 2023-06-28 10:52:41 +02:00
Antoine du Hamel
435cb8ba71
examples/aws-nodejs: showcase an example without preflight requests (#4516) 2023-06-27 21:34:17 +02:00
Antoine du Hamel
b6a6f83c44
@uppy/aws-s3-multipart: fix pause/resume (#4523)
When pausing the upload, we don't want to remove the cached `uploadId`,
otherwise Uppy needs to re-upload the file from the begininng, even if
it has already uploaded some chunks.
2023-06-27 19:01:53 +02:00
Antoine du Hamel
692481ae35
@uppy/status-bar: fix ETA when Uppy recovers its state (#4525)
It was showing NaN seconds left.
2023-06-27 18:52:20 +02:00
Antoine du Hamel
ae3a0e7016
@uppy/aws-s3-multipart: fix resume single-chunk multipart uploads (#4528) 2023-06-26 13:56:46 +02:00
Antoine du Hamel
e289c8404c
@uppy/companion: fix part listing in s3 (#4524)
Attempting to list a multipart upload with 0 uploaded parts would return
an empty array with AWS SDK v2, and returns `undefined` with AWS SDK v3.
2023-06-24 19:38:56 +02:00
Antoine du Hamel
2b26e646d3
example/aws-php: make it forward-compatible with the next Uppy major (#4522) 2023-06-22 16:12:11 +02:00
Antoine du Hamel
a869d2ed49
@uppy/golden-retriever: refactor to modernize the codebase (#4520)
Use of async/await rather than `.then` chains, avoid caching promises,
use newer syntax/methods where it makes sense, etc.
2023-06-22 15:34:09 +02:00
Antoine du Hamel
44e5e0e2d7
examples/aws-nodejs: upgrade to AWS-SDK v3 (#4515) 2023-06-22 12:18:35 +02:00
Mikael Finstad
2c75ddacfe
@uppy/companion: implement refresh for authentication tokens (#4448)
* allow storing multiple tokens

inside uppy auth token

* de-duplicate uploadRemote

by creating a new superclass UploaderPlugin

* pull out requestSocketToken

from MiniXHRUpload

* add class UploaderPlugin

* refactor

* refactor

* refactor/reuse

* refactor/make getAuthToken private

* fix bug

* implement refresh token

for dropbox and google drive

closes #2721

* fix test

* also update auth token cookie
when refreshing token

* fix build error on node 14

* increase auth token expiry

to workaround expiry

* Update packages/@uppy/companion-client/src/RequestClient.js

Co-authored-by: Antoine du Hamel <antoine@transloadit.com>

* make queueRequestSocketToken private

* rename arg

* fix lint

* log error message

* fix s3

* Update packages/@uppy/companion-client/src/Provider.js

Co-authored-by: Antoine du Hamel <antoine@transloadit.com>

---------

Co-authored-by: Antoine du Hamel <antoine@transloadit.com>
2023-06-22 11:18:48 +02:00
Artur Paikin
12db56f332
@uppy/aws-s3-multipart: disable pause/resume for remote uploads in the UI (#4500)
Co-authored-by: Murderlon <merlijn@soverin.net>
2023-06-22 10:09:49 +02:00
Antoine du Hamel
2b9958c4f8
@uppy/tus: retry on 423 HTTP error code (#4512) 2023-06-20 11:17:56 +02:00
github-actions[bot]
147e5da96f
Release: uppy@3.10.0 (#4511)
| Package                | Version | Package                | Version |
| ---------------------- | ------- | ---------------------- | ------- |
| @uppy/aws-s3           |   3.2.0 | @uppy/status-bar       |   3.2.0 |
| @uppy/aws-s3-multipart |   3.4.0 | @uppy/transloadit      |   3.1.6 |
| @uppy/companion        |   4.5.1 | @uppy/tus              |   3.1.1 |
| @uppy/core             |   3.2.1 | @uppy/url              |   3.3.2 |
| @uppy/dashboard        |   3.4.1 | @uppy/utils            |   5.4.0 |
| @uppy/golden-retriever |   3.0.4 | @uppy/xhr-upload       |   3.3.0 |
| @uppy/locales          |   3.2.2 | uppy                   |  3.10.0 |
| @uppy/provider-views   |   3.3.1 |                        |         |

- @uppy/aws-s3-multipart: fix the chunk size calculation (Antoine du Hamel / #4508)
- @uppy/aws-s3: add `shouldUseMultipart` option (Antoine du Hamel / #4299)
- @uppy/companion: switch from aws-sdk v2 to @aws-sdk/* (v3) (Scott Bessler / #4285)
- @uppy/companion,@uppy/core,@uppy/dashboard,@uppy/golden-retriever,@uppy/status-bar,@uppy/utils: Migrate all lodash' per-method-packages usage to lodash. (LinusMain / #4274)
- @uppy/core: Don't set late (throttled) progress event on a file that is 100% complete (Artur Paikin / #4507)
- @uppy/companion: revert randomness from file names (Mikael Finstad / #4509)
- @uppy/companion: Custom provider fixes (Mikael Finstad / #4498)
- @uppy/transloadit: ensure `fields` is not nullish when there no uploaded files (Antoine du Hamel / #4487)
- @uppy/aws-s3-multipart,@uppy/aws-s3,@uppy/tus,@uppy/utils,@uppy/xhr-upload: When file is removed (or all are canceled), controller.abort queued requests (Artur Paikin / #4504)
- @uppy/provider-views: Fix range selection not resetting and computing correctly (Terence C / #4415)
- meta: disallow use of `.only` in tests (Antoine du Hamel / #4494)
- @uppy/companion: fix 500 when file name contains non-ASCII chars (Antoine du Hamel / #4493)
- @uppy/locales: update `fr_FR.js` (Samuel De Backer / #4499)
- @uppy/aws-s3-multipart,@uppy/tus,@uppy/xhr-upload: Don't close socket while upload is still in progress (Artur Paikin / #4479)
- meta: bump `luxon` from 1.28.0 to 1.28.1 (dependabot[bot] / #4497)
- @uppy/utils: rename `EventTracker` -> `EventManager` (Stephen Wooten / #4481)
- meta: bump cookiejar from 2.1.3 to 2.1.4 (dependabot[bot] / #4496)
- meta: make `pre-commit` use `corepack yarn` instead of `npm run` (Antoine du Hamel / #4495)
- meta: bump ua-parser-js from 0.7.31 to 0.7.35 (dependabot[bot] / #4474)
- meta: bump @sideway/formula from 3.0.0 to 3.0.1 (dependabot[bot] / #4473)
- meta: bump http-cache-semantics from 4.1.0 to 4.1.1 (dependabot[bot] / #4472)
- @uppy/companion: Use filename from content-disposition instead of relying on url, with fallback (Artur Paikin / #4489)
- meta: bump `babel`, `esbuild`, and `vite` (dependabot[bot] / #4485)
- @uppy/dashboard: include the old state when setting new (Artur Paikin / #4490)
- @uppy/companion: fix companion implicitpath (Mikael Finstad / #4484)
- @uppy/companion: fix undefined protocol and example page (Mikael Finstad / #4483)
- meta: upgrade Cypress 12.9.0 -> 12.14.0 (Antoine du Hamel / #4491)
- @uppy/core: remove `state` getter from types (Antoine du Hamel / #4477)
- examples/php-xhr: Added filename sanitation and file size check before saving (neuronet77 / #4432)
- examples/php-xhr: update PHP dependencies (dependabot[bot])
- @uppy/xhr-upload: add support for arrays in metadata (Vasiliy Matyushin / #4431)
- @uppy/status-bar: Filtered ETA (stduhpf / #4458)
- @uppy/aws-s3-multipart: fix `getUploadParameters` option (Antoine du Hamel / #4465)
2023-06-19 15:37:12 +00:00
Antoine du Hamel
13da7caab3
@uppy/aws-s3-multipart: fix the chunk size calculation (#4508)
Co-authored-by: Murderlon <merlijn@soverin.net>
2023-06-19 17:13:26 +02:00
Antoine du Hamel
c687d85b5f
@uppy/aws-s3: add shouldUseMultipart option (#4299)
Co-authored-by: Artur Paikin <artur@arturpaikin.com>
2023-06-19 16:25:43 +02:00
Scott Bessler
29665748c8
@uppy/companion: switch from aws-sdk v2 to @aws-sdk/* (v3) (#4285)
Co-authored-by: Antoine du Hamel <antoine@transloadit.com>
Co-authored-by: Mikael Finstad <finstaden@gmail.com>
2023-06-19 16:02:57 +02:00
LinusMain
38de438864
Migrate all lodash' per-method-packages usage to lodash. (#4274)
Fixes: https://github.com/transloadit/uppy/issues/4272
Co-authored-by: R <r@r.com>
Co-authored-by: Mikael Finstad <finstaden@gmail.com>
Co-authored-by: Antoine du Hamel <antoine@transloadit.com>
2023-06-19 15:45:28 +02:00
Artur Paikin
ad96bdb8ce
@uppy/core: Don't set late (throttled) progress event on a file that is 100% complete (#4507)
Don't set late (throttled) progress event on a file that is 100% complete

Co-authored-by: Antoine du Hamel <antoine@transloadit.com>
2023-06-19 15:11:30 +02:00
Mikael Finstad
46acd009c7
@uppy/companion: revert randomness from file names (#4509)
remove random path part

reverts https://github.com/transloadit/uppy/pull/4489#discussion_r1225535334
2023-06-19 15:10:53 +02:00
Mikael Finstad
8b6e87a168
Custom provider fixes (#4498)
Fixes: https://github.com/transloadit/uppy/issues/4460
2023-06-19 15:08:21 +02:00
Antoine du Hamel
c377379019
@uppy/transloadit: ensure fields is not nullish when there no uploaded files (#4487)
Refs: https://github.com/transloadit/uppy/pull/4059
2023-06-19 15:02:13 +02:00
Artur Paikin
b521a40ebb
When file is removed (or all are canceled), controller.abort queued requests (#4504)
* When file is removed (or all are canceled), controller.abort queued requests

* add controller.abort to all other remote uploaders too

* fix the queue

---------

Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>
2023-06-19 11:28:23 +01:00
Terence C
327655ca7e
@uppy/provider-views: Fix range selection not resetting and computing correctly (#4415)
* Fix range selection not resetting and computing correctly

* Remove comment about deselecting previous selections

* Add range selection to Unsplash — just pass the recordShiftKeyPress prop

---------

Co-authored-by: Artur Paikin <artur@arturpaikin.com>
2023-06-16 10:57:19 +01:00
Antoine du Hamel
71e3f062b7
meta: disallow use of .only in tests (#4494)
It is useful for local testing, but should never be committed. This lint
rule should help catch that during code reviews.
2023-06-15 19:09:57 +01:00
Antoine du Hamel
f07697e7f4
@uppy/companion: fix 500 when file name contains non-ASCII chars (#4493)
* @uppy/companion: fix 500 when file name contains non-ASCII chars

* Update packages/@uppy/companion/src/server/controllers/s3.js

* fixup! @uppy/companion: fix 500 when file name contains non-ASCII chars

* we need a lint rule for this
2023-06-13 22:29:40 +01:00
Samuel De Backer
b8fe961e59
@uppy/locales: update fr_FR.js (#4499)
1. Lang correction : use of "téléverser" in place of "télécharger", because it's the correct translation of "upload", see https://fr.wikipedia.org/wiki/Téléchargement#Vocabulaire_utilisé
2. Typographical changes : '…' in place of '...' and use of 'Apostrophe typographique' : https://fr.wikipedia.org/wiki/Apostrophe_(typographie)
3. Other small corrections.
2023-06-13 20:54:47 +02:00
Artur Paikin
0c931e3e36
Don't close socket while upload is still in progress (#4479)
* Don't close socket while upload is still in progress

* Don't close sockets randomly in AWS S3 either, close on error/cancel

* First send the socket message, then call .abort()
2023-06-12 22:25:04 +01:00
dependabot[bot]
923171538d
meta: bump luxon from 1.28.0 to 1.28.1 (#4497)
Bumps [luxon](https://github.com/moment/luxon) from 1.28.0 to 1.28.1.
- [Changelog](https://github.com/moment/luxon/blob/master/CHANGELOG.md)
- [Commits](https://github.com/moment/luxon/compare/1.28.0...1.28.1)


Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>
2023-06-10 12:12:47 +02:00
Stephen Wooten
b4f3c178dc
@uppy/utils: rename EventTracker -> EventManager (#4481)
Co-authored-by: Stephen Wooten <stephen.wooten@super.mx>
Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>
2023-06-10 12:10:05 +02:00
dependabot[bot]
431fb52e18
meta: bump cookiejar from 2.1.3 to 2.1.4 (#4496)
Bumps [cookiejar](https://github.com/bmeck/node-cookiejar) from 2.1.3 to 2.1.4.
- [Commits](https://github.com/bmeck/node-cookiejar/commits)

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>
2023-06-10 11:55:07 +02:00
Antoine du Hamel
3d59e78e11
meta: make pre-commit use corepack yarn instead of npm run (#4495) 2023-06-10 11:47:23 +02:00
dependabot[bot]
3511a557e3
meta: bump ua-parser-js from 0.7.31 to 0.7.35 (#4474)
* Bump ua-parser-js from 0.7.31 to 0.7.35

Bumps [ua-parser-js](https://github.com/faisalman/ua-parser-js) from 0.7.31 to 0.7.35.
- [Release notes](https://github.com/faisalman/ua-parser-js/releases)
- [Changelog](https://github.com/faisalman/ua-parser-js/blob/master/changelog.md)
- [Commits](https://github.com/faisalman/ua-parser-js/compare/0.7.31...0.7.35)

---
updated-dependencies:
- dependency-name: ua-parser-js
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

* fixup! Bump ua-parser-js from 0.7.31 to 0.7.35

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>
2023-06-10 11:46:13 +02:00
dependabot[bot]
a93626cf2a
meta: bump @sideway/formula from 3.0.0 to 3.0.1 (#4473)
* Bump @sideway/formula from 3.0.0 to 3.0.1

Bumps [@sideway/formula](https://github.com/sideway/formula) from 3.0.0 to 3.0.1.
- [Commits](https://github.com/sideway/formula/compare/v3.0.0...v3.0.1)

---
updated-dependencies:
- dependency-name: "@sideway/formula"
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>

* fixup! Bump @sideway/formula from 3.0.0 to 3.0.1

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>
2023-06-10 11:45:51 +02:00
dependabot[bot]
cd8ea1adb2
meta: bump http-cache-semantics from 4.1.0 to 4.1.1 (#4472)
Bumps [http-cache-semantics](https://github.com/kornelski/http-cache-semantics) from 4.1.0 to 4.1.1.
- [Commits](https://github.com/kornelski/http-cache-semantics/compare/v4.1.0...v4.1.1)

---
updated-dependencies:
- dependency-name: http-cache-semantics
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>
2023-06-10 11:35:15 +02:00
dependabot[bot]
12996dc460
example: update PHP dependencies
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>
2023-06-10 11:27:45 +02:00
Artur Paikin
d979f5cf91
@uppy/companion: Use filename from content-disposition instead of relying on url, with fallback (#4489)
* Use filename from content-disposition instead of relying on url, with fallback

* Update packages/@uppy/companion/src/server/helpers/request.js

* Update packages/@uppy/companion/src/server/helpers/request.js

* Add random string to file name coming from basename in case ?param is a differentiator

* Add e2e test for Companion /url/meta file name + mock server with Content-Disposition

Co-authored-by: Antoine du Hamel <antoine@transloadit.com>

* Update e2e/cypress/integration/dashboard-xhr.spec.ts

Co-authored-by: Mikael Finstad <finstaden@gmail.com>

* Update e2e/mock-server.mjs

Co-authored-by: Antoine du Hamel <antoine@transloadit.com>

* Update package.json

Co-authored-by: Antoine du Hamel <antoine@transloadit.com>

* Update e2e/mock-server.mjs

Co-authored-by: Antoine du Hamel <antoine@transloadit.com>

* Update e2e/cypress/integration/dashboard-xhr.spec.ts

Co-authored-by: Mikael Finstad <finstaden@gmail.com>

* Add comment about why randomUUID is added to file name

* yarn

* res vs response

---------

Co-authored-by: Antoine du Hamel <antoine@transloadit.com>
Co-authored-by: Mikael Finstad <finstaden@gmail.com>
2023-06-09 19:22:20 +01:00
dependabot[bot]
947421b91c
meta: bump babel, esbuild, and vite (#4485)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Antoine du Hamel <duhamelantoine1995@gmail.com>
2023-06-09 12:06:59 +02:00
Artur Paikin
865334faa9
@uppy/dashboard: include the old state when setting new (#4490)
include the old state when setting new
2023-06-09 02:42:15 +01:00
Mikael Finstad
ae49999472
fix companion implicitpath (#4484)
* fix undefined protocol and example page

fixes #4478

* fix companion implicitpath

fixes #4468
2023-06-08 21:30:11 +01:00
Mikael Finstad
da45a2af2d
fix undefined protocol and example page (#4483)
fixes #4478
2023-06-08 19:20:14 +01:00