CDR Tickets

Issue Number 4126
Summary Display user friendly error messages
Created 2016-06-20 10:37:16
Issue Type Bug
Submitted By Osei-Poku, William (NIH/NCI) [C]
Assigned To Englisch, Volker (NIH/NCI) [C]
Status Closed
Resolved 2018-04-02 18:00:02
Resolution Fixed
Path /home/bkline/backups/jira/ocecdr/issue.186503
Description

When a required top level section title element is missing from a summary, the summary validates, however it fails to successfully generate PP. Meanwhile the error message that is displayed (see attached) does not help the user in trying to identify the problem. It would be helpful to display a more user friendly error message to aid the user in finding and fixing the problem.

List of errors:
1. Missing Top Level Section
2. Missing protocol (http) from Summary URL
3. Missing SummaryFragmentRef (OCECDR-4105)
4. Adding linking (copy and paste) elements but failing to complete link by CTRL + Enter macro
5. When user fails to enter a CDR ID or enters only CDR ID but not PubMed citation ID while updating a citation on the citations import page on the advanced page, a python script error displays.

Comment entered 2016-08-26 17:44:46 by Osei-Poku, William (NIH/NCI) [C]

I am wondering if we can re-purpose this ticket to address other vague error messages mostly coming from percussion or gatekeeper when document fail PP? For example, here is another error that is displayed in the browser when the protocol is omitted from the Summary URL.

"CDRPreview web service error: Xml data validation error,The 'Err' element is not declared.Validation error occurred when validating the instance document.,6,3"

The error message is not helpful at all in identifying what the problem is with the document. I am sure with time, I will be able to provide many more examples.

Comment entered 2016-08-26 18:41:50 by Englisch, Volker (NIH/NCI) [C]

Let's discuss this at our next meeting.
The original problem can only be solved with a filter change while your new problem could likely be handled with a validation rule rather than a filter change. That makes me think we shouldn't mix both problems in a single ticket.

Comment entered 2016-10-04 14:36:21 by Osei-Poku, William (NIH/NCI) [C]

Updated ticked with error reported by in OCECDR-4105

Comment entered 2016-11-10 11:55:32 by Osei-Poku, William (NIH/NCI) [C]

Revised title to reflect requested changes

Comment entered 2017-03-30 13:31:27 by Englisch, Volker (NIH/NCI) [C]

I have made the changes for item #1 when the PP report returns with an error message from Percussion. The modified file is PublishPreview.py.

Comment entered 2017-03-30 13:45:10 by Englisch, Volker (NIH/NCI) [C]

Moving on to item #2. I've modified the URL to remove the _http://_ protocol from the SummaryURL element but it doesn't cause the PP report to fail.
Would you be able to prepare a document on DEV so that I can see what error message we encounter?

Comment entered 2017-04-03 12:06:05 by Osei-Poku, William (NIH/NCI) [C]

Here is one on DEV that is causing the same error message: CDR0000062945

Comment entered 2017-04-03 12:35:34 by Englisch, Volker (NIH/NCI) [C]

I ran the PP report on the CWD for this summary on DEV without problems. Do you need me to run a different report or a different version to reproduce the error?

Comment entered 2017-04-03 12:40:44 by Osei-Poku, William (NIH/NCI) [C]

Please try again on the CWD. Somehow, I left the protocol in there. I was just able to reproduce the error message after removing it and saving a version.

Comment entered 2017-04-04 11:27:05 by Englisch, Volker (NIH/NCI) [C]

It turns out that item #2 was actually a bug in our filter code that only hit when the http protocol was left out.
This has been fixed now in the filters

  • CDR000157 (Vendor Filter: Summary)

  • CDR786432 (Module: URL Conversion)

For my information: This change is in the trunk sandbox

Comment entered 2017-04-04 11:51:41 by Englisch, Volker (NIH/NCI) [C]

and : Would it be possible to recreate that error for item #3 of the description on DEV? The referred ticket indicates a missing SummaryFragmentRef to have caused an error but I don't remember any details.

Also, it appears that item #4 is a XmetaL problem, right? If that's the case we'll need to create a separate ticket for that item because macro changes are not filter changes and are release dependent.

Comment entered 2017-04-04 20:43:09 by Osei-Poku, William (NIH/NCI) [C]

Error #3 happens when you link (SummaryFragmentRef) to a never published summary/document (tested with only summary). The QC Report does not work and produces the following error message:

<Errors> <Err>XSLT error: code: 61 msgtype:error code:61 module:Sablotron URI:cdrutil:/get-pv-num/CDR0000779306#_2 line:1 node:attribute 'encoding' msg:could not open document 'cdr:CDR0000779306/lastp' </Err> </Errors>

Check out CDR0000257995 (linked to unpublished/blocked CDR0000779306) on DEV.

Comment entered 2017-04-04 20:49:50 by Osei-Poku, William (NIH/NCI) [C]

Also, it appears that item #4 is a XmetaL problem, right? If that's the case we'll need to create a separate ticket for that item because macro changes are not filter changes and are release dependent.

Yes, this problem happens in XMetal. However, it is not necessarily a problem with the macro. The Macro works fine. However, if the user fails to complete the process (CTRL + Enter, Select retrieved doc, click OK). But leaves the element blank, that is when the error is displayed. Please let me know if I still need to create a new ticket for this.

Comment entered 2017-04-06 21:42:54 by Osei-Poku, William (NIH/NCI) [C]

Verified on DEV.

Comment entered 2017-04-27 17:10:45 by Englisch, Volker (NIH/NCI) [C]

The following filters have been copied to QA for testing:

  • CDR000157 (Vendor Filter: Summary)

  • CDR786432 (Module: URL Conversion)

Comment entered 2017-04-27 17:30:42 by Englisch, Volker (NIH/NCI) [C]

Since item #4 isn't a release independent filter change please create a separate ticket so that we can mark this ticket as resolved.

Comment entered 2017-08-08 11:59:26 by Kline, Bob (NIH/NCI) [C]

: please link this ticket to the one Volker asked to be create for item #4, and close this ticket.

Comment entered 2017-08-08 14:51:59 by Osei-Poku, William (NIH/NCI) [C]

New ticket created and linked - OCECDR-4299

Comment entered 2017-08-09 18:42:07 by Englisch, Volker (NIH/NCI) [C]

and close this ticket.

Looking at the comments, these changes have made it to QA but not yet to production. In addition, the filter changes could be promoted to PROD but the change to the PP report needs the help of CBIIT.

I suggest let's test the filter changes and promote these to PROD. Then we'll leave this ticket open and mark it for Hawking for the updates to the PublishPreview.py report.

Comment entered 2017-09-21 10:03:09 by Englisch, Volker (NIH/NCI) [C]

The changes to PublishPreview.py have been moved from my subversion sandbox Feynman-hold to the git repository cdr-admin (cdr4126).

Comment entered 2017-09-22 15:19:31 by Englisch, Volker (NIH/NCI) [C]

Saved changed in git repository admin:

  • PublishPreview.py [cdr4126 1e612604]

Comment entered 2017-11-22 13:32:40 by Osei-Poku, William (NIH/NCI) [C]

<type 'exceptions.AttributeError'> Python 2.7.13: D:\Python\python.exe
Wed Nov 22 13:23:26 2017

A problem occurred in a Python script. Here is the sequence of function calls leading up to the error, in the order they occurred.

D:\Inetpub\wwwroot\cgi-bin\cdr\CiteSearch.py in ()
147 #----------------------------------------------------------------------

148 if impReq:

=> 149 importID = importID.strip()

150 if not session: cdrcgi.bail("User not logged in")

151 article = fetchCitation(importID)

importID = None, importID.strip undefined

<type 'exceptions.AttributeError'>: 'NoneType' object has no attribute 'strip'
args = ("'NoneType' object has no attribute 'strip'",)
message = "'NoneType' object has no attribute 'strip'"

D:\cdr\Log\tmpjxpffp.html contains the description of this error.

Comment entered 2018-02-15 17:38:31 by Englisch, Volker (NIH/NCI) [C]

Here is another situation that would benefit from additional information displayed to the user:
When running the PublishPreview report on a document for which no publishable version exists a python error gets created and the log-file contains the following message:

Exception: Unable to resolve uri u'CDR0000791241/lastp'
Comment entered 2018-03-31 19:53:49 by Englisch, Volker (NIH/NCI) [C]

The following filter has been fixed in order to display a "nicer" error message when a SummaryFragmentRef is found pointing to a document without a publishable version (issue #3):

Comment entered 2018-03-31 19:56:13 by Englisch, Volker (NIH/NCI) [C]

The following filters have been updated (issue #2):

Comment entered 2018-03-31 20:00:27 by Englisch, Volker (NIH/NCI) [C]

The following program has been updated on githup to address issue #1:

Comment entered 2018-04-02 17:53:32 by Englisch, Volker (NIH/NCI) [C]

The following script has been updated to avoid the listed error message in the comment from Nov. 22nd (addressing issue #5):

Comment entered 2018-04-09 10:18:49 by Osei-Poku, William (NIH/NCI) [C]

Verified on QA. Thanks!

Comment entered 2018-05-31 12:28:34 by Osei-Poku, William (NIH/NCI) [C]

Verified on PROD. Thanks!

Attachments
File Name Posted User
Not linking.png 2016-11-01 14:07:25 Osei-Poku, William (NIH/NCI) [C]
pub preview error message.docx 2016-08-26 17:46:31 Osei-Poku, William (NIH/NCI) [C]
top level title error message.JPG 2016-06-20 10:37:16 Osei-Poku, William (NIH/NCI) [C]

Elapsed: 0:00:00.001385