-
Notifications
You must be signed in to change notification settings - Fork 2
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
feat: feedback analytics and previously submitted answers #3948
Merged
Merged
Changes from 3 commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
24a074e
try again
jamdelion 6896569
Handle previously submitted answers
jamdelion 55ef0bd
Expose feedbackScore separately
jamdelion ab2f1fc
Lint fix
jamdelion 45ea823
Remove feedback.feedbackscore from allow_lists and add usercomment in…
jamdelion d80bd2b
Only include feedback_score in analytics tables
jamdelion 04ba77e
Fix sql - readd application.type
jamdelion File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not entirely sure whether
_feedback.feedbackScore
is needed here, and if it is, whether it is in the right format... Thesql
file does not have_feedback.feedbackScore
in it directly, but seemed to work as it is!e.g. this is from local hasura, analytics table:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry for confusion here! Here's what I'd expect:
"_feedback"
should be included in this list. Dot-separated variables only work when it's the "whole" property name and doesn't require destructuring a passport value, which"_feedback.feedbackScore"
wouldfeedback
column in the raw analytics table will look exactly like you've posted above - a jsonb object !((ls.allow_list_answers -> '_feedback' -> 'feedbackScore'::int))::int AS feedback_score
so that what we're exposing to Metabase is the feedback score as an integer (Metabase can't process jsonb! And free-textuserComments
are nice to track in raw table but aren't very chart-able)Does this make sense?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks Jess, the
int
version you put above (and variations I have tried) caused syntax errors"message": "invalid input syntax for type integer: \"feedbackScore\"",
- I assume the reason it shouldn't be text is because Metabase can make nice charts with numbers and can't convert from string numbers to actual numbers?Have added a column for userComment in the table, and I assume that the feedback column (displaying jsonb) is completely redundant then, given that we now have separate columns for
feedback_score
anduser_comment
. Figuring out a way to drop that column from the view if so!There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.