From e7df81c59c4a7b73aa6e61b3810622f2dcc5e086 Mon Sep 17 00:00:00 2001 From: Ansh Goyal Date: Fri, 13 Sep 2024 16:05:38 +0530 Subject: [PATCH 1/4] Update netlify-edge-functions-test.yml --- .github/workflows/netlify-edge-functions-test.yml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/netlify-edge-functions-test.yml b/.github/workflows/netlify-edge-functions-test.yml index 83150c38be0a..55a0b8d4b8a9 100644 --- a/.github/workflows/netlify-edge-functions-test.yml +++ b/.github/workflows/netlify-edge-functions-test.yml @@ -1,7 +1,8 @@ name: Run tests for netlify edge-functions on: - workflow_dispatch + pull_request: + types: [opened, reopened, synchronize, ready_for_review] jobs: netlify-tests: @@ -16,5 +17,5 @@ jobs: with: deno-version: ${{ matrix.deno-version }} - name: Test with Deno - run: deno test --allow-env --trace-ops - \ No newline at end of file + run: deno test --allow-env --trace-ops netlify/**/*.test.ts + From 191edc2c74a0d8e95e80122ff25e627fd9b0fb97 Mon Sep 17 00:00:00 2001 From: Ansh Goyal Date: Fri, 13 Sep 2024 10:48:19 +0000 Subject: [PATCH 2/4] add deno lock --- deno.lock | 151 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 151 insertions(+) create mode 100644 deno.lock diff --git a/deno.lock b/deno.lock new file mode 100644 index 000000000000..130ad70ad964 --- /dev/null +++ b/deno.lock @@ -0,0 +1,151 @@ +{ + "version": "3", + "redirects": { + "https://crux.land/api/get/2KNRVU": "https://crux.land/api/get/2KNRVU.ts", + "https://crux.land/api/get/router@0.0.5": "https://crux.land/api/get/2KNRVU", + "https://crux.land/router@0.0.5": "https://crux.land/api/get/router@0.0.5" + }, + "remote": { + "https://crux.land/api/get/2KNRVU.ts": "6a77d55844aba78d01520c5ff0b2f0af7f24cc1716a0de8b3bb6bd918c47b5ba", + "https://deno.land/std@0.114.0/_util/assert.ts": "2f868145a042a11d5ad0a3c748dcf580add8a0dbc0e876eaa0026303a5488f58", + "https://deno.land/std@0.114.0/datetime/formatter.ts": "bf7befcd2c55c3060be199ebc10e40f9c33aef6141c20f7c781d03beef25a49e", + "https://deno.land/std@0.114.0/datetime/mod.ts": "ddbf54ca8144583cdf16f49b5a69c6b4594215d7b14fef8fecc5ff73911da9e3", + "https://deno.land/std@0.114.0/datetime/tokenizer.ts": "492bb6251e75e0c03d5a89a66bd2b03e08e9cbc298d51e002cf59378aaa32c48", + "https://deno.land/std@0.114.0/http/cookie.ts": "72f6bef1d2a092b1846747dfc00a9764aac7b218eccbdc37ca43dee5973d47c8", + "https://deno.land/std@0.208.0/assert/_constants.ts": "8a9da298c26750b28b326b297316cdde860bc237533b07e1337c021379e6b2a9", + "https://deno.land/std@0.208.0/assert/_diff.ts": "58e1461cc61d8eb1eacbf2a010932bf6a05b79344b02ca38095f9b805795dc48", + "https://deno.land/std@0.208.0/assert/_format.ts": "a69126e8a469009adf4cf2a50af889aca364c349797e63174884a52ff75cf4c7", + "https://deno.land/std@0.208.0/assert/assert_equals.ts": "d8ec8a22447fbaf2fc9d7c3ed2e66790fdb74beae3e482855d75782218d68227", + "https://deno.land/std@0.208.0/assert/assertion_error.ts": "4d0bde9b374dfbcbe8ac23f54f567b77024fb67dbb1906a852d67fe050d42f56", + "https://deno.land/std@0.208.0/assert/equal.ts": "9f1a46d5993966d2596c44e5858eec821859b45f783a5ee2f7a695dfc12d8ece", + "https://deno.land/std@0.208.0/fmt/colors.ts": "34b3f77432925eb72cf0bfb351616949746768620b8e5ead66da532f93d10ba2", + "https://deno.land/x/mock_fetch@0.3.0/mod.ts": "7e7806c65ab17b2b684c334c4e565812bdaf504a3e9c938d2bb52bb67428bc89", + "https://edge-bootstrap.netlify.app/v1/bootstrap/context.ts": "2a9e41ec34256604727ef98dc8038ea4806cdc58a38eafb83bddb2582366f83c", + "https://edge-bootstrap.netlify.app/v1/bootstrap/cookie_store.ts": "bea757a992bfdd732f68704988c693b3d28ab64a827df32ab6f20e37e9c483b6", + "https://edge-bootstrap.netlify.app/v1/bootstrap/edge_function.ts": "e1354df74bd7116896749c5242ff88fdfb258c7c9b3ee9fc15c59a355285a652", + "https://edge-bootstrap.netlify.app/v1/bootstrap/environment.ts": "310fda1b6341d50ba1b7838acd3acdcc883a6c59e30783fa486fa03fa512cd3f", + "https://edge-bootstrap.netlify.app/v1/bootstrap/function_chain.ts": "333f628c5bc41355fea175ce60727e19d080bfd3374f9b36f5a51b9cd4c223b1", + "https://edge-bootstrap.netlify.app/v1/bootstrap/geo.ts": "58ea99beb13514e450154898ab8972354c077ae048e8d67f6c73f9a9ef9b5c6e", + "https://edge-bootstrap.netlify.app/v1/bootstrap/headers.ts": "b78047a219e0073beee1c2a1ae71adaa6ed8980d6d827eaef5ef090d3a8b8464", + "https://edge-bootstrap.netlify.app/v1/bootstrap/request.ts": "e6bc0786756ffe05a21f04197294c771632b3f96b12defb11c18aa0e4e1ecd07", + "https://edge-bootstrap.netlify.app/v1/bootstrap/response.ts": "beac0d12589790a233873439e82c57c019ea1a600609f9658e65a171004dd4fe", + "https://edge-bootstrap.netlify.app/v1/bootstrap/site.ts": "92469673f289c124a9985c7027dc6c166364371b209b5a674aa05d482ad5583b", + "https://edge-bootstrap.netlify.app/v1/index.ts": "7039235c222713929d406e851f1ac93a09f3604d062b284ed46c2b9ea245b1df" + }, + "workspace": { + "packageJson": { + "dependencies": [ + "npm:@chromatic-com/storybook@^1.6.1", + "npm:@docsearch/react@^3.5.2", + "npm:@fec/remark-a11y-emoji@^4.0.2", + "npm:@floating-ui/react-dom-interactions@^0.13.3", + "npm:@heroicons/react@^1.0.6", + "npm:@mailchimp/mailchimp_marketing@^3.0.80", + "npm:@mdx-js/loader@^3.0.1", + "npm:@mdx-js/react@^3.0.1", + "npm:@netlify/functions@^2.6.0", + "npm:@netlify/plugin-nextjs@^4.41.3", + "npm:@next/mdx@^14.1.0", + "npm:@octokit/graphql@^7.0.2", + "npm:@slack/web-api@^7.0.2", + "npm:@storybook/addon-essentials@^8.2.4", + "npm:@storybook/addon-interactions@^8.2.4", + "npm:@storybook/addon-links@^8.2.4", + "npm:@storybook/addon-onboarding@^8.2.4", + "npm:@storybook/blocks@^8.2.4", + "npm:@storybook/nextjs@^8.2.4", + "npm:@storybook/preview-api@^8.2.2", + "npm:@storybook/react@^8.2.4", + "npm:@storybook/test@^8.2.4", + "npm:@tailwindcss/aspect-ratio@^0.4.2", + "npm:@tailwindcss/forms@^0.5.7", + "npm:@tailwindcss/line-clamp@^0.4.4", + "npm:@tailwindcss/typography@^0.5.10", + "npm:@types/lodash@^4.17.0", + "npm:@types/node@^20", + "npm:@types/react-dom@^18", + "npm:@types/react-gtm-module@^2.0.3", + "npm:@types/react-scrollspy@^3.3.9", + "npm:@types/react-syntax-highlighter@^15.5.11", + "npm:@types/react-text-truncate@^0.14.4", + "npm:@types/react-typing-animation@^1.6.6", + "npm:@types/react-youtube-embed@^1.0.4", + "npm:@types/react@^18.0.1", + "npm:@typescript-eslint/eslint-plugin@^6.21.0", + "npm:@typescript-eslint/parser@^6.21.0", + "npm:ajv-formats@^2.1.1", + "npm:ajv@^8.12.0", + "npm:autoprefixer@^10.4.17", + "npm:axios@^1.7.4", + "npm:clsx@^2.1.0", + "npm:cssnano@^6.0.3", + "npm:dedent@^1.5.1", + "npm:dotenv@^16.4.4", + "npm:eslint-config-airbnb-typescript@^17.1.0", + "npm:eslint-config-next@14.1.0", + "npm:eslint-config-prettier@^9.1.0", + "npm:eslint-plugin-jsx-a11y@^6.8.0", + "npm:eslint-plugin-mdx@^3.1.5", + "npm:eslint-plugin-prettier@^5.1.3", + "npm:eslint-plugin-react@^7.33.2", + "npm:eslint-plugin-simple-import-sort@^12.0.0", + "npm:eslint-plugin-storybook@^0.8.0", + "npm:eslint-plugin-tailwindcss@^3.14.2", + "npm:eslint-plugin-unused-imports@^3.1.0", + "npm:eslint@^8", + "npm:fuse.js@^7.0.0", + "npm:googleapis@^133.0.0", + "npm:gray-matter@^4.0.3", + "npm:i18next@^23.12.2", + "npm:inquirer@^9.2.14", + "npm:jest@^29.7.0", + "npm:jgexml@^0.4.4", + "npm:js-cookie@^3.0.5", + "npm:json-schema@^0.4.0", + "npm:lodash@^4.17.21", + "npm:markdown-to-txt@^2.0.1", + "npm:markdown-toc@^1.2.0", + "npm:md5@^2.3.0", + "npm:mermaid@9.3.0", + "npm:moment@^2.30.1", + "npm:next-i18next@^15.3.0", + "npm:next-language-detector@^1.1.0", + "npm:next-mdx-remote@^4.4.1", + "npm:next@14.1.1", + "npm:node-fetch@^2.7.0", + "npm:node-fetch@^3.3.2", + "npm:postcss-import@^16.0.1", + "npm:postcss@^8.4.35", + "npm:prettier@^3.3.3", + "npm:react-dom@^18", + "npm:react-ga@^3.3.1", + "npm:react-gtm-module@^2.0.11", + "npm:react-scrollspy@^3.4.3", + "npm:react-syntax-highlighter@^15.5.0", + "npm:react-text-truncate@^0.19.0", + "npm:react-twitter-embed@^4.0.4", + "npm:react-typist-component@^1.0.6", + "npm:react-youtube-embed@^1.0.3", + "npm:react@^18", + "npm:reading-time@^1.5.0", + "npm:recharts@^2.12.2", + "npm:remark-cli@^12.0.1", + "npm:remark-frontmatter@^5.0.0", + "npm:remark-gemoji-to-emoji@^1.1.0", + "npm:remark-gfm@^4.0.0", + "npm:remark-heading-id@^1.0.1", + "npm:remark-images@^4.0.0", + "npm:remark-lint@^10.0.0", + "npm:remark-mdx@^3.0.1", + "npm:remark-slug@^7.0.1", + "npm:schyma@^1.0.4", + "npm:storybook@^8.2.4", + "npm:swiper@^11.0.7", + "npm:tailwind-merge@^2.2.1", + "npm:tailwindcss@^3.4.3", + "npm:typescript@^5.3.3", + "npm:yaml@^2.3.4" + ] + } + } +} From bc9917ef9a814808691e093b10ba358e3f92e196 Mon Sep 17 00:00:00 2001 From: Ansh Goyal Date: Fri, 13 Sep 2024 10:55:09 +0000 Subject: [PATCH 3/4] denolib to denoland --- .github/workflows/netlify-edge-functions-test.yml | 4 ++-- .gitignore | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/netlify-edge-functions-test.yml b/.github/workflows/netlify-edge-functions-test.yml index 55a0b8d4b8a9..adc110d68ddb 100644 --- a/.github/workflows/netlify-edge-functions-test.yml +++ b/.github/workflows/netlify-edge-functions-test.yml @@ -8,12 +8,12 @@ jobs: netlify-tests: strategy: matrix: - deno-version: [1.30.0] + deno-version: [1.46.0] runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - name: Setup Deno - uses: denolib/setup-deno@v2 + uses: denoland/setup-deno@3a041055d2e2068f6e2c59904ee0ec2dfa9d9665 with: deno-version: ${{ matrix.deno-version }} - name: Test with Deno diff --git a/.gitignore b/.gitignore index 210beb93f6a7..0a69d4de26c5 100644 --- a/.gitignore +++ b/.gitignore @@ -21,3 +21,4 @@ cypress/videos *storybook.log /storybook-static/ coverage +deno.lock From 8486ebd4a7114f6835a7650598d4e440b0d5881a Mon Sep 17 00:00:00 2001 From: Ansh Goyal Date: Fri, 13 Sep 2024 10:55:56 +0000 Subject: [PATCH 4/4] denolib to denoland --- deno.lock | 151 ------------------------------------------------------ 1 file changed, 151 deletions(-) delete mode 100644 deno.lock diff --git a/deno.lock b/deno.lock deleted file mode 100644 index 130ad70ad964..000000000000 --- a/deno.lock +++ /dev/null @@ -1,151 +0,0 @@ -{ - "version": "3", - "redirects": { - "https://crux.land/api/get/2KNRVU": "https://crux.land/api/get/2KNRVU.ts", - "https://crux.land/api/get/router@0.0.5": "https://crux.land/api/get/2KNRVU", - "https://crux.land/router@0.0.5": "https://crux.land/api/get/router@0.0.5" - }, - "remote": { - "https://crux.land/api/get/2KNRVU.ts": "6a77d55844aba78d01520c5ff0b2f0af7f24cc1716a0de8b3bb6bd918c47b5ba", - "https://deno.land/std@0.114.0/_util/assert.ts": "2f868145a042a11d5ad0a3c748dcf580add8a0dbc0e876eaa0026303a5488f58", - "https://deno.land/std@0.114.0/datetime/formatter.ts": "bf7befcd2c55c3060be199ebc10e40f9c33aef6141c20f7c781d03beef25a49e", - "https://deno.land/std@0.114.0/datetime/mod.ts": "ddbf54ca8144583cdf16f49b5a69c6b4594215d7b14fef8fecc5ff73911da9e3", - "https://deno.land/std@0.114.0/datetime/tokenizer.ts": "492bb6251e75e0c03d5a89a66bd2b03e08e9cbc298d51e002cf59378aaa32c48", - "https://deno.land/std@0.114.0/http/cookie.ts": "72f6bef1d2a092b1846747dfc00a9764aac7b218eccbdc37ca43dee5973d47c8", - "https://deno.land/std@0.208.0/assert/_constants.ts": "8a9da298c26750b28b326b297316cdde860bc237533b07e1337c021379e6b2a9", - "https://deno.land/std@0.208.0/assert/_diff.ts": "58e1461cc61d8eb1eacbf2a010932bf6a05b79344b02ca38095f9b805795dc48", - "https://deno.land/std@0.208.0/assert/_format.ts": "a69126e8a469009adf4cf2a50af889aca364c349797e63174884a52ff75cf4c7", - "https://deno.land/std@0.208.0/assert/assert_equals.ts": "d8ec8a22447fbaf2fc9d7c3ed2e66790fdb74beae3e482855d75782218d68227", - "https://deno.land/std@0.208.0/assert/assertion_error.ts": "4d0bde9b374dfbcbe8ac23f54f567b77024fb67dbb1906a852d67fe050d42f56", - "https://deno.land/std@0.208.0/assert/equal.ts": "9f1a46d5993966d2596c44e5858eec821859b45f783a5ee2f7a695dfc12d8ece", - "https://deno.land/std@0.208.0/fmt/colors.ts": "34b3f77432925eb72cf0bfb351616949746768620b8e5ead66da532f93d10ba2", - "https://deno.land/x/mock_fetch@0.3.0/mod.ts": "7e7806c65ab17b2b684c334c4e565812bdaf504a3e9c938d2bb52bb67428bc89", - "https://edge-bootstrap.netlify.app/v1/bootstrap/context.ts": "2a9e41ec34256604727ef98dc8038ea4806cdc58a38eafb83bddb2582366f83c", - "https://edge-bootstrap.netlify.app/v1/bootstrap/cookie_store.ts": "bea757a992bfdd732f68704988c693b3d28ab64a827df32ab6f20e37e9c483b6", - "https://edge-bootstrap.netlify.app/v1/bootstrap/edge_function.ts": "e1354df74bd7116896749c5242ff88fdfb258c7c9b3ee9fc15c59a355285a652", - "https://edge-bootstrap.netlify.app/v1/bootstrap/environment.ts": "310fda1b6341d50ba1b7838acd3acdcc883a6c59e30783fa486fa03fa512cd3f", - "https://edge-bootstrap.netlify.app/v1/bootstrap/function_chain.ts": "333f628c5bc41355fea175ce60727e19d080bfd3374f9b36f5a51b9cd4c223b1", - "https://edge-bootstrap.netlify.app/v1/bootstrap/geo.ts": "58ea99beb13514e450154898ab8972354c077ae048e8d67f6c73f9a9ef9b5c6e", - "https://edge-bootstrap.netlify.app/v1/bootstrap/headers.ts": "b78047a219e0073beee1c2a1ae71adaa6ed8980d6d827eaef5ef090d3a8b8464", - "https://edge-bootstrap.netlify.app/v1/bootstrap/request.ts": "e6bc0786756ffe05a21f04197294c771632b3f96b12defb11c18aa0e4e1ecd07", - "https://edge-bootstrap.netlify.app/v1/bootstrap/response.ts": "beac0d12589790a233873439e82c57c019ea1a600609f9658e65a171004dd4fe", - "https://edge-bootstrap.netlify.app/v1/bootstrap/site.ts": "92469673f289c124a9985c7027dc6c166364371b209b5a674aa05d482ad5583b", - "https://edge-bootstrap.netlify.app/v1/index.ts": "7039235c222713929d406e851f1ac93a09f3604d062b284ed46c2b9ea245b1df" - }, - "workspace": { - "packageJson": { - "dependencies": [ - "npm:@chromatic-com/storybook@^1.6.1", - "npm:@docsearch/react@^3.5.2", - "npm:@fec/remark-a11y-emoji@^4.0.2", - "npm:@floating-ui/react-dom-interactions@^0.13.3", - "npm:@heroicons/react@^1.0.6", - "npm:@mailchimp/mailchimp_marketing@^3.0.80", - "npm:@mdx-js/loader@^3.0.1", - "npm:@mdx-js/react@^3.0.1", - "npm:@netlify/functions@^2.6.0", - "npm:@netlify/plugin-nextjs@^4.41.3", - "npm:@next/mdx@^14.1.0", - "npm:@octokit/graphql@^7.0.2", - "npm:@slack/web-api@^7.0.2", - "npm:@storybook/addon-essentials@^8.2.4", - "npm:@storybook/addon-interactions@^8.2.4", - "npm:@storybook/addon-links@^8.2.4", - "npm:@storybook/addon-onboarding@^8.2.4", - "npm:@storybook/blocks@^8.2.4", - "npm:@storybook/nextjs@^8.2.4", - "npm:@storybook/preview-api@^8.2.2", - "npm:@storybook/react@^8.2.4", - "npm:@storybook/test@^8.2.4", - "npm:@tailwindcss/aspect-ratio@^0.4.2", - "npm:@tailwindcss/forms@^0.5.7", - "npm:@tailwindcss/line-clamp@^0.4.4", - "npm:@tailwindcss/typography@^0.5.10", - "npm:@types/lodash@^4.17.0", - "npm:@types/node@^20", - "npm:@types/react-dom@^18", - "npm:@types/react-gtm-module@^2.0.3", - "npm:@types/react-scrollspy@^3.3.9", - "npm:@types/react-syntax-highlighter@^15.5.11", - "npm:@types/react-text-truncate@^0.14.4", - "npm:@types/react-typing-animation@^1.6.6", - "npm:@types/react-youtube-embed@^1.0.4", - "npm:@types/react@^18.0.1", - "npm:@typescript-eslint/eslint-plugin@^6.21.0", - "npm:@typescript-eslint/parser@^6.21.0", - "npm:ajv-formats@^2.1.1", - "npm:ajv@^8.12.0", - "npm:autoprefixer@^10.4.17", - "npm:axios@^1.7.4", - "npm:clsx@^2.1.0", - "npm:cssnano@^6.0.3", - "npm:dedent@^1.5.1", - "npm:dotenv@^16.4.4", - "npm:eslint-config-airbnb-typescript@^17.1.0", - "npm:eslint-config-next@14.1.0", - "npm:eslint-config-prettier@^9.1.0", - "npm:eslint-plugin-jsx-a11y@^6.8.0", - "npm:eslint-plugin-mdx@^3.1.5", - "npm:eslint-plugin-prettier@^5.1.3", - "npm:eslint-plugin-react@^7.33.2", - "npm:eslint-plugin-simple-import-sort@^12.0.0", - "npm:eslint-plugin-storybook@^0.8.0", - "npm:eslint-plugin-tailwindcss@^3.14.2", - "npm:eslint-plugin-unused-imports@^3.1.0", - "npm:eslint@^8", - "npm:fuse.js@^7.0.0", - "npm:googleapis@^133.0.0", - "npm:gray-matter@^4.0.3", - "npm:i18next@^23.12.2", - "npm:inquirer@^9.2.14", - "npm:jest@^29.7.0", - "npm:jgexml@^0.4.4", - "npm:js-cookie@^3.0.5", - "npm:json-schema@^0.4.0", - "npm:lodash@^4.17.21", - "npm:markdown-to-txt@^2.0.1", - "npm:markdown-toc@^1.2.0", - "npm:md5@^2.3.0", - "npm:mermaid@9.3.0", - "npm:moment@^2.30.1", - "npm:next-i18next@^15.3.0", - "npm:next-language-detector@^1.1.0", - "npm:next-mdx-remote@^4.4.1", - "npm:next@14.1.1", - "npm:node-fetch@^2.7.0", - "npm:node-fetch@^3.3.2", - "npm:postcss-import@^16.0.1", - "npm:postcss@^8.4.35", - "npm:prettier@^3.3.3", - "npm:react-dom@^18", - "npm:react-ga@^3.3.1", - "npm:react-gtm-module@^2.0.11", - "npm:react-scrollspy@^3.4.3", - "npm:react-syntax-highlighter@^15.5.0", - "npm:react-text-truncate@^0.19.0", - "npm:react-twitter-embed@^4.0.4", - "npm:react-typist-component@^1.0.6", - "npm:react-youtube-embed@^1.0.3", - "npm:react@^18", - "npm:reading-time@^1.5.0", - "npm:recharts@^2.12.2", - "npm:remark-cli@^12.0.1", - "npm:remark-frontmatter@^5.0.0", - "npm:remark-gemoji-to-emoji@^1.1.0", - "npm:remark-gfm@^4.0.0", - "npm:remark-heading-id@^1.0.1", - "npm:remark-images@^4.0.0", - "npm:remark-lint@^10.0.0", - "npm:remark-mdx@^3.0.1", - "npm:remark-slug@^7.0.1", - "npm:schyma@^1.0.4", - "npm:storybook@^8.2.4", - "npm:swiper@^11.0.7", - "npm:tailwind-merge@^2.2.1", - "npm:tailwindcss@^3.4.3", - "npm:typescript@^5.3.3", - "npm:yaml@^2.3.4" - ] - } - } -}