Esri / coordinate-conversion-addin-dotnet

Addin for ArcMap and Pro for convenient coordinate conversion in Desktop.
Apache License 2.0
45 stars 20 forks source link

CC crashes when entering 45,45 (ambiguous) coordinate values in text box at Pro 2.3 #525

Closed BobBooth closed 5 years ago

BobBooth commented 6 years ago

With the latest (10/30/18) build of CC, on ArcGIS Pro 2.3 (2.3.0-beta.1+build 14448), when I enter coordinate values in the input box and hit enter, ArcGIS Pro crashes sometimes. To repro, in the Input box, type 0,0 and press the Enter key. Pro crashes. 45,128 worked, but then when I tried 45,45 it crashed Pro again. The Ambiguous coordinate dialog was not displayed.

The same build of the add-in worked correctly with values such as 0,0 and 45,45 on ArcGISPro 2.2.0. The ambiguous coordinate dialog does appear, and it creates the points correctly. This seems to be something that changed in Pro at 2.3. Using today's daily of Pro and the September build 16 of CC, I am seeing a crash on entering 45,45 and pressing Enter.

This is not a problem in the ArcMap version of the add-in, on ArcMap 10.6.0 (8184)

BobBooth commented 6 years ago

@dfoll

BobBooth commented 6 years ago

@csmoore - this seems to be a Pro 2.3 vs Pro 2.2 difference that could be taken to the core folks by @dfoll. Can you look at what is going on? Repro case: in CC on 2.3, enter 45,45 or 0,0 in the input text box.

dfoll commented 6 years ago

agree with @BobBooth it seems that anything ambiguous is crashing Pro.

csmoore commented 6 years ago

@BobBooth - thanks for the repro case - this one looks like a crash in CC when the ambiguous coord form is loaded (so probably not a Pro issue) - looking into cause now.

Update: the cause of this exception is calling a Form from the CIM Thread instead of the UI Thread. Not sure why this error is not seen on Pro 2.2 but this is a CC bug.

BobBooth commented 6 years ago

@csmoore - Thanks. The form loads in Pro 2.2, FYI.

BobBooth commented 6 years ago

@csmoore - I wonder if the crash when clicking "Search" button when no search term is entered (on the Edit Properties >> Symbology tab) is has a similar cause? (calling a Form from the CIM Thread instead of the UI Thread) https://github.com/Esri/coordinate-conversion-addin-dotnet/issues/526

csmoore commented 6 years ago

@BobBooth - I checked #526 and it was just a plain old null string bug vs. threading bug - https://github.com/Esri/coordinate-conversion-addin-dotnet/issues/526#issuecomment-437993272

csmoore commented 5 years ago

@dfoll @saip - adding crash line: https://github.com/Esri/coordinate-conversion-addin-dotnet/blame/dev/source/CoordinateConversion/ProAppCoordConversionModule/ViewModels/ProTabBaseViewModel.cs#L806

And Call Stack - UI is now being created on CIM Thread (source of crash):

image

lfunkhouser commented 5 years ago

@saip please take a look at this one. This is seen in Pro 2.3 from the code changes in #518 It is not a core issue.

dfoll commented 5 years ago

To add to what @lfunkhouser stated the PR that had this delivery was https://github.com/Esri/coordinate-conversion-addin-dotnet/pull/518

csmoore commented 5 years ago

PR #549 created to address the issue.

dfoll commented 5 years ago

Solutions\DefenseSolutions\CoordinateConversion\Testing\csm-525-crash-at-2-3-if-ambig\41 was built to test this

dfoll commented 5 years ago

Tested on Pro 2.3.0.15723 CC testing build 41 (see comment).

Cases tested

image Ambig coords dialog is showing. Also, some test coordinates I used.

Proceeding to merge

dfoll commented 5 years ago

...\Solutions\DefenseSolutions\CoordinateConversion\January2019\Dev\41 was built post-merge to test this

dfoll commented 5 years ago

Looks good from ..\Dev\41. I did not test on ArcMap as this problem was listed only for Pro. @BobBooth can you also take a look and move to Done and add verified label if it looks good to you.

BobBooth commented 5 years ago

I tested from \Dev\41 and I'm seeing the ambiguous coordinate panel pop up when needed, no crashing.

lfunkhouser commented 5 years ago

Need to test on Pro 2.2 to verify this is fixed on the dev branch before the PR for #538 can be merged

csmoore commented 5 years ago

Testing these repro steps from latest dev branch (Built at Commercial\Solutions\DefenseSolutions\CoordinateConversion\January2019\Dev\44), on Pro 2.2.0. I am unable to reproduce this issue.

NOTE: branch CTLocalGovTeam-dev for #138 was also tested, and I could not see the issue.

@lfunkhouser @dfoll @saip @kgonzago Can we verify that this is not a configuration issue or there are not additional steps required?

image

image

BobBooth commented 5 years ago

I just tested the same version @csmoore was using (Commercial\Solutions\DefenseSolutions\CoordinateConversion\January2019\Dev\44) on Pro 2.3.0 (installer date 1/10/19, build 15769) and it worked fine. Also tested same build of CC on Pro 2.2 it also worked fine.

saip commented 5 years ago

@lfunkhouser @dfoll @kgonzago @csmoore We have tested this again this morning on multiple machines and could not reproduce on Pro 2.2 with the repro steps mentioned above.

We will submit a PR with a fix for #538.