Cloud Python warehouse snippet omits the import needed by its short-lived-job guidance
Maintainer antworten meist innerhalb von 1 Tag
Bewertung
- Schwierigkeit
- 1/5
- Geschätzter Aufwand
- Unter einer Stunde
- Anfängerfreundlichkeit
- 75/100
- Issue-Typ
- Dokumentation
- Klarheit
- Klar beschrieben
- Aktivitätsstatus
- Aktiv
- Tech-Stack
- python, typescript
- Bereich
- documentation
Rechercherichtung
Das Python-Snippet stammt aus getWarehouseEventSnippets().Python in frontend/web/components/pages/environment-settings/tabs/warehouse-tab/warehouseEventSnippets.ts. Vergleiche die Import-Zeile für Cloud mit dem Zweig für Self-Hosted, der EventProcessorConfig und Flagsmith bereits importiert. Prüfe danach die Anleitung für kurzlebige Jobs, die max_buffer_items=1 verwendet. Fertig ist, wenn die Cloud-Ausgabe beide Symbole importiert, dem Self-Hosted-Stand entspricht und die Anleitung konsistent bleibt. Zur Überprüfung des Texts ist kein Lauf des Python-SDK nötig.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
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
- Vorherrschende Sprache
- Python
- Sterne
- 7.4k
- Forks
- 613
- Ø Merge
- 1 T. 11 Std.
- Gemergte PRs (30 T.)
- 144
Entwicklungsumgebung
- Enthält ein Dockerfile oder eine Docker-Compose-Datei
- Hat eine Pull-Request-Vorlage
- Beitragsleitfaden lesen
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus Flagsmith/flagsmith
-
Action links render in the wrong colour in dark modeEvtl. vergeben @manueldezman hat das heute übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 88/100
Flagsmith/flagsmith#9082 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
Fix Button Alignment in SDK Installation SectionEvtl. vergeben @manueldezman hat das heute übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 62/100
Flagsmith/flagsmith#9056 · 2 Kommentare ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 83/100
Flagsmith/flagsmith#9013 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
Expose whether an organisation is blocked for API usageEvtl. vergeben @PiUnknown hat das vor 35 Tagen übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 62/100
Flagsmith/flagsmith#8773 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 75/100
Maintainer antworten meist innerhalb von 1 Tag
Alle Issues in Flagsmith/flagsmith
Ähnliche Issues
-
flaky: test_fire_returns_thread_per_http_entry_on_head waits 5 s per dispatch worker on busy shardsOffenstatus/accepted type/bug
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 74/100
microsoft/apm#5309 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
bug vector-store
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 85/100
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 74/100
EverMind-AI/Raven#1413 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Tests: parallel pyinstallcheck runs oversubscribe the machine through nested TBB and BLAS poolsEvtl. vergeben Ein verknüpfter Pull Request ist offen oder bereits gemergt. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 86/100
ACCESS-NRI/containerised-environments-infra#143 ·
Maintainer antworten meist innerhalb von 2 Tagen