Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-47492

"TypeError: Cannot read property 'toLowerCase' of undefined" when trying to list PRs

    • Blue Ocean 1.4 - beta 3, Blue Ocean 1.4 - beta 2

       

      The URL I'm trying to load is:

      http://_buildserver_/blue/organizations/jenkins/pipeline-github%2Fcore/pr/

      The page comes up with just the header and then the rest of the page is blank.

      In the JavaScript console:

       

       
      Error fetching page TypeError: Cannot read property 'toLowerCase' of undefined
      at TimeHarmonizerUtil.getI18nTitle (blueocean.js:2274)
      at LiveStatusIndicator.render (blueocean.js:1563)
      at ReactCompositeComponentWrapper._renderValidatedComponentWithoutOwnerOrContext (blueocean.js:124443)
      at ReactCompositeComponentWrapper._renderValidatedComponent (blueocean.js:124466)
      at ReactCompositeComponentWrapper.performInitialMount (blueocean.js:124008)
      at ReactCompositeComponentWrapper.mountComponent (blueocean.js:123904)
      at Object.mountComponent (blueocean.js:130917)
      at ReactCompositeComponentWrapper.performInitialMount (blueocean.js:124017)
      at ReactCompositeComponentWrapper.mountComponent (blueocean.js:123904)
      at Object.mountComponent (blueocean.js:130917)
      at ReactDOMComponent.mountChildren (blueocean.js:129795)
      at ReactDOMComponent._createInitialChildren (blueocean.js:125371)
      at ReactDOMComponent.mountComponent (blueocean.js:125196)
      at Object.mountComponent (blueocean.js:130917)
      at ReactDOMComponent.mountChildren (blueocean.js:129795)
      at ReactDOMComponent._createInitialChildren (blueocean.js:125371)
      at ReactDOMComponent.mountComponent (blueocean.js:125196)
      at Object.mountComponent (blueocean.js:130917)
      at ReactCompositeComponentWrapper.performInitialMount (blueocean.js:124017)
      at ReactCompositeComponentWrapper.mountComponent (blueocean.js:123904)
      at Object.mountComponent (blueocean.js:130917)
      at ReactDOMComponent.mountChildren (blueocean.js:129795)
      (anonymous) @ blueocean.js:6234
       

          [JENKINS-47492] "TypeError: Cannot read property 'toLowerCase' of undefined" when trying to list PRs

          James Dumay added a comment -

          trejkaz would you mind capturing a HAR file that reproduces this bug?

          James Dumay added a comment - trejkaz would you mind capturing a HAR file that reproduces this bug?

          trejkaz added a comment -

          Tried today, but this time the page loaded, so it will have to wait until next time.

          I do see a lot of errors in the console on this run:

          GET http://_buildserver_/blue/rest/organizations/jenkins/pipelines/trunk-functional-matrix/pipelines/os=centos%20%7C%7C%20release-centos,test=lib/pipelines/case/pipelines/search_unsorted 404 (Not Found)
          
          Unhandled Rejection:  TypeError: Cannot read property 'self' of undefined
              at ActivityService.bunkerKey (blueocean.js:5616)
              at ActivityService.setItem (blueocean.js:5659)
              at executeAction (blueocean.js:103343)
              at ActivityService.res (blueocean.js:103315)
              at blueocean.js:5910
              at <anonymous>
          
          Unhandled Rejection:  TypeError: Already read
              at blueocean.js:3104
              at <anonymous>
          

          That said though, that original stack trace seems diagnosable because it's essentially an NPE. Each level in the stack just has to decide whether a null object is valid or not, and bam, you know where the problem is.

          trejkaz added a comment - Tried today, but this time the page loaded, so it will have to wait until next time. I do see a lot of errors in the console on this run: GET http://_buildserver_/blue/rest/organizations/jenkins/pipelines/trunk-functional-matrix/pipelines/os=centos%20%7C%7C%20release-centos,test=lib/pipelines/case/pipelines/search_unsorted 404 (Not Found) Unhandled Rejection: TypeError: Cannot read property 'self' of undefined at ActivityService.bunkerKey (blueocean.js:5616) at ActivityService.setItem (blueocean.js:5659) at executeAction (blueocean.js:103343) at ActivityService.res (blueocean.js:103315) at blueocean.js:5910 at <anonymous> Unhandled Rejection: TypeError: Already read at blueocean.js:3104 at <anonymous> That said though, that original stack trace seems diagnosable because it's essentially an NPE. Each level in the stack just has to decide whether a null object is valid or not, and bam, you know where the problem is.

          James Dumay added a comment -

          Can you send through a HAR that captures that console error?

          James Dumay added a comment - Can you send through a HAR that captures that console error?

          Karl Shultz added a comment -

          Testing Notes:

          • Even though this appears to be an intermittent issue, it would be useful, going forward, to have an automated UI test which verifies the correct function of the Pull Requests tab. There might be one, but I've not found it anywhere in here.
          • This could end up as an offshoot of JENKINS-48125.
          • I've also not found any JS tests which target the PR tab, but that could be my lack of familiarity with those.

          Karl Shultz added a comment - Testing Notes: Even though this appears to be an intermittent issue, it would be useful, going forward, to have an automated UI test which verifies the correct function of the Pull Requests tab. There might be one, but I've not found it anywhere in here . This could end up as an offshoot of JENKINS-48125 . I've also not found any JS tests which target the PR tab, but that could be my lack of familiarity with those.

          James Dumay added a comment -

          michaelneale this error looks pretty familiar. I suspect we just need to be more defensive on this screen? WDYT?

          James Dumay added a comment - michaelneale this error looks pretty familiar. I suspect we just need to be more defensive on this screen? WDYT?

          Michael Neale added a comment -

          jamesdumay yes - this may be exact same thing as https://issues.jenkins-ci.org/browse/JENKINS-48198 ? 

          Michael Neale added a comment - jamesdumay yes - this may be exact same thing as https://issues.jenkins-ci.org/browse/JENKINS-48198  ? 

          James Dumay added a comment -

          michaelneale Yep, looks like it!

          James Dumay added a comment - michaelneale Yep, looks like it!

          Michael Neale added a comment -

          kshultz do you want to put your notes on the other ticket? (I don't think this is specifically related to PR screen) 0- as for PR tab - not sure... 

          Michael Neale added a comment - kshultz do you want to put your notes on the other ticket? (I don't think this is specifically related to PR screen) 0- as for PR tab - not sure... 

            jamesdumay James Dumay
            trejkaz trejkaz
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: