You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "ASF GitHub Bot (Jira)" <ji...@apache.org> on 2019/09/05 16:40:00 UTC

[jira] [Work logged] (CAMEL-13919) "camel-package:update-readme" throws ArrayIndexOutOfBoundsException when there is an empty "adoc" file

     [ https://issues.apache.org/jira/browse/CAMEL-13919?focusedWorklogId=307306&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-307306 ]

ASF GitHub Bot logged work on CAMEL-13919:
------------------------------------------

                Author: ASF GitHub Bot
            Created on: 05/Sep/19 16:39
            Start Date: 05/Sep/19 16:39
    Worklog Time Spent: 10m 
      Work Description: omarsmak commented on pull request #3148: MINOR: CAMEL-13919: Fix ArrayIndexOutOfBoundsException when generate readme …
URL: https://github.com/apache/camel/pull/3148
 
 
   It happens if you have an empty documentation file or a file with less than 5 lines per https://issues.apache.org/jira/browse/CAMEL-13919
 
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Issue Time Tracking
-------------------

            Worklog Id:     (was: 307306)
    Remaining Estimate: 0h
            Time Spent: 10m

> "camel-package:update-readme" throws ArrayIndexOutOfBoundsException when there is an empty "adoc" file
> ------------------------------------------------------------------------------------------------------
>
>                 Key: CAMEL-13919
>                 URL: https://issues.apache.org/jira/browse/CAMEL-13919
>             Project: Camel
>          Issue Type: Bug
>          Components: tooling
>    Affects Versions: 3.0.0.M4
>            Reporter: Omar Al-Safi
>            Priority: Minor
>             Fix For: 3.0.0, 3.0.0.RC2
>
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> Steps to produce: 
>  * Create an empty {{adoc}} file in any component.
>  * Run {{camel-package:update-readme}}.
>  * It will fail with the following error: 
> {code}
> Caused by: java.lang.ArrayIndexOutOfBoundsException: Index 1 out of bounds for length 1
>     at org.apache.camel.maven.packaging.UpdateReadmeMojo.updateAvailableFrom (UpdateReadmeMojo.java:510)
>     at org.apache.camel.maven.packaging.UpdateReadmeMojo.executeComponent (UpdateReadmeMojo.java:151)
>     at org.apache.camel.maven.packaging.UpdateReadmeMojo.execute (UpdateReadmeMojo.java:105)
> {code}
> * As I can see [here|https://github.com/apache/camel/blob/master/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/UpdateReadmeMojo.java#L510], it looks it will try to retrieve index although there are empty lines



--
This message was sent by Atlassian Jira
(v8.3.2#803003)