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

Issues after #3444 merged #3473

Closed
4 tasks
mifi opened this issue Feb 9, 2022 · 3 comments · Fixed by #3475 or #3498
Closed
4 tasks

Issues after #3444 merged #3473

mifi opened this issue Feb 9, 2022 · 3 comments · Fixed by #3475 or #3498
Labels

Comments

@mifi
Copy link
Contributor

mifi commented Feb 9, 2022

  • npm run dev:with-companion gives error in browser devtools console:
Uncaught TypeError: Cannot read properties of undefined (reading 'replace')
    at Function.initPlugin (uppy/packages/@uppy/companion-client/src/Provider.js:125:72)
    at new GoogleDrive (uppy/packages/@uppy/google-drive/src/index.js:26:14)
    at Uppy.use (uppy/packages/@uppy/core/src/Uppy.js:1383:22)
    at default (:3000/Dashboard.js:70:6)
    at :3000/index.js:9:27
@arturi
Copy link
Contributor

arturi commented Feb 9, 2022

@aduh95 didn’t we say we are using .env.local in root yesterday?

@aduh95
Copy link
Contributor

aduh95 commented Feb 9, 2022

I've opened #3475 to fix the docs, to me there should be only one .env.local file at the root of the repo.

aduh95 added a commit that referenced this issue Feb 14, 2022
And use `pull_request_target` event instead of `pull_request` to use secrets from forks.

Fixes: #3473

Co-authored-by: Mikael Finstad <[email protected]>
@mifi
Copy link
Contributor Author

mifi commented Feb 17, 2022

npm run dev:with-companion and npm run start:companion seemsto be still broken on main.

corepack yarn run start:companion
[nodemon] 2.0.15
[nodemon] to restart at any time, enter `rs`
[nodemon] watching path(s): packages/@uppy/companion/src/**/*
[nodemon] watching extensions: js,mjs,json
[nodemon] starting `node ./packages/@uppy/companion/src/standalone/start-server.js`
companion: 2022-02-17T11:30:02.011Z [warn] startup.secret auto-generating server secret because none was specified
companion: 2022-02-17T11:30:02.013Z [warn] startup.secret auto-generating server secret because none was specified
 Please specify the following options to use companion:
"filePath",
"server.host" 
[nodemon] app crashed - waiting for file changes before starting...

corepack yarn run also gives the same error.

I have COMPANION_DATADIR (filePath) and COMPANION_DOMAIN (server.host) in my .env.local

@mifi mifi reopened this Feb 17, 2022
mifi added a commit that referenced this issue Feb 17, 2022
aduh95 added a commit to aduh95/uppy that referenced this issue Feb 17, 2022
Fixes: transloadit#3473
Co-authored-by: Antoine du Hamel <[email protected]>
Co-authored-by: Mikael Finstad <[email protected]>
aduh95 added a commit that referenced this issue Feb 17, 2022
Fixes: #3473
Co-authored-by: Antoine du Hamel <[email protected]>
Co-authored-by: Mikael Finstad <[email protected]>
arturi pushed a commit that referenced this issue Feb 17, 2022
…mpanion tests (#3478)

* fix broken npm run test

* improve jest / companion

add `npm run test:companion:watch`

move env variables into code to make testing easier
this allows for watching (source is causing problems with npm scripts)
also now we can run `corepack yarn test:companion -t 'single test'`

* fix root project jest

make sure we don't run companion tests on npm run test:unit (as they don't work in a browser/jsdom environment)

* improve validation logic

previously incorrect options gives an Uploader object in an incorrect state

* rewrite uploader to make it more testable

* add test for xhr

* check that metadata values are strings

* fix nested meta

causing error #3477

* convert meta to strings instead

like the official FormData spec does

* fix broken companion dev #3473

* fix botched merge

* fix botched merge and remove --fix

* fix botchedf merge

* quick fix

* .

* remove eslint fix
vymao pushed a commit to vymao/uppy that referenced this issue Mar 29, 2022
HeavenFox pushed a commit to docsend/uppy that referenced this issue Jun 27, 2023
…mpanion tests (transloadit#3478)

* fix broken npm run test

* improve jest / companion

add `npm run test:companion:watch`

move env variables into code to make testing easier
this allows for watching (source is causing problems with npm scripts)
also now we can run `corepack yarn test:companion -t 'single test'`

* fix root project jest

make sure we don't run companion tests on npm run test:unit (as they don't work in a browser/jsdom environment)

* improve validation logic

previously incorrect options gives an Uploader object in an incorrect state

* rewrite uploader to make it more testable

* add test for xhr

* check that metadata values are strings

* fix nested meta

causing error transloadit#3477

* convert meta to strings instead

like the official FormData spec does

* fix broken companion dev transloadit#3473

* fix botched merge

* fix botched merge and remove --fix

* fix botchedf merge

* quick fix

* .

* remove eslint fix
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
3 participants