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 TypeError on the top page #107

Closed
13 tasks done
sinproject-iwasaki opened this issue Jul 26, 2023 · 1 comment · Fixed by #205
Closed
13 tasks done

Fix TypeError on the top page #107

sinproject-iwasaki opened this issue Jul 26, 2023 · 1 comment · Fixed by #205
Assignees
Labels
bug Something isn't working

Comments

@sinproject-iwasaki
Copy link
Contributor

sinproject-iwasaki commented Jul 26, 2023

Tasks

  • Fix TypeError on the top page

Uncaught (in promise) TypeError: Failed to execute 'put' on 'Cache': Request scheme 'chrome-extension' is unsupported
at respond (service-worker.js:53:11)

Writing the Issue

  • Write each task for this issue using checkboxes
  • Write all verbal instructions as tasks
  • Add labels and assignees

Before Working on the Issue

  • Assign yourself
  • Share your screen on Discord
  • Write which issue you are starting on Slack
  • Git: Fetch the latest main
  • Git: Create a branch with the name of the issue

Pre-PR Checks

  • Insure that changes include only what is necessary for this PR
  • Implement necessary Unit tests
  • Implement necessary E2E tests
  • Perform functionality checks
@sinproject-iwasaki sinproject-iwasaki added the bug Something isn't working label Jul 26, 2023
gottu91-code added a commit that referenced this issue Aug 7, 2023
gottu91-code added a commit that referenced this issue Aug 7, 2023
@gottu91-code gottu91-code self-assigned this Aug 7, 2023
@gottu91-code
Copy link
Collaborator

gottu91-code commented Aug 7, 2023

エラーが出ていた原因

Service Workerで許可されていないリクエストURL(chrome-extension:// を含むURL)を処理しようとしていたため。

下記のようにchrome拡張機能から発生するリクエストはService Workerで許可されていないためエラーが出る。
chrome-extension://cofdbpoegempjloogbagkncekinflcnj/fonts/OpenSans_VariableFont_wdth_wght.ttf

下記のようなリクエストURLは問題なく処理できる。
http://localhost:5173/src/routes/+layout.svelte
https://sinpro.dev/docs/concurrency

参考になった記事

Service Worker TypeError when opening Chrome extension
Uncaught (in promise) TypeError: Request scheme 'chrome-extension' is unsupported #1
ServiceWorkerをサクッと導入してみた
Service Workerについて調べたのでメモ

備考

現環境でもchrome拡張機能をすべてオフにすると、エラーが非表示となります。

gottu91-code added a commit that referenced this issue Aug 7, 2023
sinproject-iwasaki added a commit that referenced this issue Aug 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants