Cloud Python warehouse snippet omits the import needed by its short-lived-job guidance
I maintainer di solito rispondono entro 1 giorno
Valutazione
- Difficoltà
- 1/5
- Tempo stimato
- Meno di un'ora
- Idoneità per principianti
- 75/100
- Tipo di issue
- Documentazione
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Attiva
- Stack tecnologico
- python, typescript
- Ambito
- documentation
Direzione di ricerca
Lo snippet Python proviene da getWarehouseEventSnippets().Python in frontend/web/components/pages/environment-settings/tabs/warehouse-tab/warehouseEventSnippets.ts. Confronta la riga di import di Cloud con il ramo self-hosted, che importa già EventProcessorConfig e Flagsmith, quindi controlla le indicazioni per i job di breve durata che usano max_buffer_items=1. È completato quando l'output di Cloud importa entrambi i simboli, come self-hosted, e le indicazioni restano coerenti. Per verificare il testo non serve eseguire l'SDK Python.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Hullo folks,
I’m doing some research for Tessl Code Review and ran it against your repo. It flagged a potential issue, and I figured it made sense to share it with you:
Describe the bug
The Cloud Python warehouse example advises short-lived scripts to use EventProcessorConfig(max_buffer_items=1), but its import only includes Flagsmith. A user applying that advice needs an additional import that the example does not show.
This is a small documentation/snippet issue, rather than a claim that the unchanged snippet itself raises an exception.
Steps to reproduce
At be2bd72, call getWarehouseEventSnippets().Python in warehouseEventSnippets.ts. The emitted text starts with:
from flagsmith import Flagsmith
It later recommends passing max_buffer_items=1 to EventProcessorConfig for short-lived scripts and jobs. Applying that recommendation in the constructor introduces a name that was never imported:
flagsmith = Flagsmith(
environment_key="YOUR_ENVIRONMENT_KEY",
enable_events=True,
event_processor_config=EventProcessorConfig(max_buffer_items=1),
)
Expected behavior
Include EventProcessorConfig in the Cloud import, or show the extra import and constructor option together in the short-lived-job guidance. The self-hosted variant already imports both symbols.
Validation
I executed the current TypeScript generator with no argument (Cloud) and with self-hosted URLs. Cloud emitted only Flagsmith; self-hosted emitted EventProcessorConfig, Flagsmith. Both emitted the short-lived-job guidance. I did not run the Python SDK, send events, or test a deployed Flagsmith instance.
The lead came from a retrospective Tessl review and I checked the generated output against current source. Happy to adjust if the intended example usage is different.
Full transparency: I work at Tessl, and we've spotted that using Tessl Code Review - using repository-level context and specific review lenses that improve over time through feedback. That’s how this finding surfaced.
We’re just getting started and want to offer the tool free to open-source projects. If this is useful, happy to give you access.
Bap
- Lingua principale
- Python
- Stelle
- 7.4k
- Fork
- 613
- Merge medio
- 1g 11h
- PR unite (30g)
- 144
Preparare l'ambiente
- Include un Dockerfile o un file Docker Compose
- Ha un modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di Flagsmith/flagsmith
-
Action links render in the wrong colour in dark modeForse già presa @manueldezman l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
Flagsmith/flagsmith#9082 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Fix Button Alignment in SDK Installation SectionForse già presa @manueldezman l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
Flagsmith/flagsmith#9056 · 2 commenti ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 83/100
Flagsmith/flagsmith#9013 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Expose whether an organisation is blocked for API usageForse già presa @PiUnknown l’ha presa 35 giorni fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
Flagsmith/flagsmith#8773 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di Flagsmith/flagsmith
Issue simili
-
flaky: test_fire_returns_thread_per_http_entry_on_head waits 5 s per dispatch worker on busy shardsApertastatus/accepted type/bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
microsoft/apm#5309 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
bug vector-store
Difficoltà 2/5 1-3 ore Idoneità per principianti 85/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
EverMind-AI/Raven#1413 ·
I maintainer di solito rispondono entro 1 giorno
-
Tests: parallel pyinstallcheck runs oversubscribe the machine through nested TBB and BLAS poolsForse già presa Una pull request collegata a questa issue è aperta o già unita. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 86/100
ACCESS-NRI/containerised-environments-infra#143 ·
I maintainer di solito rispondono entro 2 giorni