[jira] [Work logged] (BEAM-3993) rat doesn't pass with gradle

2018-04-04 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot logged work on BEAM-3993:


Author: ASF GitHub Bot
Created on: 04/Apr/18 15:19
Start Date: 04/Apr/18 15:19
Worklog Time Spent: 10m 
  Work Description: lukecwik closed pull request #5002: [BEAM-3993] read 
gitignore and add it in rat exclusions
URL: https://github.com/apache/beam/pull/5002
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/.gitignore b/.gitignore
index e81a4e379c8..69373cba747 100644
--- a/.gitignore
+++ b/.gitignore
@@ -8,6 +8,7 @@
 # Ignore files generated by the Gradle build process.
 **/.gradle/**/*
 **/.gogradle/**/*
+**/gogradle.lock
 **/build/**/*
 **/vendor/**/*
 **/.gradletasknamecache
@@ -22,7 +23,9 @@ 
sdks/java/maven-archetypes/examples/src/main/resources/archetype-resources/src/
 
sdks/java/maven-archetypes/examples-java8/src/main/resources/archetype-resources/src/
 
 # Ignore files generated by the Python build process.
-**/*.py[cod]
+**/*.pyc
+**/*.pyo
+**/*.pyd
 **/*.egg-info/
 **/.eggs/
 **/nose-*.egg/
diff --git a/build.gradle b/build.gradle
index ad58db61eeb..e924202df6d 100644
--- a/build.gradle
+++ b/build.gradle
@@ -67,76 +67,9 @@ apply plugin: "base"
 
 // Apply one top level rat plugin to perform any required license enforcement 
analysis
 apply plugin: "org.nosphere.apache.rat"
-rat {
-  plainOutput = true
-  xmlOutput = false
-  htmlOutput = false
-  failOnError = true
-  excludes = [
-// Ignore any offline repositories the user may have created.
-"**/${offlineRepositoryRoot}/**/*",
-
-// Exclude files generated by the Gradle build process
-"**/.gradle/**/*",
-"**/.gogradle/**/*",
-"**/gogradle.lock",
-"**/build/**/*",
-"**/vendor/**/*",
-"**/.gradletasknamecache",
-
-// .gitignore: Ignore files generated by the Maven build process
-"**/target/**/*",
-"**/bin/**/*",
-"**/dependency-reduced-pom.xml",
-
-// .gitignore: Ignore files generated by the Python build process
-"**/*.pyc",
-"**/*.pyo",
-"**/*.pyd",
-"**/*.egg-info/**/*",
-"**/.eggs/**/*",
-"**/nose-*.egg/**/*",
-"**/.tox/**/*",
-"**/dist/**/*",
-"**/distribute-*/**/*",
-"**/env/**/*",
-"sdks/python/**/*.c",
-"sdks/python/**/*.so",
-"sdks/python/**/*.egg",
-"sdks/python/LICENSE",
-"sdks/python/NOTICE",
-"sdks/python/README.md",
-"sdks/python/apache_beam/portability/api/*pb2*.*",
-
-// .gitignore: Ignore IntelliJ files.
-"**/.idea/**/*",
-"**/*.iml",
-"**/*.ipr",
-"**/*.iws",
-"**/out/**/*",
-
-// .gitignore: Ignore Eclipse files.
-"**/.classpath",
-"**/.project",
-"**/.factorypath",
-"**/.checkstyle",
-"**/.fbExcludeFilterFile",
-"**/.apt_generated/**/*",
-"**/.settings/**/*",
-
-// .gitignore: Ignore Visual Studio Code files.
-"**/.vscode/**/*",
-
-// .gitignore: Hotspot VM leaves this log in a non-target directory when 
java crashes
-"**/hs_err_pid*.log",
-
-// .gitignore: Ignore files that end with "~", since they
-// are most likely auto-save files produced by a text editor.
-"**/*~",
-
-// .gitignore: Ignore MacOSX files.
-"**/.DS_Store/**/*",
 
+rat {
+  def exclusions = [
 // Ignore files we track but do not distribute
 ".github/**/*",
 
@@ -157,6 +90,22 @@ rat {
 // VCF test files
 "**/apache_beam/testing/data/vcf/*",
   ]
+
+  // Add .gitignore excludes to the Apache Rat exclusion list. We re-create 
the behavior
+  // of the Apache Maven Rat plugin since the Apache Ant Rat plugin doesn't do 
this
+  // automatically.
+  def gitIgnore = project(':').file('.gitignore')
+  if (gitIgnore.exists()) {
+def gitIgnoreExcludes = gitIgnore.readLines().findAll { !it.isEmpty() && 
!it.startsWith('#') }
+println "Adding ${gitIgnoreExcludes.size()} .gitignore exclusions to 
Apache Rat"
+exclusions.addAll(gitIgnoreExcludes)
+  }
+
+  plainOutput = true
+  xmlOutput = false
+  htmlOutput = false
+  failOnError = true
+  excludes = exclusions
 }
 check.dependsOn rat
 


 


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 87585)
Time Spent: 1h  (was: 50m)

> rat doesn't pass with gradle
> 
>
>

[jira] [Work logged] (BEAM-3993) rat doesn't pass with gradle

2018-04-04 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot logged work on BEAM-3993:


Author: ASF GitHub Bot
Created on: 04/Apr/18 15:18
Start Date: 04/Apr/18 15:18
Worklog Time Spent: 10m 
  Work Description: lukecwik commented on issue #5002: [BEAM-3993] read 
gitignore and add it in rat exclusions
URL: https://github.com/apache/beam/pull/5002#issuecomment-378638502
 
 
   Just to get visibility during the build process so that users don't have to 
type --info. The rest of the build uses it at important points. We can swap to 
using logging to cut down verbosity at any point in time in the future.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 87583)
Time Spent: 50m  (was: 40m)

> rat doesn't pass with gradle
> 
>
> Key: BEAM-3993
> URL: https://issues.apache.org/jira/browse/BEAM-3993
> Project: Beam
>  Issue Type: Sub-task
>  Components: build-system
>Reporter: Romain Manni-Bucau
>Assignee: Romain Manni-Bucau
>Priority: Major
> Fix For: 2.5.0
>
>  Time Spent: 50m
>  Remaining Estimate: 0h
>




--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Work logged] (BEAM-3993) rat doesn't pass with gradle

2018-04-04 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot logged work on BEAM-3993:


Author: ASF GitHub Bot
Created on: 04/Apr/18 07:30
Start Date: 04/Apr/18 07:30
Worklog Time Spent: 10m 
  Work Description: rmannibucau commented on issue #5002: [BEAM-3993] read 
gitignore and add it in rat exclusions
URL: https://github.com/apache/beam/pull/5002#issuecomment-378507384
 
 
   @lukecwik applied, only "?" I have is why using println instead of the 
logger which prevents to use --info to control the logs but not a blocker at 
all.


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 87450)
Time Spent: 40m  (was: 0.5h)

> rat doesn't pass with gradle
> 
>
> Key: BEAM-3993
> URL: https://issues.apache.org/jira/browse/BEAM-3993
> Project: Beam
>  Issue Type: Sub-task
>  Components: build-system
>Reporter: Romain Manni-Bucau
>Assignee: Romain Manni-Bucau
>Priority: Major
> Fix For: 2.5.0
>
>  Time Spent: 40m
>  Remaining Estimate: 0h
>




--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Work logged] (BEAM-3993) rat doesn't pass with gradle

2018-04-03 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot logged work on BEAM-3993:


Author: ASF GitHub Bot
Created on: 03/Apr/18 22:29
Start Date: 03/Apr/18 22:29
Worklog Time Spent: 10m 
  Work Description: lukecwik commented on a change in pull request #5002: 
[BEAM-3993] read gitignore and add it in rat exclusions
URL: https://github.com/apache/beam/pull/5002#discussion_r178980602
 
 

 ##
 File path: build.gradle
 ##
 @@ -107,7 +104,6 @@ rat {
 "sdks/python/NOTICE",
 
 Review comment:
   I cleaned up the duplication in 
https://github.com/rmannibucau/incubator-beam/pull/1, please consider merging 
into your branch.
   
   


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 87314)
Time Spent: 0.5h  (was: 20m)

> rat doesn't pass with gradle
> 
>
> Key: BEAM-3993
> URL: https://issues.apache.org/jira/browse/BEAM-3993
> Project: Beam
>  Issue Type: Sub-task
>  Components: build-system
>Reporter: Romain Manni-Bucau
>Assignee: Romain Manni-Bucau
>Priority: Major
> Fix For: 2.5.0
>
>  Time Spent: 0.5h
>  Remaining Estimate: 0h
>




--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Work logged] (BEAM-3993) rat doesn't pass with gradle

2018-04-03 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot logged work on BEAM-3993:


Author: ASF GitHub Bot
Created on: 03/Apr/18 20:24
Start Date: 03/Apr/18 20:24
Worklog Time Spent: 10m 
  Work Description: angoenka commented on issue #5002: [BEAM-3993] read 
gitignore and add it in rat exclusions
URL: https://github.com/apache/beam/pull/5002#issuecomment-378385379
 
 
   R: @lukecwik 


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 87261)
Time Spent: 20m  (was: 10m)

> rat doesn't pass with gradle
> 
>
> Key: BEAM-3993
> URL: https://issues.apache.org/jira/browse/BEAM-3993
> Project: Beam
>  Issue Type: Sub-task
>  Components: build-system
>Reporter: Romain Manni-Bucau
>Assignee: Romain Manni-Bucau
>Priority: Major
> Fix For: 2.5.0
>
>  Time Spent: 20m
>  Remaining Estimate: 0h
>




--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Work logged] (BEAM-3993) rat doesn't pass with gradle

2018-04-03 Thread ASF GitHub Bot (JIRA)

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

ASF GitHub Bot logged work on BEAM-3993:


Author: ASF GitHub Bot
Created on: 03/Apr/18 09:58
Start Date: 03/Apr/18 09:58
Worklog Time Spent: 10m 
  Work Description: rmannibucau opened a new pull request #5002: 
[BEAM-3993] read gitignore and add it in rat exclusions
URL: https://github.com/apache/beam/pull/5002
 
 
   rat build doesn't pass with gradle cause maven merges gitignore in rat 
exclusions but not ant/gradle
   
   this PR reads gitignore to merge it as well (instead of duplicating them)
   
   
   
   Follow this checklist to help us incorporate your contribution quickly and 
easily:
   
- [ ] Make sure there is a [JIRA 
issue](https://issues.apache.org/jira/projects/BEAM/issues/) filed for the 
change (usually before you start working on it).  Trivial changes like typos do 
not require a JIRA issue.  Your pull request should address just this issue, 
without pulling in other changes.
- [ ] Format the pull request title like `[BEAM-XXX] Fixes bug in 
ApproximateQuantiles`, where you replace `BEAM-XXX` with the appropriate JIRA 
issue.
- [ ] Write a pull request description that is detailed enough to 
understand:
  - [ ] What the pull request does
  - [ ] Why it does it
  - [ ] How it does it
  - [ ] Why this approach
- [ ] Each commit in the pull request should have a meaningful subject line 
and body.
- [ ] Run `mvn clean verify` to make sure basic checks pass. A more 
thorough check will be performed on your pull request automatically.
- [ ] If this contribution is large, please file an Apache [Individual 
Contributor License Agreement](https://www.apache.org/licenses/icla.pdf).
   
   


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

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

> rat doesn't pass with gradle
> 
>
> Key: BEAM-3993
> URL: https://issues.apache.org/jira/browse/BEAM-3993
> Project: Beam
>  Issue Type: Sub-task
>  Components: build-system
>Reporter: Romain Manni-Bucau
>Assignee: Romain Manni-Bucau
>Priority: Major
> Fix For: 2.5.0
>
>  Time Spent: 10m
>  Remaining Estimate: 0h
>




--
This message was sent by Atlassian JIRA
(v7.6.3#76005)