-
Notifications
You must be signed in to change notification settings - Fork 90
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
@broskoski => Schema for followed artists filter #348
@broskoski => Schema for followed artists filter #348
Conversation
Gravity PR's: https://github.com/artsy/gravity/pull/10200 (filtering by artists you follow), and https://github.com/artsy/gravity/pull/10203 (return counts for followed artists in aggregations) |
Looks good but ❌ |
💚 |
followed_artists_total: { | ||
type: GraphQLInt, | ||
resolve: ({ aggregations }) => aggregations.followed_artists.value, | ||
}, |
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.
Shouldn’t these counts go in a counts
object?
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.
Well, the current total we just expose in the schema, so this just follows that pattern.
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.
Yeah I get that, but I guess that makes sense when there’s only 1 count field. I’m more wondering in general when the best time would be to add a counts
object. Should we do that even if there’s only 1 count field so that it’s clear where subsequent count fields need to go and we don’t need to move API around?
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.
Hmm, not sure the best practices around counts
field, I haven't used them yet.
I'm happy to do whatever, since there is already deployed code that depends on the current schema (as well as a pending Force PR: artsy/force#5344, mind making that an issue that I can tackle 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.
Yeah, in general I think we want to stick to the counts
convention that Master @dzucconi set up, so its always one way. Feel free to follow up in a future PR if it's more complicated to change now though.
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.
Cool, yea let's do it in a subsequent PR, esp since the Force one is merged.
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.
Ah this one is merged. Cool! 👍
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.
@mzikherman Filed a ticket #350
Bump. |
a93b450
to
fabff66
Compare
Needed for Comm filtering 1.6 (artworks by followed artists filter)