Commit Graph
425 Commits
Author SHA1 Message Date
Etienne Stalmans b492341ed1 chore: make MildTomato codeowner of packages (#35558)
* chore: make MildTomato codeowner of packages

* chore: make supabase/design package/ui owners
2025-05-26 13:40:03 +00:00
Charis 419ae4707f chore(docs): bump linter version (#35724) 2025-05-20 11:54:35 -04:00
Jordi EnricandJoshen Lim 6e91494b16 Add coveralls integration (#35424)
* update gh action, update vitest config

* debug

* debug cov

* idk try something different

* test2

* test3

* add base path

* rm debug

* add apiAuthenticate tests

* supabaseClient tests

* apiWrappers tests

* add apiHelpers tests

* add configcat tests

* add formatSql tests

* add github tests

* add cloudprovider utils tests

* add helpers tests

* fix typeerr

* add missing readonly err

* fix typeerrrs

* fix type errors in apiWrapper tests

* fix apiHelpers test

* add packages/ui tests

* add coveralls flags

* try coveralls parallel config

* fix coveralls parallel config

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2025-05-08 12:23:37 +02:00
Charis c136ee4c19 ci (docs): fix docs lint action on forks (#35277)
Before:

The docs lint action doesn't run properly on forks because it tries to
use the branch name to identify the PR for updating, but the branch name is adapted on forks, so it is not `branch-name`, but `forking-account:branch-name`.

After:

Use the PR number instead to identify the PR instead.
2025-04-25 12:02:27 -04:00
Charis 68832f2c00 ci (docs): prevent concurrent search update processes (#35127) 2025-04-21 08:39:37 -04:00
Han Qiao 56f0bb58c5 chore: update docker tag for dependabot (#35037) 2025-04-15 22:28:23 +08:00
Han Qiao 5d8d1f92be fix: format build version for dependabot (#34933) 2025-04-11 18:48:12 +08:00
Stephen Morgan 431be5682b fix: review actions (#34648)
* fix: possible command injection in docs-lint

* fix: explicit permissions for github actions
2025-04-02 16:41:14 +13:00
Kevin Grüneberg c1330d35c0 ci: fix autofix (#34332) 2025-03-22 15:51:01 +01:00
Andrew Valleteau eb7efdef7f chore(studio): move Query to pgMeta add tests (#34232)
* chore(studio): move Query to pgMeta add tests

- Move the Query builder from studio to pgMeta
- Add e2e tests over the generated sql to ensure syntax and runtime
  result over pg database
- fix bug with orde by for table with undefined column

* chore: fix query import path

* chore: set ES target for lint

* chore: add github action for pg-meta test package

* chore: add tsconfig to sparse checkout
2025-03-20 19:04:58 +00:00
Charis 2709fa4a3e feat: pre-compile-time partials (#34028)
Partials are currently defined via MDX includes. This PR switches to pre-compile-time partials, which have a new syntax:

```
<$Partial path="path/to/file.mdx" />
```

## Rationale

This produces two improvements:

1. Partial substitution can occur in pipelines that don't use MDX compilation. For example, we can now do partial substitution before building the search index, so partial content will also be indexed.
2. After the App Router migration, the MDXProviders should've been deprecated, but were kept around for the sole reason of making partials work, and leading to us shipping unnecessary client-side code. We get a minor decrease in overall client bundle size (5.74 MB to 5.6 MB) by getting rid of the Providers.

## Breaking changes

Besides the change to partial syntax, the arguments are also less powerful than before because we are doing string substitution and don't have the full power of JS. Defining string variables is still possible (documented in the Contributing guide), and since that's all we actually do in practice, this shouldn't be too cumbersome. There is always the escape hatch of making a custom component for more complex content reuse cases.
2025-03-18 10:37:39 -04:00
Pamela Chia 2e60c6c9a0 fix: codeowners for telemetry based on team (#34242) 2025-03-17 19:33:14 +01:00
Charis 77b4856ba9 ci(docs): improve linting of external PRs (#34104) 2025-03-11 12:57:49 +01:00
Charis 9080f8e32a ci: docs lint prevent prs hanging (#33819)
Conditional and required checks don't mix well on GitHub -- if a required check is skipped it still hangs, preventing PRs from getting merged indefinitely. Instead, we need to to run the action on every PR, but bail early if no docs content changes were made.

Since the logic for when/how this action runs is getting a bit convoluted, I also split up the tests against master (run against all files, no conditional checks) from the tests aginst PRs (run against changed files, with conditional checks)
2025-02-24 19:40:25 +00:00
Charis a820c56ed0 chore: docs linting (#33574) 2025-02-21 14:13:00 -05:00
Jordi EnricandJoshen Lim b6e126c331 Feat: remember last visited route in logs FE-1418 (#33486)
* add logic to remember last route

* add default redirect

* move logic to index page

* Simplify logs page redirect logic

* missing }

* fix wrong }

* wait 2s for page to redirect

* use latest version in local studio cli test

* rm timeouts looks like it takes longer in ci

* Clean up

* Fix broken commands

---------

Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2025-02-20 14:42:01 +08:00
Joshen Lim ca37f16f58 Chore/refactor e2e tests (#33647)
* Set up E2E tests for staging

* update

* Update

* Update .env.staging.example

* Fix node modules

* Fix

* Attempt to swap local-studio-tests to use the new studio-tests directory

* Omit storage state if running tests for local self host

* Fix test:local command

* Deprecate local-studio-test folder

* Rename local studio tests GH action to E2E test
2025-02-20 12:02:41 +08:00
Beng Eu c2547eec4f fix: hide pnpm update message, it's confusing since the pnpm version is locked; update to pnpm 9.15.4 (#33232) 2025-02-06 14:57:01 +08:00
Charis 2d55512553 chore: activate spelling and admonitions lints for docs (#33292) 2025-02-04 13:18:31 -05:00
Pamela Chia d50fa11757 feat: add homepage click events (#33005)
* feat: add homepage click events

* fix codeowners telemetry filepath
2025-01-22 17:20:47 -08:00
30c390c19c chore: unify telemetry event sending (#32861)
* chore: unify telemetry event sending

* organize some imports

* remove final useTelemetryProps

* add www telemetry actions typing and docs

* remove gaevents

* fix build

* move telemetry identify into PageTelemetry

* fix telemetry constants import

---------

Co-authored-by: Pamela Chia <pamelachiamayyee@gmail.com>
Co-authored-by: Joshen Lim <joshenlimek@gmail.com>
2025-01-22 23:52:32 +08:00
Charis a5daf7cee4 fix: troubleshooting sync workflow (#32778)
Workflow was missed when updating to pnpm
2025-01-14 18:21:17 -05:00
Ivan Vasilov ab3a3b3c76 chore: Move playwright tests to tests/local-studio-tests (#21488)
* Move the playwright package to tests folder.

* Update the workspace list.

* Change the name of the playwright tests to local studio tests.
2025-01-09 12:36:32 +01:00
Wen Bo XieandEtienne Stalmans e6b31c6644 chore: add spam detector to auto-label-issues.yml (#32611)
* chore: add spam detector to auto-label-issues.yml

* Update .github/workflows/auto-label-issues.yml

Co-authored-by: Etienne Stalmans <staaldraad@users.noreply.github.com>

---------

Co-authored-by: Etienne Stalmans <staaldraad@users.noreply.github.com>
2025-01-08 09:45:16 +01:00
Charis 4f6b2be178 fix(ci): comments also appearing on internal prs (#32538) 2025-01-02 23:27:21 +01:00
Charis d21a2a0cbc chore(ci): comment on external PRs (#32529)
Comment on external PRs with some tips for speeding up review process
2025-01-02 16:05:58 -05:00
Ivan Vasilov dd572efb0d chore: Switch repo to use pnpm (#29928)
* Fix some missing and duplicate dependencies.

* Fix the types for jest in ai-commands package.

* Replace all npm commands with pnpm. Add pnpm files and workspace links.

* Fix rimraf to work with pnpm.

* Refactor the github actions to work with pnpm.

* Delete package-lock.json.

* Fix the tailwind configs to not include node_modules.

* Fix random files.

* Add preinstall scripts to all packages.

* Fix the Dockerfile to work with pnpm.

* Update the DEVELOPERS documentation.
2024-12-20 13:07:20 +01:00
Long Hoang 5247a6f7e5 chore: add code owners for event documentation (#31191) 2024-12-17 09:36:09 +01:00
Charis 931d01090b ci: lint docs on push to master (#31176)
Docs lint errors can make it into master through a race condition:

- PR with lint configuration changes is made
- Separately, a PR that is incompatible with the new configuration (but _is_ compatible with the old one) is merged

This can be annoying for downstream PRs, so lint post-merge, and create a PR with auto-fixes if possible.
2024-12-16 17:35:07 -05:00
Charis d69902da94 chore(docs): lint all sections with linter v2 (#31110)
lint(docs): heading capitalization
2024-12-16 14:33:25 -05:00
Charis ba132968cd ci(docs): fix linter v2 pipeline (#30930)
The linter was failing whenever grep turned up empty because pipefail was on, now ignoring grep error so it'll stop erroring on all irrelevant PRs 😵
2024-12-05 15:48:19 +00:00
Charis 4cecae1e09 ci(docs): linter bump version + expand scope (#30860) 2024-12-04 20:37:49 +00:00
Charis 572111224b ci(docs): bump linter + expand linting to auth section (#30704) 2024-11-28 10:26:00 -05:00
419eba99a1 fix(self-hosted): self hosted docker compose (#30674)
* fix(self-host): ensure migrations connect back to postgres database

* fix(self-host): use supabase_admin user for supavisor pooler

* fix(self-host): services healthchecks

* fix(self-host): vector config path

* feat(ci): add smoke test for self-hosted stack

---------

Co-authored-by: Shawal Mbalire <mbalireshawal@gmail.com>
Co-authored-by: Robson Martins <robson@controle.digital>
2024-11-28 11:37:08 +00:00
Charis 78d0755008 docs(ci): expand linter scope (#30678)
Expand linter scope to cover `ai` directory as well.
2024-11-26 14:28:40 -05:00
Charisandgithub-actions[bot] d9a1a615f5 ci: linter v2 (#30480)
PR to start introducing Linter V2!

Primary improvements from this linter:

Better parsing of MDX (fewer false positives)
More flexibility
And suggested autofixes! (see auto-generated PR comment below for how that works)
Turning this on for only a small portion of the repo at first to avoid an avalanche of alerts, will slowly expand from there.

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2024-11-22 15:22:05 -05:00
Charis fe50beb8a5 ci(docs): lint only changed files (#30589) 2024-11-21 17:00:20 -05:00
Han Qiao 1440bf04dc chore: update auth url config for preview (#30544) 2024-11-19 22:41:24 +08:00
Etienne Stalmans 37a9a58880 chore: add security as codeowners (#30432)
Security need to review pages that contain payment processor content, as
per PCI-DSS.
2024-11-14 14:52:26 +01:00
Charisandgithub-tidy-bot 3f08a033d9 fix: autofix action (#30421)
Autofix action is failing with error message:

```
fatal: You are not currently on a branch.
To push the history leading to the current (detached HEAD)
state now, use

    git push origin HEAD:<name-of-remote-branch>
```

This is because the checkout action on a PR by default checks out the merge commit, which is not a branch. Instead, check out [`github.head_ref`](https://docs.github.com/en/actions/writing-workflows/choosing-what-your-workflow-does/accessing-contextual-information-about-workflow-runs#github-context), which will point to the source of the PR.

---------

Co-authored-by: github-tidy-bot <github-tidy-bot@supabase.com>
2024-11-11 16:18:42 -05:00
Charis 4a82aabaf0 feat(docs): sync troubleshooting (#29933)
When a troubleshooting entry is created or updated in this repo, sync it to GitHub. This creates a new troubleshooting discussion if one does not exist, and updates the content on an existing troubleshooting discussion if it has changed.

To preserve the connections between GitHub discussions and Markdown files, record the discussion ID and URL to the database. The database ID is then written to the Markdown file, and a new PR is generated to commit the new Markdown with ID.

There is currently no mechanism to delete outdated discussions. That will be a follow-up.
2024-10-29 12:58:46 -04:00
Charis c2fe11850d feat: embed code samples from github (#29519)
Add the ability to embed code samples from GitHub into tutorials, so we can have a single source of truth for the source code.

Introduces the <$CodeSample /> syntax, which is a special syntax and not a real React component (see the directives/README.md for why on earth I did it this way -- in this specific case, CodeHike adjusts the MDX syntax tree before it gets compiled, and we need to adjust it ourselves before CodeHike sees it, so we need to get down to the level of manipulating the AST in order to make this work with CodeHike).

Adjusted one of the example tutorials to use this new feature as a test.
2024-09-26 15:54:57 -04:00
Charis 182440c9ae chore: remove www redirects from codeownership (#28634)
As discussed on Slack, this unblocks docs PRs, which can be approved by
anyone on the Supabase team.
2024-08-14 10:11:08 -04:00
Charis fc164b5d07 Refactor/app router refs (#28095)
Migrates client SDK References to App Router. (Management and CLI API references aren't migrated yet, nor are self-hosting config references.)

Some notes:

Big changes to the way crawler pages are built and individual section URLs (e.g., javascript/select) are served. All of these used to be SSG-generated pages, but the number of heavy pages was just too much to handle -- slow as molasses and my laptop sounded like it was taking off, and CI sometimes refuses to build it all at all.

Tried various tricks with caching and pre-generating data but no dice.

So I changed to only building one copy of each SDK+version page, then serving the sub-URLs through a response rewrite. That's for the actual user-visible pages.

For the bot pages, each sub-URL needs to be its own page, but prebuilding it doesn't work, and rendering on demand from React components is too slow (looking for super-fast response here for SEO). Instead I changed to using an API route that serves very minimal, hand-crafted HTML. It looks ugly, but it's purely for the search bots.

You can test what bots see by running curl --user-agent "Mozilla/5.0 (iPhone; CPU iPhone OS 6_0 like Mac OS X) AppleWebKit/536.26 (KHTML, like Gecko) Version/6.0 Mobile/10A5376e Safari/8536.25 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)" <URL_OF_PAGE>

Also added some smoke tests to run against prod for the crawler routes, since we don't keep an eye on those regularly, and Vercel config changes could surprise-break them. Tested the meta images on Open Graph and all seems to work fine.

With this approach, full production builds are really fast: ~5 minutes

Starts using the new type spec handling, which is better at finding params automatically, so I could remove some of the manually written ones from the spec files.
2024-08-13 16:12:59 -04:00
Inian 1b4682ed4f Update CODEOWNERS (#28602) 2024-08-13 13:58:39 +00:00
Kevin Grüneberg 4c0278f95b chore: simplify autofix (#28408) 2024-08-06 04:36:05 +00:00
Kevin Grüneberg 2f7331a80d chore: simplify autofix (#28407) 2024-08-06 12:25:21 +08:00
Charis 0772a88e0f ci: remove migration push from search action (#28327)
We don't need this for migration pushes since the Supabase integration will do
it instead. Removing it makes this action less brittle since embedding updates
get blocked on CLI problems.
2024-08-02 13:58:30 -04:00
Kevin Grüneberg 4496c5a9ab chore: only lint in CI, not on Vercel (#28136) 2024-07-23 16:28:52 +08:00
Thor 雷神 Schaeff 5a56fcc60e Update marketing as blog CODEOWNERS (#27853)
* Update CODEOWNERS

* Update .github/CODEOWNERS
2024-07-08 16:26:55 +08:00