![]() |
|
|
Issue Type:
|
Bug
|
Assignee:
|
Gregory Boissinot
|
Components:
|
envinject |
Created:
|
04/Oct/14 1:00 AM
|
Description:
|
EnvInject throws a StringIndexOutOfBoundsException in BuildCauseRetriever.getTriggeredCause if the class that triggered it was anonymous. This is because getTriggerName uses cause.getClass().getSimpleName(), which returns an empty string for anonymous classes, empty strings are skipped when getTriggeredCause iterates over build causes, but it always assumes that there is at least one non-empty build cause.
I'm not sure which fix would be most consistent with the intent of the ENV_CAUSE variable for custom triggers. I see these options:
- Skip setting an ENV_CAUSE, possibly log a warning
- Use the parent class as the trigger name
- make the trigger "ANONYMOUSTRIGGER", possibly prefixed by the parent class
|
Environment:
|
envinject-plugin master branch
|
Project:
|
Jenkins
|
Priority:
|
Minor
|
Reporter:
|
David Eckel
|
|
|
|
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira
|
--
You received this message because you are subscribed to the Google Groups "Jenkins Issues" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
jenkinsci-issues+unsubscr...@googlegroups.com.
For more options, visit
https://groups.google.com/d/optout.