timja / jenkins-gh-issues-poc-06-18

0 stars 0 forks source link

[JENKINS-19248] regression: Upgrading to 1.528 ("Upgrade Automatically") breaks "configure" #10505

Closed timja closed 10 years ago

timja commented 11 years ago

When upgrading from 1.527 to 1.528, no jobs can be edited anymore!

When clicking the configure button (or going to jobname/configure), it starts loading the fields and filling in the data from the configuration, but the "LOADING" overlay never disappears, and the job settings can't be changed.

When looking at the web browser console, I see a lot of ajax POST requests from the browser, but the LOADING never disappears.

Downgrading to 1.527 solves the problem.

Are there any more logs I can attach to help solving the problem?


Originally reported by rggjan, imported from: regression: Upgrading to 1.528 ("Upgrade Automatically") breaks "configure"
  • assignee: bap
  • status: Resolved
  • priority: Blocker
  • resolution: Duplicate
  • resolved: 2014-02-05T15:21:04+00:00
  • imported: 2022/01/10
timja commented 11 years ago

pedersen:

I can confirm this issue: There is a javascript error triggered:
Timestamp: 19.08.2013 11:40:43
Error: SyntaxError: invalid regular expression flag j
Source File: http://trac.frm2.tum.de/jenkins/static/5e152190/scripts/hudson-behavior.js
Line: 416, Column: 9
Source Code:
/jenkins/job/FreeBSDUpdatePort/descriptorByName/jenkins.plugins.publi

...
// Behavior rules
//========================================================
// using tag names in CSS selector makes the processing faster
function registerValidator(e) {
e.targetElement = findFollowingTR(e, "validation-error-area").firstChild.nextSibling;
e.targetUrl = function() {
var url = this.getAttribute("checkUrl");
var depends = this.getAttribute("checkDependsOn");

if (depends==null)

{// legacy behaviour where checkUrl is a JavaScript return eval(url); // need access to 'this', so no 'geval' <--- this is line 416 }

else {
var q = qs(this).addThis();
if (depends.length>0)
depends.split(" ").each(function

{ q.nearBy(n); }

);
return url+ q.toString();
}
};

...

timja commented 11 years ago

gcummings:

Getting same error on upgrade to 1.528

File was modified as part of https://issues.jenkins-ci.org/browse/JENKINS-19124

timja commented 11 years ago

gcummings:

Code change was part of JENKINS-19124

timja commented 11 years ago

gcummings:

Changing component to Core

timja commented 11 years ago

gcummings:

mine sames to fail when processing

url=/jenkins/job/JOB_NAME/descriptorByName/jenkins.plugins.publish_over_ssh.BapSshTransfer/checkExecCommand
depends=null

Uncaught SyntaxError: Unexpected token ILLEGAL

timja commented 11 years ago

12delta:

I have the same Problem and a simple replacement (downgrade) of the jenkis.war (version 1.528) with the version 1.527 works for me, too.

timja commented 11 years ago

gcummings:

Might be a problem between the JavaScript change and the publish over ssh plugin as reported in JENKINS-19253

The URL causing the JavaScript error for me was a publish over ssh url

timja commented 11 years ago

mwebber:

I don't have this problem on 1.528, so I guess it depends on what specific plugins are installed.
I don't have publish_over_ssh installed.

timja commented 11 years ago

mwebber:

Assigning to bap, since this appears to eb an issue with the publish-over-ssh plugin.

timja commented 11 years ago

12delta:

Interesting: Our Jenkins has an activated "Publish Over SSH". When I have some time, I check, if Jenkins 1.528 works with deactivated "Publish Over SSH" Plug-in.

timja commented 11 years ago

aphro_:

Fix made in https://github.com/jenkinsci/jenkins/pull/910

We should probably try/catch whenever we're 'eval'ing Javascript, it's not good to assume it will always be sane.

timja commented 11 years ago

jgriffithpics:

I have the publish over ssh plug in installed, but it's not part of any of the builds. I'm going to try to remove it and see if that corrects the problem.

timja commented 11 years ago

jgriffithpics:

I uninstalled the publish over ssh plug in and it resolves the problem (which is a better work around than downgrading Jenkins IMO).

timja commented 11 years ago

holgerf:

I can confirm that deactivating publish over ssh plugin temporarily resolves the issue (on 1.528 from Debian repo).

timja commented 11 years ago

bedge:

Also uninstalled the publish over ssh plug in and it resolves the problem with 1.528

timja commented 11 years ago

jgriffithpics:

Just to throw it out there, has anyone tried to just disable the publish over ssh plug in? I probably should have but thought about it only after I uninstalled it.

timja commented 11 years ago

yakobe:

I have the same issue. I have disabled the plugin and it works again. However this plugin is used in several projects here so it would be great to have a fix asap

timja commented 11 years ago

dark_lx_tomtom:

we have the same problem and we are dependent on the publish-over-ssh plugin.
so we downgraded to 527 for now and hope this weill be fixed fast.

also, with 528 the http publisher plugin did not create proper links anymore, with 527 this is still fine.

timja commented 11 years ago

djhaskin987:

Many people googled JENKINS-9494 when this problem was found. My comment relating to this problem and those of ~4 others are there.

timja commented 11 years ago

jniesen:

I ran into this issue this morning after upgrading to 1.529. Disabling the Publish Over SSH plug-in made the symptoms go away.

timja commented 11 years ago

pedersen:

Looking at #19323 I think the problem stems from the fact, that javascript allow a shortcut regexp notation if an expression starts with /.

If we catch the SyntaxError raised, and quote the string, it is working correctly again.

 hudson-behaviuor.js ~416
if (depends==null) {// legacy behaviour where checkUrl is a JavaScript
    try{
    return eval(url); // need access to 'this', so no 'geval'
}
     catch (x){
return eval("'"+url+"'");
    }
} else {

The publish-over-ssh-plugin is sending a relative url causing the js-engine to treat it as a regexp.

timja commented 11 years ago

dmfay:

I'm seeing something similar in 1.529; the message in Chrome's JS console is "Invalid flags supplied to RegExp constructor 'job'". It happens both in a newly created freestyle job and an existing one.

I have the SSH publishing plugin installed, and had updated both Jenkins and the plugin (to v1.10) yesterday. I've tried downgrading the plugin to 1.09 and it didn't help. Disabling or uninstalling it isn't an option, I'll have to downgrade until this is fixed.

timja commented 11 years ago

jglick:

@pedersen sounds like the start of a pull request, though ideally we should add some test coverage for this.

timja commented 11 years ago

jgriffithpics:

Just a note, I think it's really strange that a plug in that I didn't even have in use in any of my jobs caused this issue. One would think that if you didn't have it in use in any job that it would not negatively affect the job (similar to having the plug in disabled globally). Just a thought.

timja commented 11 years ago

jesperjensen:

See also https://www.jfrog.com/jira/browse/HAP-325 this is the same from a user perspective.

timja commented 11 years ago

aphro_:

@glick I already made one, see https://issues.jenkins-ci.org/browse/JENKINS-19248?focusedCommentId=183968&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-183968

timja commented 11 years ago

alen:

Pedersens patch works. I am running 1.529 with Publish over SSH 1.09.
Thank you very much.

timja commented 11 years ago

ogre_x:

I can confirm that Pedersens patch works. I cloned the git repo and applied the patch to master. Not going back to releases until this is fixed.

Jenkins ver. 1.531-SNAPSHOT (private-08/30/2013 05:37 GMT), Publish over SSH 1.10.

Thank you for finding a workaround.

timja commented 11 years ago

jglick:

Someone should go through possible duplicates that do not mention Publish Over SSH and check if the attempted fix now in trunk resolves them.

timja commented 11 years ago

swf:

Same problem here with 1.529 but Publish Over SSH plugin is not installed!? Here's the list of installed plugins:
Jenkins Mailer Plugin 1.5
External Monitor Job Type Plugin 1.2
LDAP Plugin 1.6
PAM Authentication plugin 1.1
Ant Plugin 1.2
Javadoc Plugin 1.1
Green Balls 1.12
Token Macro Plugin 1.8.1
Maven Integration plugin 1.529
Jenkins Subversion Plug-in 1.50
Jenkins CVS Plug-in 2.9
Deploy WebLogic Plugin 2.5
Credentials Plugin 1.7.6
Jenkins Translation Assistance plugin 1.10
Static Analysis Utilities 1.54
FindBugs Plug-in 4.51
SSH Credentials Plugin 1.4
Jenkins SSH Slaves plugin 1.2
PMD Plug-in 3.37
Checkstyle Plug-in 3.38
Static Analysis Collector Plug-in 1.38
Jenkins disk-usage plugin 0.20
Timestamper 1.5.7
Jenkins Email Extension Plugin 2.32
Jenkins M2 Extra Steps Plugin 1.1.7
Jenkins Job Configuration History Plugin 2.4
Jenkins Maven Release Plug-in Plug-in 0.12.0
Console Column Plugin 1.5
Jenkins Sonar Plugin 2.1

timja commented 11 years ago

thomasp:

Yves Schumann: deactivate em one by one to find the guilty one

timja commented 11 years ago

ramunask:

For me disabling "Publish Over SSH" helped view configuration page "Jenkins ver. 1.530". But I need this plugin to be enabled.

timja commented 11 years ago

radius314:

I am having the same issue with 1.530. Disabling the plugin isn't really a workaround.

timja commented 11 years ago

jglick:

Please test the purported fix (of JENKINS-19457) in 1.531.

timja commented 11 years ago

toddr:

1.531 isn't out yet is it?

timja commented 11 years ago

ramunask:

For me Jenkins didn't suggested new version. As temporal solution I edited hudson-behaviuor.js file and wrapped "return eval(url); " with try/catch. Seems that functionality still works. Waiting for new release

timja commented 11 years ago

jglick:

1.531 is currently in RC.

timja commented 11 years ago

dbaldo:

I get the same error on upgrade to 1.528. After wait some releases e this issue don't was correted, i decided to downgrade to 1.527

timja commented 11 years ago

rdesgroppes:

No longer facing the problen with 1.531. That said, I also updated all plugins (but xunit)

timja commented 10 years ago

dbaldo:

I have installed Jenkins version 1.527, when this issue will be fixed?

timja commented 10 years ago

mwebber:

Daniel Baldo, do you mean 1.527 or 1.537? Please provide a few more details about your plugin environment.

timja commented 10 years ago

dbaldo:

My version Jenkins is 1.527. See the atached zip file with my environment.

timja commented 10 years ago

dbaldo:

My environment attached.

timja commented 10 years ago

mwebber:

Daniel, what exactly are you asking?? You say that you are on 1.527. DO you have the problem on that release or not?

The problem was fixed in 1.531, as far as I know. Did you read the all the comments in this ticket?

timja commented 10 years ago

jglick:

Believed to have been resolved with the fix in JENKINS-19457.

timja commented 2 years ago

gmcdonald:

For your information, all publish-over-ssh component type JENKINS issues related to the Publish Over SSH plugin have been transferred to Github: https://github.com/jenkinsci/publish-over-ssh-plugin/issues

Here is the direct link to this issue in Github: https://github.com/jenkinsci/publish-over-ssh-plugin/issues/193
And here is the link to a search for related issues: https://github.com/jenkinsci/publish-over-ssh-plugin/issues?q=%22JENKINS-19248%22

(Note: this is an automated bulk comment)

timja commented 2 years ago

[Duplicates: JENKINS-19457]

timja commented 2 years ago

[Originally duplicated by: JENKINS-19511]

timja commented 2 years ago

[Originally duplicated by: JENKINS-19293]

timja commented 2 years ago

[Originally related to: JENKINS-19389]