From 91bbea98b1888a66109d8c34c56b47d47dfed8b6 Mon Sep 17 00:00:00 2001 From: 0xflotus <0xflotus@gmail.com> Date: Mon, 14 Nov 2022 15:16:09 +0100 Subject: [PATCH 1/8] Update 2022-10-03-postgres-wasm.mdx --- apps/www/_blog/2022-10-03-postgres-wasm.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/www/_blog/2022-10-03-postgres-wasm.mdx b/apps/www/_blog/2022-10-03-postgres-wasm.mdx index d3108c92b04..ffa7191f864 100644 --- a/apps/www/_blog/2022-10-03-postgres-wasm.mdx +++ b/apps/www/_blog/2022-10-03-postgres-wasm.mdx @@ -147,7 +147,7 @@ We achieve this by mounting a compressed [9P filesystem]( Date: Mon, 14 Nov 2022 15:17:40 +0100 Subject: [PATCH 2/8] Update 2022-10-03-postgres-wasm.mdx --- apps/www/_blog/2022-10-03-postgres-wasm.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/www/_blog/2022-10-03-postgres-wasm.mdx b/apps/www/_blog/2022-10-03-postgres-wasm.mdx index ffa7191f864..826d0edbd8a 100644 --- a/apps/www/_blog/2022-10-03-postgres-wasm.mdx +++ b/apps/www/_blog/2022-10-03-postgres-wasm.mdx @@ -97,7 +97,7 @@ See [source code](https://github.com/snaplet/postgres-browser/tree/main/packages ### Web application -Next, we need to run the the VM inside our browser. How? [WASM](https://en.wikipedia.org/wiki/WebAssembly). +Next, we need to run the VM inside our browser. How? [WASM](https://en.wikipedia.org/wiki/WebAssembly). We use [v86](https://github.com/copy/v86) to run our VM inside the browser. Our demo application is very simple - plain HTML and some basic styling. See [source code](https://github.com/snaplet/postgres-browser/tree/main/packages/pg-browser). From 1a28e77bc39849c58e261d2ab170cb63aaf0cc24 Mon Sep 17 00:00:00 2001 From: 0xflotus <0xflotus@gmail.com> Date: Mon, 14 Nov 2022 15:20:08 +0100 Subject: [PATCH 3/8] Update 2022-10-03-postgres-wasm.mdx --- apps/www/_blog/2022-10-03-postgres-wasm.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/www/_blog/2022-10-03-postgres-wasm.mdx b/apps/www/_blog/2022-10-03-postgres-wasm.mdx index 826d0edbd8a..fc8a139b2ca 100644 --- a/apps/www/_blog/2022-10-03-postgres-wasm.mdx +++ b/apps/www/_blog/2022-10-03-postgres-wasm.mdx @@ -79,7 +79,7 @@ It has a lot of potential though. Some ideas we'll be playing with over the next - **Documentation:** for tutorials and demos. - **Offline data:** running it in the browser for an offline cache, similar to [sql.js](https://sql.js.org/#/) or [absurd-sql](https://github.com/jlongster/absurd-sql). - **Offline data analysis:** using it in a dashboard for offline data analysis and charts. -- **Testing:** testing PostgresSQL functions, triggers, data modeling, logical replication, etc. +- **Testing:** testing PostgreSQL functions, triggers, data modeling, logical replication, etc. - **Dev environments:** use it as a development environment — pull data from production or push new data, functions, triggers, views up to production. - **Snapshots:** create a test version of your database with sample data, then take a snapshot to send to other developers. - **Support:** send snapshots of your database to support personnel to demonstrate an issue you're having. From 2e2e24d75f626719469ae6b6e6ad6dc006c26084 Mon Sep 17 00:00:00 2001 From: 0xflotus <0xflotus@gmail.com> Date: Mon, 14 Nov 2022 15:20:47 +0100 Subject: [PATCH 4/8] Update 2022-09-08-choosing-a-postgres-primary-key.mdx --- apps/www/_blog/2022-09-08-choosing-a-postgres-primary-key.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/www/_blog/2022-09-08-choosing-a-postgres-primary-key.mdx b/apps/www/_blog/2022-09-08-choosing-a-postgres-primary-key.mdx index 6fa24cafbc4..d6f3918bd1a 100644 --- a/apps/www/_blog/2022-09-08-choosing-a-postgres-primary-key.mdx +++ b/apps/www/_blog/2022-09-08-choosing-a-postgres-primary-key.mdx @@ -348,7 +348,7 @@ Unfortunately, `uuid-ossp` isn't *quite* so advanced as to have many of these ne [pg_idkit](https://github.com/t3hmrman/pg_idkit) is built with Rust, so it gives us access to the following ID generation crates: -- [nanoid](https://crates.io/crates/nanoid) (a [well known package](https://www.npmjs.com/package/nanoid) from the the NodeJS ecosystem) +- [nanoid](https://crates.io/crates/nanoid) (a [well known package](https://www.npmjs.com/package/nanoid) from the NodeJS ecosystem) - [ksuid](https://crates.io/crates/ksuid) - [ulid](https://crates.io/crates/ulid) - [rs-snowflake](https://crates.io/crates/rs-snowflake) (Twitter's Snowflake algorithm) From 3d38e6986773d66e748b133187bc61eab97dd316 Mon Sep 17 00:00:00 2001 From: 0xflotus <0xflotus@gmail.com> Date: Mon, 14 Nov 2022 15:24:04 +0100 Subject: [PATCH 5/8] Update 2022-11-02-supabase-beta-update-october-2022.mdx --- apps/www/_blog/2022-11-02-supabase-beta-update-october-2022.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/www/_blog/2022-11-02-supabase-beta-update-october-2022.mdx b/apps/www/_blog/2022-11-02-supabase-beta-update-october-2022.mdx index 3b575fcab3d..3b9b38f8495 100644 --- a/apps/www/_blog/2022-11-02-supabase-beta-update-october-2022.mdx +++ b/apps/www/_blog/2022-11-02-supabase-beta-update-october-2022.mdx @@ -96,7 +96,7 @@ If you want to see +100 other apps, check [the replies](https://twitter.com/supa ## Launch Week 6 date announced -We are ending 2022 on a high note ✊. Mark your calendars: Launch Week 6 is happenning on **December 12-16**. +We are ending 2022 on a high note ✊. Mark your calendars: Launch Week 6 is happening on **December 12-16**. In the meantime, [revisit LW5](https://supabase.com/launch-week). From deb7e914f86b8ce3068ee2e67a7e6eb31be450d8 Mon Sep 17 00:00:00 2001 From: 0xflotus <0xflotus@gmail.com> Date: Mon, 14 Nov 2022 15:25:32 +0100 Subject: [PATCH 6/8] Update 2022-10-14-postgres-full-text-search-vs-the-rest.mdx --- .../_blog/2022-10-14-postgres-full-text-search-vs-the-rest.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/www/_blog/2022-10-14-postgres-full-text-search-vs-the-rest.mdx b/apps/www/_blog/2022-10-14-postgres-full-text-search-vs-the-rest.mdx index f96545c783a..763143a6c6d 100644 --- a/apps/www/_blog/2022-10-14-postgres-full-text-search-vs-the-rest.mdx +++ b/apps/www/_blog/2022-10-14-postgres-full-text-search-vs-the-rest.mdx @@ -348,7 +348,7 @@ _Quentin de Quelen, Meilisearch CEO_ ### Typesense -> Some more context around Typesense's behavior: how loose or exact matches are done are configurable in Typesense. For eg, you can configure the number of typos that are accounted for (num_typos), and when typo tolerance should kick-in, only if a configurable amount of results are not found (typo_tokens_treshold). For multi keyword searches, you can configure Typesense to expand the search by dropping some of the keywords, until at least a configurable number of search results are found (drop_tokens_threshold). +> Some more context around Typesense's behavior: how loose or exact matches are done are configurable in Typesense. For eg, you can configure the number of typos that are accounted for (num_typos), and when typo tolerance should kick-in, only if a configurable amount of results are not found (typo_tokens_threshold). For multi keyword searches, you can configure Typesense to expand the search by dropping some of the keywords, until at least a configurable number of search results are found (drop_tokens_threshold). > We've chosen specifically to keep the search tight because we received feedback from users that some results were confusing if we let the defaults be too loose. _Jason Bosco, Typesense CEO_ From d04e658317cc798169a02114d8660cba841c533f Mon Sep 17 00:00:00 2001 From: 0xflotus <0xflotus@gmail.com> Date: Mon, 14 Nov 2022 16:16:16 +0100 Subject: [PATCH 7/8] Update 2022-11-02-supabase-beta-update-october-2022.mdx (#23) --- apps/www/_blog/2022-11-02-supabase-beta-update-october-2022.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/www/_blog/2022-11-02-supabase-beta-update-october-2022.mdx b/apps/www/_blog/2022-11-02-supabase-beta-update-october-2022.mdx index 3b9b38f8495..f0ae6d632ca 100644 --- a/apps/www/_blog/2022-11-02-supabase-beta-update-october-2022.mdx +++ b/apps/www/_blog/2022-11-02-supabase-beta-update-october-2022.mdx @@ -43,7 +43,7 @@ The Auth team published an in-depth doc explaining how Supabase Auth supports se ![Database Testing with pgTAP](/images/blog/2022-october/database-testing-postgres-pgtap.jpg) -Do you have 100% code coverage? Probably not, because that’s usually the last thing you think of, but *definitely* not if you don’t have database tests. We just shipped a framework for Database Tests which makes it incredibly easy to test your database using pgTAP an pg_prove. +Do you have 100% code coverage? Probably not, because that’s usually the last thing you think of, but *definitely* not if you don’t have database tests. We just shipped a framework for Database Tests which makes it incredibly easy to test your database using pgTAP and pg_prove. [Read the docs](https://supabase.com/docs/guides/database/testing). From 66b93099c64676a36b06e233f52a28c733d7e110 Mon Sep 17 00:00:00 2001 From: 0xflotus <0xflotus@gmail.com> Date: Mon, 14 Nov 2022 16:52:26 +0100 Subject: [PATCH 8/8] Update 2022-09-08-choosing-a-postgres-primary-key.mdx --- .../_blog/2022-09-08-choosing-a-postgres-primary-key.mdx | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/apps/www/_blog/2022-09-08-choosing-a-postgres-primary-key.mdx b/apps/www/_blog/2022-09-08-choosing-a-postgres-primary-key.mdx index d6f3918bd1a..7b96861b886 100644 --- a/apps/www/_blog/2022-09-08-choosing-a-postgres-primary-key.mdx +++ b/apps/www/_blog/2022-09-08-choosing-a-postgres-primary-key.mdx @@ -164,9 +164,9 @@ So how does *this* work? Postgres does the same thing under the covers -- it gen Let's say the application using the DB has some [Python](https://python.org) code like the following: -```sql -import randrange from random -import User from models; +```python +from random import randrange +from models import User MAX_RANDOM_USER_ID = 1_000_000_000 def create_user(): """ @@ -175,7 +175,6 @@ def create_user(): user_id = randrange(1, MAX_RANDOM_USER_ID) user = User(id=user_id, email="new@example.com", name="new user") db.save(user) - ``` That *looks* good, but there's a problem -- [random](https://docs.python.org/3/library/random.html) is a *pseudorandom* generator.