This commit improve the error handling for the edge function to add a new source and the worker, so that we get more insights why a request fails. A user will now also get a more detailed error why a source could not be added.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.
## 📋 Pull Request Information
**Original PR:** https://github.com/feeddeck/feeddeck/pull/103
**Author:** [@ricoberger](https://github.com/ricoberger)
**Created:** 12/17/2023
**Status:** ✅ Merged
**Merged:** 12/17/2023
**Merged by:** [@ricoberger](https://github.com/ricoberger)
**Base:** `main` ← **Head:** `improve-error-handling-for-feed-edge-functions`
---
### 📝 Commits (1)
- [`b8f6774`](https://github.com/feeddeck/feeddeck/commit/b8f67743f2f29e295685f49ba0b449ee1e40fcca) [core] Improve Error Handling for Feed Edge Functions
### 📊 Changes
**21 files changed** (+1062 additions, -232 deletions)
<details>
<summary>View changed files</summary>
📝 `supabase/functions/_cmd/worker/worker.ts` (+41 -33)
📝 `supabase/functions/_shared/feed/feed.ts` (+2 -1)
📝 `supabase/functions/_shared/feed/github.ts` (+4 -4)
📝 `supabase/functions/_shared/feed/googlenews.ts` (+7 -14)
📝 `supabase/functions/_shared/feed/lemmy.ts` (+5 -14)
📝 `supabase/functions/_shared/feed/mastodon.ts` (+3 -15)
📝 `supabase/functions/_shared/feed/medium.ts` (+4 -14)
📝 `supabase/functions/_shared/feed/nitter.ts` (+6 -19)
📝 `supabase/functions/_shared/feed/pinterest.ts` (+5 -14)
📝 `supabase/functions/_shared/feed/podcast.ts` (+3 -13)
📝 `supabase/functions/_shared/feed/reddit.ts` (+3 -12)
📝 `supabase/functions/_shared/feed/rss.ts` (+3 -14)
📝 `supabase/functions/_shared/feed/stackoverflow.ts` (+6 -16)
📝 `supabase/functions/_shared/feed/tumblr.ts` (+6 -15)
➕ `supabase/functions/_shared/feed/utils/errors.ts` (+13 -0)
➕ `supabase/functions/_shared/feed/utils/getAndParseFeed.ts` (+63 -0)
📝 `supabase/functions/_shared/feed/utils/index.ts` (+5 -0)
📝 `supabase/functions/_shared/feed/x.ts` (+2 -2)
📝 `supabase/functions/_shared/feed/youtube.ts` (+8 -15)
📝 `supabase/functions/add-source-v1/index.ts` (+50 -17)
_...and 1 more files_
</details>
### 📄 Description
This commit improve the error handling for the edge function to add a new source and the worker, so that we get more insights why a request fails. A user will now also get a more detailed error why a source could not be added.
<!--
Keep PR title verbose enough and add prefix telling about what source it touches e.g "[rss] Add feature xyz" or if the
the PR is not realated to a source use "[core]", e.g. "[core] Fix xyz".
If you add a breaking change within your PR you should add ":warning:" to the title,
e.g. ":warning: [core] My breaking change"
-->
<!--
Description of what have been changed. Please also reference an issue, when available.
-->
---
<sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
📋 Pull Request Information
Original PR: https://github.com/feeddeck/feeddeck/pull/103
Author: @ricoberger
Created: 12/17/2023
Status: ✅ Merged
Merged: 12/17/2023
Merged by: @ricoberger
Base:
main← Head:improve-error-handling-for-feed-edge-functions📝 Commits (1)
b8f6774[core] Improve Error Handling for Feed Edge Functions📊 Changes
21 files changed (+1062 additions, -232 deletions)
View changed files
📝
supabase/functions/_cmd/worker/worker.ts(+41 -33)📝
supabase/functions/_shared/feed/feed.ts(+2 -1)📝
supabase/functions/_shared/feed/github.ts(+4 -4)📝
supabase/functions/_shared/feed/googlenews.ts(+7 -14)📝
supabase/functions/_shared/feed/lemmy.ts(+5 -14)📝
supabase/functions/_shared/feed/mastodon.ts(+3 -15)📝
supabase/functions/_shared/feed/medium.ts(+4 -14)📝
supabase/functions/_shared/feed/nitter.ts(+6 -19)📝
supabase/functions/_shared/feed/pinterest.ts(+5 -14)📝
supabase/functions/_shared/feed/podcast.ts(+3 -13)📝
supabase/functions/_shared/feed/reddit.ts(+3 -12)📝
supabase/functions/_shared/feed/rss.ts(+3 -14)📝
supabase/functions/_shared/feed/stackoverflow.ts(+6 -16)📝
supabase/functions/_shared/feed/tumblr.ts(+6 -15)➕
supabase/functions/_shared/feed/utils/errors.ts(+13 -0)➕
supabase/functions/_shared/feed/utils/getAndParseFeed.ts(+63 -0)📝
supabase/functions/_shared/feed/utils/index.ts(+5 -0)📝
supabase/functions/_shared/feed/x.ts(+2 -2)📝
supabase/functions/_shared/feed/youtube.ts(+8 -15)📝
supabase/functions/add-source-v1/index.ts(+50 -17)...and 1 more files
📄 Description
This commit improve the error handling for the edge function to add a new source and the worker, so that we get more insights why a request fails. A user will now also get a more detailed error why a source could not be added.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.