Skip to content

Commit d5e7bd0

Browse files
committed
[SPARK-33483][INFRA][TESTS] Fix rat exclusion patterns and add a LICENSE
### What changes were proposed in this pull request? This PR fixes the RAT exclusion rule which was originated from SPARK-1144 (Apache Spark 1.0) ### Why are the changes needed? This prevents the situation like #30415. Currently, it missed `catalog` directory due to `.log` rule. ``` $ dev/check-license Could not find Apache license headers in the following files: !????? /Users/dongjoon/APACHE/spark-merge/sql/catalyst/src/main/java/org/apache/spark/sql/connector/catalog/MetadataColumn.java !????? /Users/dongjoon/APACHE/spark-merge/sql/catalyst/src/main/java/org/apache/spark/sql/connector/catalog/SupportsMetadataColumns.java ``` ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? Pass the CI with the new rule. Closes #30418 from dongjoon-hyun/SPARK-RAT. Authored-by: Dongjoon Hyun <dongjoon@apache.org> Signed-off-by: Dongjoon Hyun <dongjoon@apache.org>
1 parent 0b0fb70 commit d5e7bd0

2 files changed

Lines changed: 36 additions & 10 deletions

File tree

dev/.rat-excludes

Lines changed: 18 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -42,11 +42,11 @@ jquery.dataTables.1.10.20.min.js
4242
jquery.mustache.js
4343
jsonFormatter.min.css
4444
jsonFormatter.min.js
45-
.*avsc
46-
.*txt
47-
.*json
48-
.*data
49-
.*log
45+
.*\.avsc
46+
.*\.txt
47+
.*\.json
48+
.*\.data
49+
.*\.log
5050
pyspark-coverage-site/*
5151
cloudpickle/*
5252
join.py
@@ -98,17 +98,17 @@ local-1430917381535_2
9898
DESCRIPTION
9999
NAMESPACE
100100
test_support/*
101-
.*Rd
101+
.*\.Rd
102102
help/*
103103
html/*
104104
INDEX
105105
.lintr
106106
gen-java.*
107-
.*avpr
108-
.*parquet
107+
.*\.avpr
108+
.*\.parquet
109109
spark-deps-.*
110-
.*csv
111-
.*tsv
110+
.*\.csv
111+
.*\.tsv
112112
.*\.sql
113113
.Rbuildignore
114114
META-INF/*
@@ -125,3 +125,11 @@ application_1578436911597_0052
125125
config.properties
126126
app-20200706201101-0003
127127
py.typed
128+
_metadata
129+
_SUCCESS
130+
part-00000
131+
.*\.res
132+
flights_tiny.txt.1
133+
over1k
134+
over10k
135+
exported_table/*

sql/hive/src/test/resources/data/scripts/test_transform.py

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,21 @@
1+
#
2+
# Licensed to the Apache Software Foundation (ASF) under one
3+
# or more contributor license agreements. See the NOTICE file
4+
# distributed with this work for additional information
5+
# regarding copyright ownership. The ASF licenses this file
6+
# to you under the Apache License, Version 2.0 (the
7+
# "License"); you may not use this file except in compliance
8+
# with the License. You may obtain a copy of the License at
9+
#
10+
# http://www.apache.org/licenses/LICENSE-2.0
11+
#
12+
# Unless required by applicable law or agreed to in writing,
13+
# software distributed under the License is distributed on an
14+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15+
# KIND, either express or implied. See the License for the
16+
# specific language governing permissions and limitations
17+
# under the License.
18+
#
119
import sys
220

321
delim = sys.argv[1]

0 commit comments

Comments
 (0)