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

Testfairy plugin Failed to deserialize response UserRequest

    XMLWordPrintable

    Details

    • Similar Issues:

      Description

      This exception appears when the Testfairy plugin finishes an upload:

      TestFairy iOS/Android Uploader... v 4.2, run on 
      Loading changeLog from source control
      Uploading App...
      --add (file) apk_file: /Volumes/Data/JenkinsWorkspace/workspace/VerticalFarm_Trunk_TestFairy/VerticalFarm.ipa
      --add api_key: 68a6***998
      --add changelog: No changes since last build
      --add video-quality: high
      --add screenshot-interval: 1
      --add max-duration: 10m
      --add testers-groups: VerticalFarm, Publishing
      --add data-only-wifi: off
      --add record-on-background: off
      --add video: off
      --add auto-update: off
      --add notify: on
      --add instrumentation: off
      Metrics: logcat
      post finished {"status":"ok","app_name":"FarmOn!Dev","app_version":"1.2.0debug","file_size":62887373,"build_url":"https://app.testfairy.com/projects/3724851-farmon/builds/7874951","instrumented_url":"http://my.testfairy.com/download/6WW3ED1S6MRJTC1DT29QC5DZ8F4NKXRFWV02FPHX7E20YJQ6/getapp","download_page_url":"https://tsfr.io/wC4faA","app_url":"https://my.testfairy.com/download/6WW3ED1S6MRJTC1DT29QC5DZ8F4NKXRFWV02FPHX7E20YJQ6/getapp","invite_testers_url":"https://app.testfairy.com/projects/3724851-farmon/builds/7874951/invite","icon_url":"https://s3.amazonaws.com/testfairy/icons/106045/20c93c9f3e14cc4373f9e298da7f4fd00a83ad18.png","notified_testers_groups":""}
      Check the new build : https://app.testfairy.com/projects/3724851-farmon/builds/7874951
      ERROR: Failed to deserialize response to UserRequest:org.jenkinsci.plugins.testfairy.TestFairyIosRecorder$IosRemoteRecorder@36ebc088: java.lang.SecurityException: Rejected: net.sf.json.JSONObject; see https://jenkins.io/redirect/class-filter/
      
      com.testfairy.uploader.TestFairyException: Failed to deserialize response to UserRequest:org.jenkinsci.plugins.testfairy.TestFairyIosRecorder$IosRemoteRecorder@36ebc088: java.lang.SecurityException: Rejected: net.sf.json.JSONObject; see https://jenkins.io/redirect/class-filter/
      	at org.jenkinsci.plugins.testfairy.TestFairyIosRecorder.perform(TestFairyIosRecorder.java:61)
      	at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:744)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:690)
      	at hudson.model.Build$BuildExecution.post2(Build.java:186)
      	at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:635)
      	at hudson.model.Run.execute(Run.java:1752)
      	at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
      	at hudson.model.ResourceController.execute(ResourceController.java:97)
      	at hudson.model.Executor.run(Executor.java:429)
      Caused by: java.io.IOException: Failed to deserialize response to UserRequest:org.jenkinsci.plugins.testfairy.TestFairyIosRecorder$IosRemoteRecorder@36ebc088: java.lang.SecurityException: Rejected: net.sf.json.JSONObject; see https://jenkins.io/redirect/class-filter/
      	at hudson.remoting.Channel.call(Channel.java:960)
      	at org.jenkinsci.plugins.testfairy.TestFairyIosRecorder.perform(TestFairyIosRecorder.java:58)
      	... 9 more
      Caused by: java.lang.SecurityException: Rejected: net.sf.json.JSONObject; see https://jenkins.io/redirect/class-filter/
      	at hudson.remoting.ClassFilter.check(ClassFilter.java:64)
      	at hudson.remoting.MultiClassLoaderSerializer$Input.resolveClass(MultiClassLoaderSerializer.java:124)
      	at java.io.ObjectInputStream.readNonProxyDesc(Unknown Source)
      	at java.io.ObjectInputStream.readClassDesc(Unknown Source)
      	at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
      	at java.io.ObjectInputStream.readObject0(Unknown Source)
      	at java.io.ObjectInputStream.readObject(Unknown Source)
      	at hudson.remoting.UserRequest.deserialize(UserRequest.java:277)
      	at hudson.remoting.UserResponse.retrieve(UserRequest.java:310)
      	at hudson.remoting.Channel.call(Channel.java:952)
      	... 10 more
      Build step '  TestFairy iOS/Android Uploader' marked build as failure

      Although upload finishes successfully the build step is marked as failure.

      Is there a possibility for a fix?

      Thanks in advance!

        Attachments

          Activity

          Hide
          oleg_nenashev Oleg Nenashev added a comment -

          Yes, it is clearly a JEP-200 regression in the plugin. And it's a valid one, because JSONObject is sent over Remoting. This type is explicitly blacklisted, it is not recommended to allow it.

          Stats about TestFairy:

          • 285 installations
          • Last release available in Jenkins UC is 4.2
          • Last release in the repo in 4.11: https://github.com/jenkinsci/testfairy-plugin . Distribution management is misconfigured there afaict. Not sure what has happened with newer releases (CC Daniel Beck)
          • Plugin POM is generally obsolete as well. A facelift is required in order to build/test it efficiently (e.g. to run Plugin Compat Tester or to have CI on ci.jenkins.io)

          The plugin could be recovered and fixed, but it would be great to get a response from Gil Megidish before doing it

          Show
          oleg_nenashev Oleg Nenashev added a comment - Yes, it is clearly a JEP-200 regression in the plugin. And it's a valid one, because JSONObject is sent over Remoting. This type is explicitly blacklisted, it is not recommended to allow it. Stats about TestFairy: 285 installations Last release available in Jenkins UC is 4.2 Last release in the repo in 4.11: https://github.com/jenkinsci/testfairy-plugin . Distribution management is misconfigured there afaict. Not sure what has happened with newer releases (CC Daniel Beck ) Plugin POM is generally obsolete as well. A facelift is required in order to build/test it efficiently (e.g. to run Plugin Compat Tester or to have CI on ci.jenkins.io) The plugin could be recovered and fixed, but it would be great to get a response from Gil Megidish before doing it
          Hide
          jglick Jesse Glick added a comment -

          Generally these issues are fixed very easily by sending a String rather than JSONObject.

          Show
          jglick Jesse Glick added a comment - Generally these issues are fixed very easily by sending a String rather than JSONObject .
          Hide
          oleg_nenashev Oleg Nenashev added a comment -

          Yes, the fix itself should be easy.
          But there is a significant overhead to recover the plugin and to make it releaseable.
          We would need a buy-in from maintainers to do it for a plugin in the current state.

          Show
          oleg_nenashev Oleg Nenashev added a comment - Yes, the fix itself should be easy. But there is a significant overhead to recover the plugin and to make it releaseable. We would need a buy-in from maintainers to do it for a plugin in the current state.
          Hide
          giltsl Gil Tselsnchuk added a comment - - edited

          Thanks for reporting, 
          We released a fix at version 4.16
          https://github.com/jenkinsci/testfairy-plugin/commit/4e14b5338d1c6277de1505afc530a541e9a5bd09]

          Show
          giltsl Gil Tselsnchuk added a comment - - edited Thanks for reporting,  We released a fix at version 4.16 https://github.com/jenkinsci/testfairy-plugin/commit/4e14b5338d1c6277de1505afc530a541e9a5bd09 ]
          Hide
          oleg_nenashev Oleg Nenashev added a comment -

          Gil Tselsnchuk thanks a lot! There are some binary compatibility issues in the change, but I'd guess it's not a problem for the plugin since it has no external dependencies on it. I have updated https://wiki.jenkins.io/display/JENKINS/Plugins+affected+by+fix+for+JEP-200

          Show
          oleg_nenashev Oleg Nenashev added a comment - Gil Tselsnchuk thanks a lot! There are some binary compatibility issues in the change, but I'd guess it's not a problem for the plugin since it has no external dependencies on it. I have updated https://wiki.jenkins.io/display/JENKINS/Plugins+affected+by+fix+for+JEP-200
          Hide
          smnlevente Levente Simon added a comment -

          I have updated the plugin and can confirm that the error is now gone.

          Thanks everyone!

          Show
          smnlevente Levente Simon added a comment - I have updated the plugin and can confirm that the error is now gone. Thanks everyone!

            People

            Assignee:
            giltsl Gil Tselsnchuk
            Reporter:
            smnlevente Levente Simon
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: