roberttdev / dactyl4

DACTYL in Rails 4
MIT License
1 stars 0 forks source link

Loss of Ability to Add Point #37

Closed wsloand closed 9 years ago

wsloand commented 9 years ago

I'm not certain of how this bug progresses, but this is what I think is happening.

Steps

  1. Click in the right pane to create a data point
  2. Highlight a very small region in the left that gets rejected as a region for being too small

Result: Cannot create any more points

Expected result: Try again creating a larger region

wsloand commented 9 years ago

This happened again today in a different circumstance: after cancelling the addition of a point (not certain that it is the precipitating event).

There are no errors in the js console.

roberttdev commented 9 years ago

Cancelling de-selects the point on the right -- re-selecting it again lets you start highlighting. This is mainly done because cancelling can be done many ways (selecting another point in the DV, selecting another point in the DC UI, changing groups, etc), most of which result in the point being navigated away from. It's also so that cancelling a point which has already been entered (i.e. just cancelling changes) doesn't put the DV into highlight mode, since technically its highlighting is complete.

We can change this, but it will take more than a minimal effort.

wsloand commented 9 years ago

I have no issues with with de-selecting the point on the right upon cancellation (and it makes very reasonable sense from a UI perspective).

The issues above were that I could not highlight any region after the above problems. I clicked on other points and switched groups. When I tried to add a new point after highlighting the region, no data entry window appeared above the document view, and it just grayed out the document view.

wsloand commented 9 years ago

I found a reproducible example!!!

This did not trigger the break point suggested by email. Were I to guess, step 4 is probably the trigger.

  1. Make a copied group
  2. Copy three existing points into the pre-existing fields
  3. Click one point on the right pane to prepare for data entry
  4. (Change your mind which point you meant to enter) Click a different point on the right pane to prepare for data entry
  5. Try to highlight a region.

Clicking "Save & Exit" then going back in allowed data entry to continue.

wsloand commented 9 years ago

Now the behavior is improved, but not perfect. With the same steps as in the above comment, the result now is:

Step 5. The yellow highlight follows the mouse. Step 6. The screen turns gray, but the popup window for data entry does not appear. Step 7. Clicking away (anywhere in the gray area of the window) makes it responsive again to data entry.

The point that was initially selected away from (selected in point 3 above) appears not to be able to accept data entry.

roberttdev commented 9 years ago

Hmm, I can't recreate this, it seems fixed to me. Is it possible that you did your retest in a window that was still open from before the push? This would cause it to still have the old Javascript logic.

Try in a fresh window, and Ctrl-F5 reload it to make sure it isn't pulling the JS files from the local cache, just in case.

wsloand commented 9 years ago

This bug is still happening repeatably for me. I did Ctrl-F5, and restarted the browser.

The precise process is:

  1. Open a document that already has some DE done (currently using user test4 with document 48).
  2. Click on a point in the same table 3 to get near the right place in the data heirarchy.
  3. Click on the word "Pharmacokinetics" in the breadcrumbs
  4. Click on the "Result [Omeprazole]" group
  5. Click on the "Result [AUC ratio]" group
  6. Click on one field name ("Measurement Unit" in this case)
  7. Click on another field name ("Measurement Name" in this case)
  8. Click and drag in the document to form the yellow region.

Result: Document view is grayed out (as though it is about to show the window), but the window never shows up.

roberttdev commented 9 years ago

What's test4's password?

roberttdev commented 9 years ago

I don't think this is a code error, I think it's a symptom of the Document Viewer maxing out available CPU resources. What you're describing works, off and on, on my computer, depending on how much CPU is available. Trying to add a point on such a densely populated page maxes out the CPU, though (and I've got an almost brand-new quad-core).

Unfortunately, I think we're probably going to have to break apart the DV and rewrite big chunks of it if we're going to be annotating this densely and users will have old computers. I wager it hasn't become an issue for DocumentCloud because its users have somewhat modern computers and its highlighting is not as dense (they're highlighting whole passages instead of individual pieces), but there's too much waste in it for us. For one thing, we really need to find a way to add a simple annotation without triggering a redraw of the entire page.

Could be a 60-100 hr project, but on the flip side, the system may not be usable for most DE users without it.

roberttdev commented 9 years ago

In fact, if we do this, you should pause your current work in setting data up for Extraction until it's complete so that we can use the data entry for it to heavy test the overhaul. Your data is fine, but it's a nice way to test this work and get data for extraction in one combined effort.

roberttdev commented 9 years ago

I think we'll save a decent amount of CPU/memory by not generating the "Notes" tab and keeping it updated. Are you okay with turning that off?

roberttdev commented 9 years ago

Same question for the "Pages" tab.. less CPU and memory, but removing it will save the user from having to download all of the page thumbnails.

wsloand commented 9 years ago

I see no need for either the Notes or the Pages tabs. For potential future work, I can imagine use for the text tab.

roberttdev commented 9 years ago

Will you be providing computers for QC users? I'm realizing that they will be taking double-damage as far as resources when it comes to loading/rendering annotations. That may end up being even more relevant than DE computers as far as having to program around it.

On Thu, Nov 6, 2014 at 4:08 PM, wsloand notifications@github.com wrote:

I see no need for either the Notes or the Pages tabs. For potential future work, I can imagine use for the text tab.

— Reply to this email directly or view it on GitHub https://github.com/roberttdev/dactyl4/issues/37#issuecomment-62051527.

wsloand commented 9 years ago

I've not reproduced this recently, and given that there are a lot of recent changes, I'm assuming it's resolved.