Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(hogql): fix schema for empty time-to-convert results #20944

Merged
merged 1 commit into from
Mar 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion frontend/src/queries/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -1960,7 +1960,7 @@
"additionalProperties": false,
"properties": {
"average_conversion_time": {
"type": "number"
"type": ["number", "null"]
},
"bins": {
"items": {
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/queries/schema.ts
Original file line number Diff line number Diff line change
Expand Up @@ -713,7 +713,7 @@ type BinNumber = number
export type FunnelStepsResults = Record<string, any>[]
export type FunnelStepsBreakdownResults = Record<string, any>[][]
export type FunnelTimeToConvertResults = {
average_conversion_time: number
average_conversion_time: number | null
bins: [BinNumber, BinNumber][]
}
export type FunnelTrendsResults = Record<string, any>[]
Expand Down
2 changes: 1 addition & 1 deletion posthog/schema.py
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,7 @@ class FunnelTimeToConvertResults(BaseModel):
model_config = ConfigDict(
extra="forbid",
)
average_conversion_time: float
average_conversion_time: Optional[float] = None
bins: List[List[int]]


Expand Down
Loading