feat: use fetch instead of axios for deploy preview #2719

Merged
konrad merged 1 commits from dpschen/frontend:feature/use-fetch-instead-of-axios into main 2022-11-22 13:11:28 +00:00
Member

Since we use > node 18 nothing speaks against removing the axios dependency for the scripts

Since we use > node 18 nothing speaks against removing the axios dependency for the scripts
dpschen added the
dependencies
area/internal-code
labels 2022-11-17 10:57:33 +00:00
dpschen requested review from konrad 2022-11-17 16:36:47 +00:00
konrad was assigned by dpschen 2022-11-17 16:36:50 +00:00
dpschen changed title from WIP: feat: use fetch instead of axios for deploy preview to feat: use fetch instead of axios for deploy preview 2022-11-17 16:36:52 +00:00
Owner

CI fails :/

CI fails :/
Author
Member

Yes, because I changed that file:

+ shasum -a 384 -c ./scripts/deploy-preview-netlify.js.sha384
shasum: WARNING: 1 computed checksum did NOT match
./scripts/deploy-preview-netlify.js: FAILED
Yes, because I changed that file: ``` + shasum -a 384 -c ./scripts/deploy-preview-netlify.js.sha384 shasum: WARNING: 1 computed checksum did NOT match ./scripts/deploy-preview-netlify.js: FAILED ```
Owner

Can you regenerate the checksum?

Can you regenerate the checksum?
dpschen force-pushed feature/use-fetch-instead-of-axios from 1b8c140dfd to 9547a32ece 2022-11-18 13:09:09 +00:00 Compare
Owner

Not sure why the bot did not post the comment here.

Not sure why the bot did not post the comment here.
Author
Member

Not sure why the bot did not post the comment here.

I guess because it was initially not working.

OR because I broke something with the bot in that script?

> Not sure why the bot did not post the comment here. I guess because it was initially not working. _OR_ because I broke something with the bot in that script?
Owner

Not sure, the bot said

Preview comment sent successfully to PR #2719!

in the CI logs https://drone.kolaente.de/vikunja/frontend/11389/1/9

Not sure, the bot said > Preview comment sent successfully to PR #2719! in the CI logs https://drone.kolaente.de/vikunja/frontend/11389/1/9
Author
Member

Not sure, the bot said

Preview comment sent successfully to PR #2719!

in the CI logs https://drone.kolaente.de/vikunja/frontend/11389/1/9

Just saw that. Mhh but I only await the response. I guess I should check response.ok as well. Will add that.

> Not sure, the bot said > > > Preview comment sent successfully to PR #2719! > > in the CI logs https://drone.kolaente.de/vikunja/frontend/11389/1/9 Just saw that. Mhh but I only await the response. I guess I should check `response.ok` as well. Will add that.
dpschen force-pushed feature/use-fetch-instead-of-axios from 9547a32ece to 76c5531287 2022-11-18 14:18:24 +00:00 Compare
Owner

Now there's

Could not send preview comment to PR #2719! HTTP error, status = 422

Now there's > Could not send preview comment to PR #2719! HTTP error, status = 422
Author
Member

Any idea how I can debug this locally?

Any idea how I can debug this locally?
dpschen force-pushed feature/use-fetch-instead-of-axios from 76c5531287 to a8836f2ea4 2022-11-21 17:31:04 +00:00 Compare
dpschen force-pushed feature/use-fetch-instead-of-axios from a8836f2ea4 to 09ac6716ee 2022-11-21 17:42:51 +00:00 Compare
Member

Hi dpschen!

Thank you for creating a PR!

I've deployed the changes of this PR on a preview environment under this URL: https://2719-feature-use-fetch-instead-of-axi--vikunja-frontend-preview.netlify.app

You can use this url to view the changes live and test them out.
You will need to manually connect this to an api running somehwere. The easiest to use is https://try.vikunja.io/.

Have a nice day!

Beep boop, I'm a bot.

Hi dpschen! Thank you for creating a PR! I've deployed the changes of this PR on a preview environment under this URL: https://2719-feature-use-fetch-instead-of-axi--vikunja-frontend-preview.netlify.app You can use this url to view the changes live and test them out. You will need to manually connect this to an api running somehwere. The easiest to use is https://try.vikunja.io/. Have a nice day! > Beep boop, I'm a bot.
Author
Member

Works now.
I had two mistakes:

  • I didn't get that the object with the body inside was already part of the message. I don't use axios often enough and thought that just the string is the message.
  • I didn't JSON.stringify the object.
Works now. I had two mistakes: - I didn't get that the object with the body inside was already part of the message. I don't use axios often enough and thought that just the string is the message. - I didn't `JSON.stringify` the object.
konrad merged commit 93d95b0821 into main 2022-11-22 13:11:28 +00:00
konrad deleted branch feature/use-fetch-instead-of-axios 2022-11-22 13:11:28 +00:00
This repo is archived. You cannot comment on pull requests.
No description provided.