CityOfBoston / CityWorker-issues-Incapsulate

Archived for legacy purposes
0 stars 0 forks source link

Slow status change for traffic signal inspection #9

Closed mlevans closed 6 years ago

mlevans commented 7 years ago

I submitted a request for a traffic signal inspection, but it is not switching its status to open. Is this expected?

submitted-status-change

jqr commented 7 years ago

This is a great catch and a serious issue.

This appears to be an area of misconfiguration within Salesforce/Incapsulate. We're getting conflicting information on the required fields.

When querying for the service TFCSGNINSP, we see that it has 0 required fields. Also note that there is no mention of ST-POLE which will come into play shortly.

JSON for `TFCSGNINSP` ```json { "service_code": "TFCSGNINSP", "attributes": [ { "required": false, "datatype": "singlevaluelist", "datatype_description": null, "order": 1, "description": "Is it a traffic or pedestrian signal?", "code": "SIGN-TYPEPROB", "variable": true, "values": [ { "key": "Traffic Signal", "name": "Traffic Signal" }, { "key": "Pedestrian Signal", "name": "Pedestrian Signal" } ] }, { "required": false, "datatype": "singlevaluelist", "datatype_description": null, "order": 2, "description": "What is the problem with the traffic signal?", "code": "SIGN-TRAFFPROB", "variable": true, "values": [ { "key": "No Working Lights", "name": "No Working Lights" }, { "key": "Flashing/Blinking Light is not changing", "name": "Flashing/Blinking Light is not changing" }, { "key": "Pedestrian Indicator Not Working", "name": "Pedestrian Indicator Not Working" }, { "key": "Pedestrian Button Not Working", "name": "Pedestrian Button Not Working" }, { "key": "Controller/Timing Issues", "name": "Controller/Timing Issues" }, { "key": "Indicator Facing Wrong Direction", "name": "Indicator Facing Wrong Direction" }, { "key": "Other", "name": "Other" } ], "dependencies": { "clause": "OR", "conditions": [ { "attribute": "SIGN-TYPEPROB", "op": "eq", "value": "Traffic Signal" } ] } }, { "required": false, "datatype": "string", "datatype_description": "Please enter any other relevant information.", "order": 3, "description": "Please provide any other relevant information:", "code": "ST-CMTS1", "variable": true, "dependencies": { "clause": "OR", "conditions": [ { "attribute": "SIGN-TRAFFPROB", "op": "eq", "value": "Other" } ] } } ], "service_name": "Traffic Signal Inspection", "description": "Request that we replace or repair a traffic signal.", "activities": [ { "code": "TFCSGNINSP-INSP", "name": "Inspect Traffic Signal", "description": null, "required": false, "optional": false, "next_activity_code": null, "order": 1, "service_level_agreement": { "type": "Hours", "value": 24 }, "outcomes": [ { "code": "NOTHFOUND", "description": "Nothing Found", "action": "Close", "can_close_service_request": true, "comment_required": null, "order": 1, "responses": [ ], "attributes": [ ] }, { "code": "STO311", "description": "Send to 311", "action": "Reallocate", "can_close_service_request": false, "comment_required": null, "order": 2, "responses": [ ], "attributes": [ ] }, { "code": "TFCSGNINSP-MADESAFEA", "description": "Made Safe - Additional Work Needed", "action": "Close", "can_close_service_request": true, "comment_required": null, "order": 3, "responses": [ ], "attributes": [ ] }, { "code": "TRANSF", "description": "Transfer", "action": "Transfer", "can_close_service_request": false, "comment_required": null, "order": 4, "responses": [ ], "attributes": [ ] }, { "code": "TFCSGN-REPRD", "description": "Traffic Signal Repaired", "action": "Close", "can_close_service_request": true, "comment_required": null, "order": 5, "responses": [ ], "attributes": [ ] } ] } ], "definitions": { "service_departments": [ ], "service_categories": [ { "code": "Lights", "name": "Lights", "description": "Lights 311" } ] }, "service_level_agreement": { "type": "Business Days", "value": 1 }, "keywords": "Traffic Signal Inspection", "group": "Streets, Sidewalks, Traffic, and Vehicles", "metadata": true, "type": "realtime", "reallocate_queues": [ { "id": "00Gr0000000XANMEA4", "name": "BOS311 Reallocation From Dept", "members": [ ] } ] } ```

But when we attempt to submit this data to Incapsulate, we get the following error:

[
  {
    "description": "\"Is the pole knocked down?\" (ST-POLE) is required - 35", 
    "code": 1
  }
]

So a field(ST-POLE) is required, but we have no record of it, the type, the values, etc. Consequently, the system has no way to proceed forward and will continue to try and submit the data into Incapsulate until they accept it.

This should be taken up with Salesforce/Incapsulate teams to resolve.

jqr commented 7 years ago

And to clarify on the user-facing issue in Spot Workforce. The Submitted state means "we've accepted your data, but haven't been able to push it upstream yet, so the Ticket isn't workable". So I think that fits the situation pretty well.

Ideally we would detect permanent failures at this level and show something directly to the user, but there is no reliable way to detect this state yet. Hopefully when response codes beyond 200 and 401 are supported in Incapsulate, we can designate one of them to this situation for better handling.

mlevans commented 7 years ago

It looks like the same issue is happening with this new pothole request:

pothole-submitted

mlevans commented 7 years ago

This is also happening with some sidewalk repair requests.

Edit: This is also happening with Abandoned Bicycle, General Request, and New Tree requests.

karthikakula commented 7 years ago

@vanessacalderon As discussed during our call this morning. We will have to review the configuration of all the Flex Questions and Service Type Questions. Eric can work with you on this and will be able to create more reports for you as needed.

vanessacalderon commented 7 years ago

I fixed all of these by checking the allow web citizen web intake and putting CW in Chosen column of integrators at the question level. I created a traffic signal inspection SR and it is still in Submitted Status. I think there another issue going on-- @karthikakula

jqr commented 6 years ago

I just verified this was working using TFCSGNINSP (Traffic signal is broken) and saw the required question about being knocked down. Answering that question and pressing submit definitely worked for me. Ticket 17-00010207.

@vanessacalderon I think this needs to be revalidated.

vanessacalderon commented 6 years ago

just tested Traffic signal is broken. I did answer the required question and I got a message that it was required. All 4 questions were displayed that were public. The 5th one was not, which is good.

The only issue is that the 2 SRs I created are in Submitted status.

On Mon, Dec 4, 2017 at 12:35 PM, Elijah Miller notifications@github.com wrote:

I just verified this was working using TFCSGNINSP (Traffic signal is broken) and saw the required question about being knocked down. Answering that question and pressing submit definitely worked for me. Ticket 17-00010207 https://bos311--devint2.cs32.my.salesforce.com/500r0000003JJEz.

@vanessacalderon https://github.com/vanessacalderon I think this needs to be revalidated.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/CityOfBoston/CityWorker-issues/issues/9#issuecomment-349040023, or mute the thread https://github.com/notifications/unsubscribe-auth/AfC5vcrLutvWAVlnqk47UzN5VdfwtsWjks5s9C1wgaJpZM4PuDft .

--

Vanessa Calderon

CRM Specialist

City of Boston | DoIT

vanessa.calderon@boston.gov | 617.635.4412

jqr commented 6 years ago

So now that we've addressed the question permission aspects, the remaining bits are 500 errors we're receiving when submitting to Incapsulate. See BOS311API-47

I'm hopeful, but not 100% on the resolution of the 500 errors also resolving this issue but I'd suggest leaving this open until we can verify it 100%.

edasilva85 commented 6 years ago

not reproducible via android, all cases are moving to an Open status

vanessacalderon commented 6 years ago

Created a traffic signal is broken and it changed to open status in matter of seconds