-
Notifications
You must be signed in to change notification settings - Fork 23
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
Funnel queries drop timeframes on FunnelSteps #50
Comments
Note that |
Actually, yes, writing However, the problem runs deeper, because as it turns out we don't properly parse timeframes when deserializing to FunnelResultStep. Since the base
So, we should probably make it |
- Change the base class `QueryTimeframe` to interface `IQueryTimeframe`. - Add a `TimeframeConverter` to help with parsing JSON to the appropriate concrete implementation of `IQueryTimeframe`. - Use TimeframeConverter` to also help write `QueryRelativeTimeframe` to JSON. - We are using this new converter to create a URL-encoded JSON array to stuff in the query params for a funnel query, so we no longer drop relative timeframes. - Now we actually parse the timeframe in the `FunnelResultStep`, whether absolute or relative.
Fixed in commit 72c30a0. |
Most places where we use timeframe parameters, (which are now required, and so should no longer be optional in the SDK interface going forward) we handle JSON-ifying the timeframe by doing something like this:
However, when we take an
IEnumberable<FunnelStep>
and try to serialize it, we do this:...which results in the FunnelStep.Timeframe property being written as
{}
.We should either customize JSON formatting for the Timeframe property, or for all
QueryTimeframe
instances across the board, and therefore not need to callToString()
everywhere we encounter one, or at least here inQueries.Funnel()
manually write the JSON for eachFunnelStep
.The text was updated successfully, but these errors were encountered: