Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id D9E72200CBD for ; Thu, 6 Jul 2017 15:51:05 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id D852B16668E; Thu, 6 Jul 2017 13:51:05 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 2985816668C for ; Thu, 6 Jul 2017 15:51:05 +0200 (CEST) Received: (qmail 38786 invoked by uid 500); 6 Jul 2017 13:51:03 -0000 Mailing-List: contact commits-help@beam.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@beam.apache.org Delivered-To: mailing list commits@beam.apache.org Received: (qmail 38775 invoked by uid 99); 6 Jul 2017 13:51:03 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 06 Jul 2017 13:51:03 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id 4BE58C061E for ; Thu, 6 Jul 2017 13:51:03 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -100.002 X-Spam-Level: X-Spam-Status: No, score=-100.002 tagged_above=-999 required=6.31 tests=[RP_MATCHES_RCVD=-0.001, SPF_PASS=-0.001, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id s6L213uvPGda for ; Thu, 6 Jul 2017 13:51:02 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTP id D33455F6C6 for ; Thu, 6 Jul 2017 13:51:01 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id E8A23E065D for ; Thu, 6 Jul 2017 13:51:00 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id 3284024066 for ; Thu, 6 Jul 2017 13:51:00 +0000 (UTC) Date: Thu, 6 Jul 2017 13:51:00 +0000 (UTC) From: "Kenneth Knowles (JIRA)" To: commits@beam.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (BEAM-1984) Fix scope for dependencies that are runtime/test only MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Thu, 06 Jul 2017 13:51:06 -0000 [ https://issues.apache.org/jira/browse/BEAM-1984?page=3Dcom.atlassian.= jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=3D16076= 522#comment-16076522 ]=20 Kenneth Knowles commented on BEAM-1984: --------------------------------------- I had some good success by just enabling the analysis and then setting up `= ` for each module. There are usually just a couple. I thi= nk it should be no problem. > Fix scope for dependencies that are runtime/test only > ----------------------------------------------------- > > Key: BEAM-1984 > URL: https://issues.apache.org/jira/browse/BEAM-1984 > Project: Beam > Issue Type: Improvement > Components: build-system > Affects Versions: Not applicable > Reporter: Isma=C3=ABl Mej=C3=ADa > Assignee: Isma=C3=ABl Mej=C3=ADa > Priority: Minor > > In the Beam parent pom at this moment we have a configuration on the mave= n dependency plugin to ignore the verification of non-compile dependencies = so unused or badly configured dependencies that are used only for test or r= untime purposes are not reported. > {code:xml} > > true > {code} > I discovered this case when I executed: > {code} > =09mvn clean install -Dmaven.test.skip=3Dtrue > {code} > Notice that this is really particular because this does not compile the t= ests classes, so it can detect when the =E2=80=98main=E2=80=99 classes are = not using some code. This is different from the behavior of: > {code} > =09mvn clean install -DskipTests=3Dtrue > {code} > That does not complain because skipTests compiles the tests. > For the first case (maven.test.skip) I got a warning =E2=80=98Unused decl= ared dependencies found=E2=80=99 so with this I discovered the test/runtime= only dependencies that are not correctly scoped. I will do a PR to fix thi= s, because we can get rid of compile dependencies that are test or runtime = only. -- This message was sent by Atlassian JIRA (v6.4.14#64029)