• Editing a Wiki page causes Java error and stack dump

    By David A Clover 2 decades ago

    We have worked out the sequence that causes the Java error and also what to do to avoid it - the problem appears to be related to authentication. This Wiki can be publicly viewed but requires that a user authentcate before editing or creating an item.



    1, View wiki at http://www.computing.open.ac.uk/wiki/able

    1. Logged in status reported as 'Anonymous' (NB we have 'Default' set as 'Reader' in ACL and we do not have 'Anonymous' assigned as an ACL item at all)
    2. Attempt to 'Edit' an item
    3. Java error returned - we would have expected it to show the login page at that point to let us proceed



      Here's the workaround:

      1, View wiki at http://www.computing.open.ac.uk/wiki/able
    4. Create a new item
    5. Receive browser password challenge
    6. Observe logged in status now the authenticated entity
    7. Choose another page to edit
    8. Edit normally



      The clue in the Java error seems to be in the line 12:

      Error while executing JavaScript action expression

      Script interpreter error, line=12, col=8: Exception occurred calling method NotesDocument.save(boolean, boolean) null



      Javascript code



      1://Create the archive version

      2:

      3: if(viewScope.doArchive){

      4: var db:NotesDatabase=database;

      5:

      6: if(document1.getDocument()!=null){

      7:

      8: var arcDoc=db.createDocument();

      9: document1.getDocument().copyAllItems(arcDoc,true);

      10:

      11: arcDoc.replaceItemValue("status","trash");

      12: arcDoc.save(true,true);

      13: viewScope.archiveID=arcDoc.getUniversalID();

      14:

      15: }else{

      16: viewScope.archiveID=null;

      17: }

      18: }



      and in the stack trace:

      com.ibm.domino.xsp.bridge.http.engine.XspCmdManager.service(XspCmdManager.java:222)

      NotesException: Notes error: You are not authorized to perform that operation
    • Covered by help doc - need author access<>

      By Steve Castledine 2 decades ago