-
Notifications
You must be signed in to change notification settings - Fork 91
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
MapRoulette Integration #1221
MapRoulette Integration #1221
Conversation
…w displays an empty editor with missing string resources.
@Bonkles my two main questions are: I don't remember personally changing the contents of Do you know why it might have changed? Also, I used maproulette.org and found that their interface DOES have a BBOX feature for challenges, not just tasks. Here's a screenshot of the network tab using a My question is: do you think this might be a feature that is closed to the public? Does it maybe need maproulette.org auth of some kind? EDIT: So that screenshot shows a failed request, but her is |
Okay so in these last few commits I've bypassed a lot of the OsmoseService stuff that does not conform to the data structure of the MapRoulette Tasks that we are showing on the left sidepanel. I finally got it to look like this: The description is not the actual Task description, which is actually named Task Instruction in MapRoulette, but the name of the Parent Challenge of the Task. A lot of tasks (most for what I've seen so far) don't even have an instruction, so I'm forced to use the Parent name to describe them. Question: Should we take a chance and use Challenges instead of Tasks to display on the map? I think the |
Plan: Create a function For this, use |
Here are some preliminary questions for our upcoming meeting today: So I just found the function I already figured out how to extract an "extent" from the TaskCluster plolygon bounding. I'm just going to sort the points of the polygon and get the smallest and biggerst X coordinates. as well as smallest and biggest Y coordinates, to produce the My question here is
Another thing I figure our how to do is determining when to stop zooming in on-click. The maproulette TaskCluster API call will return an array of Cluster JSON objects where all the clusters have only 1 task. This is to know when to display tasks instead of clusters on the map. My other question is
I'd like to use icons with "number of tasks" for clusters, and maybe just a single pointer for tasks when zooming reaches it's end. Just the same way that MapRoulette does it on ther UX Thanks Ben and see you later today! |
Great questions! I think we should focus on getting something land-able for you to focus on- handling tasks, taskGroups, and Challenges will start to get unwieldy pretty fast. Let's try for the following: Just Display challenges only. When clicked, we can display the selected challenge's information in Rapid's sidebar, but also provide a link to view/edit the challenge on MapRoulette.org, a clear call to action to lead the user over there. For the remainder of the cohort, with extra time, you can document your API findings and we can collab on a feature proposal for implementing / doing the rest of this work in future cohorts. That way you can pass all the great API exploration / learning you have been doing onto the next implementer- also an extremely valuable skill to practice! Re: how to display a different map pin- you will see in the on / around line 380 of PixiTextures we have something like:
The formatting is not perfect here in this comment UI but it gets the point across. we draw a shape, give it a style and thickness with This 'graphic' gets coverted to a texture later on in the process. I can walk you through the process of converting a MapRoulette challenge to one of these if you'd like! |
…asks from challenges with non-existent pages still showing up. Should ask MR staffgit add .
@Bonkles this is working for the most part. The buttons to Close or Remove tasks are still non-functional, but they might be easy to implement. My biggest concern atm is that some MapRoulette links seem broken for tasks shown on Rapid. Here are two problems:
I think 1 is a site-wide bug on MR because actually NO task pages seem to be working right now, not even if you navigate to the task from MR's UI itself. As for 2, I'm not sure what's going on. API returns tasks from 17733, yet maproulette.org says 17733 does not exist (???) Maybe the folks at MR will like to have a look at this. |
Oh and that forest link is a tasks I own so you may be running into an issue with access. Before I logged in I got a blank screen. After I logged in I could see it. I'll have to look at what the visibility of that challenge and project is set to. |
@atiannicelli thanks for the info. I have a few questions: The URL I'm using for loading my task list looks like this:
Note the use of This is how I'm trying to filter out tasks whose parent challenge is deleted: by using the Now, this attribute is not detailed at all in https://maproulette.org/docs/swagger-ui/ and is actually not even associated to However, it DOES work for Also, the documentation says this about Challenge status, from /challenge/{id}/tasks/extract Again, this information is extracted from another API call because My hope with using However, If you read the output of https://maproulette.org/api/v2/tasks/box/-71.08040103202916/42.363936378907745/-71.06639896797085/42.375063128349666?sort=parent_id&order=DESC&cStatus=0%2C3 you will notice absolutely all of them have a My question here is: is there a way filter from |
One thing I can do to patch this is to just flag the challenge as "Deleted" on the left side panel of Rapid so the user won't be surprised to find a "Challenge does not exist" page. This would not require me to download every single parent challenge for the tasks lists, because parent challenge information from |
Hmmm, I don't know what the "status" in the challenge response means. That may map to a different set of values for challenges. The data you were looking at is the task status. But I see your issue... Basically you are searching for tasks in a bbox and you get some that are part of a challenge that has been deleted... I would ask on the Map Roulette Slack channel for ideas as to how to filter out tasks that are members of challenges that have been deleted. |
Thanks @atiannicelli , I don't have acces to MR's Slack but I think @Bonkles has access to that Slack channel. |
|
Until they fix the blank page issue (when not logged in) you can change the link to: https://maproulette.org/c/42081 OH, But if you want to jump directly to a task... like I think you probably want to then you are stuck. |
@Bonkles @atiannicelli @tordans here's a gist for a future cohort to continue the work here: https://gist.github.com/voscarmv/8e1e1329dfc56634b0b0dcb67b8b4116 I would appreciate any feedback and comments. Cheers and thanks for the great experience! Happy hacking all! |
moved to #1369 |
Solution to issue #1150
This PR allows users to access the MapRoulette API from Rapid
I started by conforming MaptrouletteService to OsomseService.
_loadStringsAsync()
is missing fromMapRouletteService
and it is needed to populate the_mapRouletteStrings
property that will be used bygetStrings
, which in turn is used byTaskStrings()
inmaproulette_details.js
to display the task details on the sidebar.This PR is a draft.