47fac22230
- .claude/CLAUDE.md - .claude/commands/subagentes.md - .claude/rules/INDEX.md - .mcp.json - bash/functions/cybersecurity/analyze_dns.md - bash/functions/cybersecurity/audit_http_headers.md - bash/functions/cybersecurity/audit_ssh_config.md - bash/functions/cybersecurity/check_firewall.md - bash/functions/cybersecurity/detect_suspicious_users.md - bash/functions/cybersecurity/encrypt_file.md - ... Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2.1 KiB
2.1 KiB
name, kind, lang, domain, version, purity, signature, description, tags, uses_functions, uses_types, returns, returns_optional, error_type, imports, params, output, tested, tests, test_file_path, file_path
| name | kind | lang | domain | version | purity | signature | description | tags | uses_functions | uses_types | returns | returns_optional | error_type | imports | params | output | tested | tests | test_file_path | file_path | ||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| bq_create_dataset | function | py | infra | 1.0.0 | impure | def bq_create_dataset(client: BQClient, dataset_id: str, location: str = 'US', description: str = '', labels: dict[str, str] | None = None, default_table_expiration_ms: int = 0) -> dict | Crea un dataset en Google BigQuery con ubicacion, descripcion y labels. Usa client._client.create_dataset() del SDK oficial. |
|
false | error_go_core |
|
|
dict con dataset_id, project, full_id, location, description, labels, created, modified, default_table_expiration_ms | false | python/functions/bigquery/datasets.py |
Ejemplo
from bigquery.client import bq_auth
from bigquery.datasets import bq_create_dataset
client = bq_auth("my-project")
ds = bq_create_dataset(
client,
"analytics",
location="EU",
description="Data warehouse principal",
labels={"env": "prod", "team": "data"},
)
print(ds["full_id"], ds["location"])
# my-project.analytics EU
Notas
Lanza google.api_core.exceptions.Conflict (409) si el dataset ya existe.
El full_id tiene formato {project}.{dataset_id} y puede usarse directamente como referencia en otras llamadas al SDK.
default_table_expiration_ms aplica a todas las tablas nuevas del dataset; las tablas existentes no se ven afectadas.