SS

supabase/splinter

Database management

이 페이지는 AI로 자동 번역되었습니다. 기술적인 세부 사항은 원문을 확인하세요. 원문 보기

294 stars 품질 70 트렌드 21PostgreSQL

supabase/splinter는 https://github.com/supabase/splinter.에서 수입된 대리인 기술 후보입니다

개요

supabase/splinter는 https://github.com/supabase/splinter.에서 수입된 대리인 기술 후보입니다

개요(AI 번역)


문: https://supabase.github.io/splinter

소스 코드: https://github.com/supabase/splinter


Splinter는 Supabase 프로젝트를 위한 lints의 세트를 유지합니다. 일반적인 데이터베이스 스키마 문제를 식별하는 SQL 쿼리를 사용합니다. 일부 lints는 Postgres 프로젝트에 대한 일반적인 목적이며 다른 사람들이 Postgres e.g. auth 및 storage에 데이터를 저장하는 Supabase 기능에 특이합니다.

사용법

프로젝트에만 관심이 있다면, 모든 lints의 최신 버전을 포함하는 단일 쿼리는 splinter에 availble입니다. repo 루트에 sql.

API-exposure 린트 및 pgrst.db_schemas

lints (e.g. auth_users_exposed], materialized_view_in_api], foreign_table_in_api]) Data API를 통해 도달하는 유일한 보고서 객체 - 즉, pgrst.db_schemas 설정에 나열된 스키마의 객체. PostgREST는 런타임에 이 값을 설정하지만, ****는 일반 psql] 연결에 존재합니다.

pgrst.db_schemas가 설정되지 않을 때, 이 lints 기본값은 **public schema만 **. 프로젝트가 추가 스키마를 노출하면 lints를 실행하기 전에 PostgREST config와 일치하는 값을 설정하므로 스키마가 너무 덮여 있습니다

이 페이지는 AI로 자동 번역되었습니다. 기술적인 세부 사항은 원문을 확인하세요.

README

원문 README의 일부입니다. 원문 보기.

splinter (Supabase Postgres LINTER)


Documentation: https://supabase.github.io/splinter

Source Code: https://github.com/supabase/splinter


Splinter maintains a set of lints for Supabase projects. It uses SQL queries to identify common database schema issues. Some lints are general purpose for Postgres projects while others are specific to Supabase features storing their data in Postgres e.g. auth and storage.

Usage

If you are only interested in linting a project, a single query containing the latest version of all lints is availble in splinter.sql in the repo root.

API-exposure lints and pgrst.db_schemas

Several lints (e.g. auth_users_exposed, materialized_view_in_api, foreign_table_in_api) only report objects that are reachable through the Data API — that is, objects in a schema listed in the pgrst.db_schemas setting. PostgREST sets this value at runtime, but it is not present in a plain psql connection.

When pgrst.db_schemas is unset, these lints default to the public schema only. If your project exposes additional schemas, set the value to match your PostgREST config before running the lints so those schemas are covered too:

set pgrst.db_schemas = 'public, graphql_public, ...';

Without this, exposures in non-public schemas will not be reported.

Lint Interface

Each lint creates a view that returns a common interface. The interface is:

  • name (text) not null – Name of the lint
  • title (text) not null – Human readable title of the lint
  • level (text) not null – The level of issue. One of ERROR/WARN/INFO
  • facing (text) not null – Is it an internal (to supabase) or an external (user centric) lint. One of INTERNAL/EXTERNAL
  • categories (text[]) not null – Relevant tags for the issue. Any/All of SECURITY/PERFORMANCE (list may grow)
  • description (text) not null – This is a description of the lint and why its an issue
  • detail (text) not null – A text description of the issue that includes references to the specific table/column/constraint/whatever that fails the lint
  • remediation (text) optional – A reference to documentation to describe the issue and how to resolve it
  • metadata (jsonb) optional – Lint specific information, for example referenced entities, or entity types
GitHub에서 전체 README 보기

추천 도구

다른 키워드를 입력하거나 필터를 제거해 보세요.

설치

npx skillfish add supabase/splinter
MCP 초보자라면? mcpskill.org 가이드부터 시작하세요 →