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

Cluster counts are wrong when filters are enables #7887

Closed
csimpi opened this issue Feb 7, 2019 · 8 comments
Closed

Cluster counts are wrong when filters are enables #7887

csimpi opened this issue Feb 7, 2019 · 8 comments

Comments

@csimpi
Copy link

csimpi commented Feb 7, 2019

mapbox-gl-js version:
v0.53.0
browser:
Chrome

Steps to Trigger Behavior

  1. Add a source with any geojson data
  2. Add a layer with any filter on it
  3. Add clusters
  4. The counting is wrong, the cluster counts the excluded (by filter) items also. It shouldn't

I know similar issues have been reported before, but those from 2016 and I'm hoping right now you will be able to help me or you have found a workaround or this supposed to be a bug. Counting items that are not showing on the map is never will be the excepted behavior.

I know the cluster works on data level and not layer-style level, but still, there should be a solution, really hard to believe that impossible to use the basic filters and clusters in the same time... those both are very basic functions.

Expected Behavior

Count the showed items only

Actual Behavior

Counts items that are not appearing on the map

@mourner
Copy link
Member

mourner commented Feb 8, 2019

Closing as a duplicate of #2613. The layer filtering is working as designed, and data filtering before it gets clustered is tracked in that ticket. As a temporary workaround, you can filter the GeoJSON manually with JavaScript, then use map.getSource('geojson').setData(filteredGeoJSON).

@mourner mourner closed this as completed Feb 8, 2019
@csimpi
Copy link
Author

csimpi commented Feb 8, 2019

@mourner thank you.

The layer filtering is working as designed

The design/concept is wrong then and you should change this.

We are paying customers and that's a shame you just threw me a 2 years old completely dead ticket with a feature label instead of urgent bug or to-do. This is not a feature that the community wants this is a wrong-designed concept that mapbox should change immediately.

Also, this has been reported 2 years ago why didn't you provide a really easy a straightforward shortcut with a filter. Same way as ['has', 'point_count'] filter works why there isn't a ['is','filtered'] or ['is','visible'] filter? This should be a couple of hours working and you would be able to provide a solution for this major issue.

@mourner
Copy link
Member

mourner commented Feb 8, 2019

@csimpi I think it's safe to assume that Mapbox would prefer to loose a paying customer than to deal with entitled abusers who prefer to attack maintainers' competence instead of taking the time to understand the issue and help resolve it.

Here are some helpful resources on how to conduct yourself on an issue tracker of an open source project:

@csimpi
Copy link
Author

csimpi commented Feb 8, 2019

@mourner
What are you talking about? Because I'm talking about a reported issue two years ago without resolution.

I know how to contribute, act politely: I just reported an issue answered the questions, provided sufficient information. I was hoping to find a reliable answer, but you closed it immediately and threw me a two years old dead thread to "track".
With all due respect, you were impolite in the first place and this made me frustrated.

Also, I don't understand that all the time when we report something we are getting the same answer, I should help the developers to solve the problems and send a PR request. I'm not working for mapbox we are paying for the mapbox, despite that, I came here to revive and re-discuss this 2 years old but still actual question (as you can see that others have the same problem) then all you can say is that I'm wrong.

Btw, sorry if this came up like I'm unrespectful, but I can't really handle when I devote time to report an issue (I've also mentioned that I know there are similar issues reported but all of them 2+ years old) then I'm getting pushed to the side. 🙏

@kkaefer
Copy link
Member

kkaefer commented Feb 11, 2019

@csimpi Thanks for reporting this issue. I agree with you that the current behavior can be confusing, but as @mourner points out, this is a duplicate of #2613. If a ticket like this one is open for a while, it doesn't mean that it's "dead". It only means that it hasn't been important enough to all users of Mapbox GL JS to be implemented. Opening a second issue isn't usually a good idea since it spreads out feature requests over multiple tickets instead of putting weight behind a single one.

You're talking about "discussing a fix", yet, you're only expressing discontent with the current behavior and accusing developers of incompetence, which isn't a good base for discussion.

Lastly, this issue tracker is for an open source project, so you should expect being encouraged to contribute to it. For sales and support questions, please turn to https://www.mapbox.com/contact/

@strech345
Copy link

i'm really dissatisfied that this is not possible and also its still opend so long time

@csimpi
Copy link
Author

csimpi commented Jan 28, 2020

@strech345 Yeah, I've got the big speech but nothing has happened then

@petertoth-dev
Copy link

@kkaefer update?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants