Uploaded image for project: 'LIMS'
  1. LIMS
  2. LIMS-1614

Error when selecting Analysis Administration Tab after receiving a sample with Sampling Workflow enabled

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 3.1.6
    • Fix Version/s: 3.1.7
    • Component/s: None
    • Labels:
      None

      Description

      http://sentry.bikalabs.com/bikalims/dev-demo-test/group/4920/

      It also happened at http://demo.bikalabs.com/

      Traceback (innermost last):
      Module ZPublisher.Publish, line 138, in publish
      Module ZPublisher.mapply, line 77, in mapply
      Module ZPublisher.Publish, line 48, in call_object
      Module bika.lims.browser.bika_listing, line 560, in _call_
      Module Products.Five.browser.pagetemplatefile, line 125, in _call_
      Module Products.Five.browser.pagetemplatefile, line 59, in _call_
      Module zope.pagetemplate.pagetemplate, line 132, in pt_render

      • Warning: Macro expansion failed
      • Warning: <type 'exceptions.KeyError'>: 'hidden_macro'
        Module zope.pagetemplate.pagetemplate, line 240, in _call_
        Module zope.tal.talinterpreter, line 271, in _call_
        Module zope.tal.talinterpreter, line 343, in interpret
        Module zope.tal.talinterpreter, line 888, in do_useMacro
        Module zope.tal.talinterpreter, line 343, in interpret
        Module zope.tal.talinterpreter, line 533, in do_optTag_tal
        Module zope.tal.talinterpreter, line 518, in do_optTag
        Module zope.tal.talinterpreter, line 513, in no_tag
        Module zope.tal.talinterpreter, line 343, in interpret
        Module zope.tal.talinterpreter, line 954, in do_defineSlot
        Module zope.tal.talinterpreter, line 343, in interpret
        Module zope.tal.talinterpreter, line 533, in do_optTag_tal
        Module zope.tal.talinterpreter, line 518, in do_optTag
        Module zope.tal.talinterpreter, line 513, in no_tag
        Module zope.tal.talinterpreter, line 343, in interpret
        Module zope.tal.talinterpreter, line 858, in do_defineMacro
        Module zope.tal.talinterpreter, line 343, in interpret
        Module zope.tal.talinterpreter, line 954, in do_defineSlot
        Module zope.tal.talinterpreter, line 343, in interpret
        Module zope.tal.talinterpreter, line 533, in do_optTag_tal
        Module zope.tal.talinterpreter, line 518, in do_optTag
        Module zope.tal.talinterpreter, line 513, in no_tag
        Module zope.tal.talinterpreter, line 343, in interpret
        Module zope.tal.talinterpreter, line 954, in do_defineSlot
        Module zope.tal.talinterpreter, line 343, in interpret
        Module zope.tal.talinterpreter, line 533, in do_optTag_tal
        Module zope.tal.talinterpreter, line 518, in do_optTag
        Module zope.tal.talinterpreter, line 513, in no_tag
        Module zope.tal.talinterpreter, line 343, in interpret
        Module zope.tal.talinterpreter, line 946, in do_defineSlot
        Module zope.tal.talinterpreter, line 343, in interpret
        Module zope.tal.talinterpreter, line 533, in do_optTag_tal
        Module zope.tal.talinterpreter, line 518, in do_optTag
        Module zope.tal.talinterpreter, line 513, in no_tag
        Module zope.tal.talinterpreter, line 343, in interpret
        Module zope.tal.talinterpreter, line 376, in do_startEndTag
        Module zope.tal.talinterpreter, line 405, in do_startTag
        Module zope.tal.talinterpreter, line 482, in attrAction_tal
        Module Products.PageTemplates.Expressions, line 225, in evaluateText
        Module zope.tales.tales, line 696, in evaluate
      • URL: /opt/bika_e/zinstance/src/bika.lims/bika/lims/browser/analysisrequest/templates/analysisrequest_analyses.pt
      • Line 93, Column 4
      • Expression: <PathExpr standard:u'view/getResultsRange'>
      • Names:
        {'args': (),
        'container': <AnalysisRequest at /entrenamiento/clients/client14-126/BA15-0007-R01>,
        'context': <AnalysisRequest at /entrenamiento/clients/client14-126/BA15-0007-R01>,
        'default': <object object at 0x7fc0be5d4550>,
        'here': <AnalysisRequest at /entrenamiento/clients/client14-126/BA15-0007-R01>,
        'loop': {},
        'nothing': None,
        'options': {},
        'repeat': <Products.PageTemplates.Expressions.SafeMapping object at 0x7fc09ce0b0a8>,
        'request': <HTTPRequest, URL=http://192.168.2.13:8050/entrenamiento/clients/client14-126/BA15-0007-R01/analyses>,
        'root': <Application at >,
        'template': <Products.Five.browser.pagetemplatefile.ViewPageTemplateFile object at 0xaacd290>,
        'traverse_subpath': [],
        'user': <PropertiedUser 'admin'>,
        'view': <Products.Five.metaclass.AnalysisRequestAnalysesView object at 0x7fc097174d10>,
        'views': <Products.Five.browser.pagetemplatefile.ViewMapper object at 0x7fc0a6d7bed0>}
        Module zope.tales.expressions, line 217, in _call_
        Module Products.PageTemplates.Expressions, line 155, in _eval
        Module Products.PageTemplates.Expressions, line 117, in render
        Module bika.lims.browser.analysisrequest.manage_analyses, line 113, in getResultsRange
        Module Products.ZCatalog.Lazy, line 132, in _getitem_
        IndexError: 0

        Activity

        leonardorojass Leo created issue -
        xispa Jordi (Inactive) made changes -
        Field Original Value New Value
        Sprint Jan'15 [ 6 ]
        xispa Jordi (Inactive) made changes -
        Rank Ranked higher
        xispa Jordi (Inactive) made changes -
        Assignee Pau Soliva [ espurna ]
        xispa Jordi (Inactive) made changes -
        Fix Version/s 3.1.7 [ 10502 ]
        Espurna Pau Soliva (Inactive) made changes -
        Status Open [ 1 ] In Progress [ 3 ]
        Espurna Pau Soliva (Inactive) made changes -
        Description It also happened at http://demo.bikalabs.com/

        Traceback (innermost last):
          Module ZPublisher.Publish, line 138, in publish
          Module ZPublisher.mapply, line 77, in mapply
          Module ZPublisher.Publish, line 48, in call_object
          Module bika.lims.browser.bika_listing, line 560, in __call__
          Module Products.Five.browser.pagetemplatefile, line 125, in __call__
          Module Products.Five.browser.pagetemplatefile, line 59, in __call__
          Module zope.pagetemplate.pagetemplate, line 132, in pt_render
           - Warning: Macro expansion failed
           - Warning: <type 'exceptions.KeyError'>: 'hidden_macro'
          Module zope.pagetemplate.pagetemplate, line 240, in __call__
          Module zope.tal.talinterpreter, line 271, in __call__
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 888, in do_useMacro
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 533, in do_optTag_tal
          Module zope.tal.talinterpreter, line 518, in do_optTag
          Module zope.tal.talinterpreter, line 513, in no_tag
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 954, in do_defineSlot
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 533, in do_optTag_tal
          Module zope.tal.talinterpreter, line 518, in do_optTag
          Module zope.tal.talinterpreter, line 513, in no_tag
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 858, in do_defineMacro
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 954, in do_defineSlot
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 533, in do_optTag_tal
          Module zope.tal.talinterpreter, line 518, in do_optTag
          Module zope.tal.talinterpreter, line 513, in no_tag
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 954, in do_defineSlot
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 533, in do_optTag_tal
          Module zope.tal.talinterpreter, line 518, in do_optTag
          Module zope.tal.talinterpreter, line 513, in no_tag
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 946, in do_defineSlot
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 533, in do_optTag_tal
          Module zope.tal.talinterpreter, line 518, in do_optTag
          Module zope.tal.talinterpreter, line 513, in no_tag
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 376, in do_startEndTag
          Module zope.tal.talinterpreter, line 405, in do_startTag
          Module zope.tal.talinterpreter, line 482, in attrAction_tal
          Module Products.PageTemplates.Expressions, line 225, in evaluateText
          Module zope.tales.tales, line 696, in evaluate
           - URL: /opt/bika_e/zinstance/src/bika.lims/bika/lims/browser/analysisrequest/templates/analysisrequest_analyses.pt
           - Line 93, Column 4
           - Expression: <PathExpr standard:u'view/getResultsRange'>
           - Names:
              {'args': (),
               'container': <AnalysisRequest at /entrenamiento/clients/client14-126/BA15-0007-R01>,
               'context': <AnalysisRequest at /entrenamiento/clients/client14-126/BA15-0007-R01>,
               'default': <object object at 0x7fc0be5d4550>,
               'here': <AnalysisRequest at /entrenamiento/clients/client14-126/BA15-0007-R01>,
               'loop': {},
               'nothing': None,
               'options': {},
               'repeat': <Products.PageTemplates.Expressions.SafeMapping object at 0x7fc09ce0b0a8>,
               'request': <HTTPRequest, URL=http://192.168.2.13:8050/entrenamiento/clients/client14-126/BA15-0007-R01/analyses&gt;,
               'root': <Application at >,
               'template': <Products.Five.browser.pagetemplatefile.ViewPageTemplateFile object at 0xaacd290>,
               'traverse_subpath': [],
               'user': <PropertiedUser 'admin'>,
               'view': <Products.Five.metaclass.AnalysisRequestAnalysesView object at 0x7fc097174d10>,
               'views': <Products.Five.browser.pagetemplatefile.ViewMapper object at 0x7fc0a6d7bed0>}
          Module zope.tales.expressions, line 217, in __call__
          Module Products.PageTemplates.Expressions, line 155, in _eval
          Module Products.PageTemplates.Expressions, line 117, in render
          Module bika.lims.browser.analysisrequest.manage_analyses, line 113, in getResultsRange
          Module Products.ZCatalog.Lazy, line 132, in __getitem__
        IndexError: 0
        http://sentry.bikalabs.com/bikalims/dev-demo-test/group/4920/

        It also happened at http://demo.bikalabs.com/

        Traceback (innermost last):
          Module ZPublisher.Publish, line 138, in publish
          Module ZPublisher.mapply, line 77, in mapply
          Module ZPublisher.Publish, line 48, in call_object
          Module bika.lims.browser.bika_listing, line 560, in __call__
          Module Products.Five.browser.pagetemplatefile, line 125, in __call__
          Module Products.Five.browser.pagetemplatefile, line 59, in __call__
          Module zope.pagetemplate.pagetemplate, line 132, in pt_render
           - Warning: Macro expansion failed
           - Warning: <type 'exceptions.KeyError'>: 'hidden_macro'
          Module zope.pagetemplate.pagetemplate, line 240, in __call__
          Module zope.tal.talinterpreter, line 271, in __call__
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 888, in do_useMacro
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 533, in do_optTag_tal
          Module zope.tal.talinterpreter, line 518, in do_optTag
          Module zope.tal.talinterpreter, line 513, in no_tag
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 954, in do_defineSlot
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 533, in do_optTag_tal
          Module zope.tal.talinterpreter, line 518, in do_optTag
          Module zope.tal.talinterpreter, line 513, in no_tag
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 858, in do_defineMacro
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 954, in do_defineSlot
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 533, in do_optTag_tal
          Module zope.tal.talinterpreter, line 518, in do_optTag
          Module zope.tal.talinterpreter, line 513, in no_tag
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 954, in do_defineSlot
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 533, in do_optTag_tal
          Module zope.tal.talinterpreter, line 518, in do_optTag
          Module zope.tal.talinterpreter, line 513, in no_tag
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 946, in do_defineSlot
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 533, in do_optTag_tal
          Module zope.tal.talinterpreter, line 518, in do_optTag
          Module zope.tal.talinterpreter, line 513, in no_tag
          Module zope.tal.talinterpreter, line 343, in interpret
          Module zope.tal.talinterpreter, line 376, in do_startEndTag
          Module zope.tal.talinterpreter, line 405, in do_startTag
          Module zope.tal.talinterpreter, line 482, in attrAction_tal
          Module Products.PageTemplates.Expressions, line 225, in evaluateText
          Module zope.tales.tales, line 696, in evaluate
           - URL: /opt/bika_e/zinstance/src/bika.lims/bika/lims/browser/analysisrequest/templates/analysisrequest_analyses.pt
           - Line 93, Column 4
           - Expression: <PathExpr standard:u'view/getResultsRange'>
           - Names:
              {'args': (),
               'container': <AnalysisRequest at /entrenamiento/clients/client14-126/BA15-0007-R01>,
               'context': <AnalysisRequest at /entrenamiento/clients/client14-126/BA15-0007-R01>,
               'default': <object object at 0x7fc0be5d4550>,
               'here': <AnalysisRequest at /entrenamiento/clients/client14-126/BA15-0007-R01>,
               'loop': {},
               'nothing': None,
               'options': {},
               'repeat': <Products.PageTemplates.Expressions.SafeMapping object at 0x7fc09ce0b0a8>,
               'request': <HTTPRequest, URL=http://192.168.2.13:8050/entrenamiento/clients/client14-126/BA15-0007-R01/analyses&gt;,
               'root': <Application at >,
               'template': <Products.Five.browser.pagetemplatefile.ViewPageTemplateFile object at 0xaacd290>,
               'traverse_subpath': [],
               'user': <PropertiedUser 'admin'>,
               'view': <Products.Five.metaclass.AnalysisRequestAnalysesView object at 0x7fc097174d10>,
               'views': <Products.Five.browser.pagetemplatefile.ViewMapper object at 0x7fc0a6d7bed0>}
          Module zope.tales.expressions, line 217, in __call__
          Module Products.PageTemplates.Expressions, line 155, in _eval
          Module Products.PageTemplates.Expressions, line 117, in render
          Module bika.lims.browser.analysisrequest.manage_analyses, line 113, in getResultsRange
          Module Products.ZCatalog.Lazy, line 132, in __getitem__
        IndexError: 0
        Espurna Pau Soliva (Inactive) made changes -
        Status In Progress [ 3 ] Open [ 1 ]
        Hide
        Espurna Pau Soliva (Inactive) added a comment -

        When you change the keyword from an Analysis Specification, the ResultsRange doesn't change the keyword value. This generates an error while broswer/analysisrequest/getResultsRange() is searching AS' UID with the keyword.

        I made a preventive try-catch.
        https://github.com/Espurna/Bika-LIMS/compare/bikalabs:hotfix/3.1.7...Espurna:issue/1614?expand=1

        Show
        Espurna Pau Soliva (Inactive) added a comment - When you change the keyword from an Analysis Specification, the ResultsRange doesn't change the keyword value. This generates an error while broswer/analysisrequest/getResultsRange() is searching AS' UID with the keyword. I made a preventive try-catch. https://github.com/Espurna/Bika-LIMS/compare/bikalabs:hotfix/3.1.7...Espurna:issue/1614?expand=1
        rockfruit Campbell made changes -
        Epic Link LIMS-1579 [ 13708 ]
        Espurna Pau Soliva (Inactive) made changes -
        Status Open [ 1 ] In Progress [ 3 ]
        Show
        xispa Jordi (Inactive) added a comment - https://github.com/bikalabs/Bika-LIMS/pull/1415
        xispa Jordi (Inactive) made changes -
        Status In Progress [ 3 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        xispa Jordi (Inactive) made changes -
        Sprint Jan'15 [ 6 ] Jan'15, Next sprint [ 6, 16 ]
        xispa Jordi (Inactive) made changes -
        Rank Ranked higher
        xispa Jordi (Inactive) made changes -
        Fix Version/s 3.2 [ 10133 ]
        Fix Version/s 3.1.7 [ 10502 ]
        xispa Jordi (Inactive) made changes -
        Fix Version/s 3.1.7 [ 10502 ]
        Fix Version/s 3.2 [ 10133 ]
        lemoene lemoene made changes -
        Rank Ranked higher
        xispa Jordi (Inactive) made changes -
        Status Resolved [ 5 ] Closed [ 6 ]

          People

          • Assignee:
            Espurna Pau Soliva (Inactive)
            Reporter:
            leonardorojass Leo
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Agile