Return-Path: Delivered-To: apmail-ant-notifications-archive@minotaur.apache.org Received: (qmail 69320 invoked from network); 10 Sep 2009 22:24:22 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 10 Sep 2009 22:24:22 -0000 Received: (qmail 4988 invoked by uid 500); 10 Sep 2009 22:24:22 -0000 Delivered-To: apmail-ant-notifications-archive@ant.apache.org Received: (qmail 4915 invoked by uid 500); 10 Sep 2009 22:24:22 -0000 Mailing-List: contact notifications-help@ant.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@ant.apache.org Delivered-To: mailing list notifications@ant.apache.org Received: (qmail 4906 invoked by uid 99); 10 Sep 2009 22:24:22 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 10 Sep 2009 22:24:22 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 10 Sep 2009 22:24:18 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 7C388234C004 for ; Thu, 10 Sep 2009 15:23:57 -0700 (PDT) Message-ID: <1751791533.1252621437494.JavaMail.jira@brutus> Date: Thu, 10 Sep 2009 15:23:57 -0700 (PDT) From: "Lucas Lech (JIRA)" To: notifications@ant.apache.org Subject: [jira] Issue Comment Edited: (IVY-1120) IvyBuildNumber non-deterministic behaviour In-Reply-To: <1439287917.1252599598047.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/IVY-1120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12753852#action_12753852 ] Lucas Lech edited comment on IVY-1120 at 9/10/09 3:22 PM: ---------------------------------------------------------- I've been running two parallel debugging sessions - the ant task that was invoking *ivy:buildnumber* was in first session executed directly and in another one it was executed as dependency of some other task (somewhere down the line of dependency graph) - few other ivy tasks, like ivy:publish have been executed before so in both sessions *ivy:buildnumber* has been fed with exactly the same attributes session invoking the ivy:buildnumber "directly" got the exact matcher while the one invoking it indirectly got the regexp one clearly the comparison in the matcher is broken unless there is something I'm missing here after replacing == with .equals & rebuilding ivy, this task started to work properly what's the reason for comparing references (ref) ant not values (*ref) was (Author: gibffe): I've been running two parallel debugging sessions - the ant task that was invoking *ivy:buildnumber* was in first session executed directly and in another one it was executed as dependency of some other task (somewhere down the line of dependency graph) - few other ivy tasks, like ivy:publish have been executed before so in both sessions *ivy:buildnumber* has been fed with exactly the same attributes clearly the comparison in the matcher is broken unless there is something I'm missing here after replacing == with .equals & rebuilding ivy, this task started to work properly > IvyBuildNumber non-deterministic behaviour > ------------------------------------------ > > Key: IVY-1120 > URL: https://issues.apache.org/jira/browse/IVY-1120 > Project: Ivy > Issue Type: Bug > Components: Ant > Affects Versions: 2.1.0-RC2 > Environment: ant 1.7.1, windows xp > Reporter: Lucas Lech > > IvyBuildNumber.java -> doExecute() > creates an inline patternMatcher with this method: > {code:title=IvyBuildNumber.java|borderStyle=solid} > public Matcher getMatcher(String expression) { > if ((expression == organisation) > || (expression == module) > || (expression == branch)) { > return exact.getMatcher(expression); > } > return regexp.getMatcher(expression); > } > {code} > I'm guessing the == comparison is a typo ? Shouldn't it be saying *.equals* ? > I've been having issues with this task - non-deterministic results - I got down in my debug to this place where I get wrong matcher when > *reference address comparison* fails. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.