Skip to content

Commit ddee471

Browse files
authored
Fix license header (apache#12008)
* chore: fix license header and add checker Signed-off-by: Ruihang Xia <[email protected]> * add CI checker Signed-off-by: Ruihang Xia <[email protected]> * ignore generated files Signed-off-by: Ruihang Xia <[email protected]> * replace RAT with hawkeye Signed-off-by: Ruihang Xia <[email protected]> * fix new header errors Signed-off-by: Ruihang Xia <[email protected]> --------- Signed-off-by: Ruihang Xia <[email protected]>
1 parent 1094651 commit ddee471

File tree

41 files changed

+199
-186
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+199
-186
lines changed

.github/workflows/dev.yml

+4-10
Original file line numberDiff line numberDiff line change
@@ -23,18 +23,12 @@ concurrency:
2323
cancel-in-progress: true
2424

2525
jobs:
26-
rat:
27-
name: Release Audit Tool (RAT)
26+
license-header-check:
2827
runs-on: ubuntu-latest
28+
name: Check License Header
2929
steps:
30-
- name: Checkout
31-
uses: actions/checkout@v4
32-
- name: Setup Python
33-
uses: actions/setup-python@v5
34-
with:
35-
python-version: "3.10"
36-
- name: Audit licenses
37-
run: ./dev/release/run-rat.sh .
30+
- uses: actions/checkout@v4
31+
- uses: korandoru/hawkeye@v5
3832

3933
prettier:
4034
name: Use prettier to check formatting of documents

.github/workflows/rust.yml

+8
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,14 @@ on:
3939
workflow_dispatch:
4040

4141
jobs:
42+
# Check license header
43+
license-header-check:
44+
runs-on: ubuntu-20.04
45+
name: Check License Header
46+
steps:
47+
- uses: actions/checkout@v4
48+
- uses: korandoru/hawkeye@v5
49+
4250
# Check crate compiles
4351
linux-build-lib:
4452
name: cargo check

benchmarks/compare.py

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

2019
from __future__ import annotations
2120

datafusion/common-runtime/src/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
// KIND, either express or implied. See the License for the
1515
// specific language governing permissions and limitations
1616
// under the License.
17+
1718
// Make cheap clones clear: https://github.com/apache/datafusion/issues/11143
1819
#![deny(clippy::clone_on_ref_ptr)]
1920

datafusion/common/src/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
// KIND, either express or implied. See the License for the
1515
// specific language governing permissions and limitations
1616
// under the License.
17+
1718
// Make cheap clones clear: https://github.com/apache/datafusion/issues/11143
1819
#![deny(clippy::clone_on_ref_ptr)]
1920

datafusion/core/src/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
// KIND, either express or implied. See the License for the
1515
// specific language governing permissions and limitations
1616
// under the License.
17+
1718
#![warn(missing_docs, clippy::needless_borrow)]
1819

1920
//! [DataFusion] is an extensible query engine written in Rust that

datafusion/core/src/physical_optimizer/sanity_checker.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
// "License"); you may not use this file except in compliance
77
// with the License. You may obtain a copy of the License at
88
//
9-
//http://www.apache.org/licenses/LICENSE-2.0
9+
// http://www.apache.org/licenses/LICENSE-2.0
1010
//
1111
// Unless required by applicable law or agreed to in writing,
1212
// software distributed under the License is distributed on an

datafusion/core/src/test/object_store.rs

+2
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,9 @@
1414
// KIND, either express or implied. See the License for the
1515
// specific language governing permissions and limitations
1616
// under the License.
17+
1718
//! Object store implementation used for testing
19+
1820
use crate::execution::context::SessionState;
1921
use crate::execution::session_state::SessionStateBuilder;
2022
use crate::prelude::SessionContext;

datafusion/core/tests/fuzz_cases/equivalence/utils.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
// KIND, either express or implied. See the License for the
1515
// specific language governing permissions and limitations
1616
// under the License.
17-
//
17+
1818
use datafusion::physical_plan::expressions::col;
1919
use datafusion::physical_plan::expressions::Column;
2020
use datafusion_physical_expr::{ConstExpr, EquivalenceProperties, PhysicalSortExpr};

datafusion/core/tests/macro_hygiene/mod.rs

+2
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,11 @@
1414
// KIND, either express or implied. See the License for the
1515
// specific language governing permissions and limitations
1616
// under the License.
17+
1718
//! Verifies [Macro Hygene]
1819
//!
1920
//! [Macro Hygene]: https://en.wikipedia.org/wiki/Hygienic_macro
21+
2022
mod plan_err {
2123
// NO other imports!
2224
use datafusion_common::plan_err;

datafusion/execution/src/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
// KIND, either express or implied. See the License for the
1515
// specific language governing permissions and limitations
1616
// under the License.
17+
1718
// Make cheap clones clear: https://github.com/apache/datafusion/issues/11143
1819
#![deny(clippy::clone_on_ref_ptr)]
1920

datafusion/expr/src/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
// KIND, either express or implied. See the License for the
1515
// specific language governing permissions and limitations
1616
// under the License.
17+
1718
// Make cheap clones clear: https://github.com/apache/datafusion/issues/11143
1819
#![deny(clippy::clone_on_ref_ptr)]
1920

datafusion/expr/src/logical_plan/display.rs

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
// KIND, either express or implied. See the License for the
1515
// specific language governing permissions and limitations
1616
// under the License.
17+
1718
//! This module provides logic for displaying LogicalPlans in various styles
1819
1920
use std::collections::HashMap;

datafusion/ffi/src/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
// KIND, either express or implied. See the License for the
1515
// specific language governing permissions and limitations
1616
// under the License.
17+
1718
// Make cheap clones clear: https://github.com/apache/datafusion/issues/11143
1819
#![deny(clippy::clone_on_ref_ptr)]
1920

datafusion/functions-aggregate-common/src/tdigest.rs

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

1618
//! An implementation of the [TDigest sketch algorithm] providing approximate
1719
//! quantile calculations.

datafusion/functions-aggregate/src/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
// KIND, either express or implied. See the License for the
1515
// specific language governing permissions and limitations
1616
// under the License.
17+
1718
// Make cheap clones clear: https://github.com/apache/datafusion/issues/11143
1819
#![deny(clippy::clone_on_ref_ptr)]
1920

datafusion/functions-aggregate/src/min_max.rs

+1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
// or more contributor license agreements. See the NOTICE file
33
// distributed with this work for additional information
44
// regarding copyright ownership. The ASF licenses this file
5+
// to you under the Apache License, Version 2.0 (the
56
// "License"); you may not use this file except in compliance
67
// with the License. You may obtain a copy of the License at
78
//

datafusion/functions-aggregate/src/min_max/min_max_bytes.rs

+1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
// or more contributor license agreements. See the NOTICE file
33
// distributed with this work for additional information
44
// regarding copyright ownership. The ASF licenses this file
5+
// to you under the Apache License, Version 2.0 (the
56
// "License"); you may not use this file except in compliance
67
// with the License. You may obtain a copy of the License at
78
//

datafusion/functions-nested/src/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
// KIND, either express or implied. See the License for the
1515
// specific language governing permissions and limitations
1616
// under the License.
17+
1718
// Make cheap clones clear: https://github.com/apache/datafusion/issues/11143
1819
#![deny(clippy::clone_on_ref_ptr)]
1920

datafusion/functions/src/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
// KIND, either express or implied. See the License for the
1515
// specific language governing permissions and limitations
1616
// under the License.
17+
1718
// Make cheap clones clear: https://github.com/apache/datafusion/issues/11143
1819
#![deny(clippy::clone_on_ref_ptr)]
1920

datafusion/optimizer/src/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
// KIND, either express or implied. See the License for the
1515
// specific language governing permissions and limitations
1616
// under the License.
17+
1718
// Make cheap clones clear: https://github.com/apache/datafusion/issues/11143
1819
#![deny(clippy::clone_on_ref_ptr)]
1920

datafusion/optimizer/src/push_down_filter.rs

+3
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
// Licensed to the Apache Software Foundation (ASF) under one
2+
// or more contributor license agreements. See the NOTICE file
3+
// distributed with this work for additional information
14
// regarding copyright ownership. The ASF licenses this file
25
// to you under the Apache License, Version 2.0 (the
36
// "License"); you may not use this file except in compliance

datafusion/physical-expr-common/src/datum.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
//
99
// http://www.apache.org/licenses/LICENSE-2.0
1010
//
11-
// UnLt required by applicable law or agreed to in writing,
11+
// Unless required by applicable law or agreed to in writing,
1212
// software distributed under the License is distributed on an
1313
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
1414
// KIND, either express or implied. See the License for the

datafusion/physical-expr/src/intervals/cp_solver.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
// "License"); you may not use this file except in compliance
77
// with the License. You may obtain a copy of the License at
88
//
9-
//http://www.apache.org/licenses/LICENSE-2.0
9+
// http://www.apache.org/licenses/LICENSE-2.0
1010
//
1111
// Unless required by applicable law or agreed to in writing,
1212
// software distributed under the License is distributed on an

datafusion/physical-expr/src/intervals/test_utils.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
// "License"); you may not use this file except in compliance
77
// with the License. You may obtain a copy of the License at
88
//
9-
//http://www.apache.org/licenses/LICENSE-2.0
9+
// http://www.apache.org/licenses/LICENSE-2.0
1010
//
1111
// Unless required by applicable law or agreed to in writing,
1212
// software distributed under the License is distributed on an

datafusion/physical-expr/src/intervals/utils.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
// "License"); you may not use this file except in compliance
77
// with the License. You may obtain a copy of the License at
88
//
9-
//http://www.apache.org/licenses/LICENSE-2.0
9+
// http://www.apache.org/licenses/LICENSE-2.0
1010
//
1111
// Unless required by applicable law or agreed to in writing,
1212
// software distributed under the License is distributed on an

datafusion/physical-optimizer/src/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
// KIND, either express or implied. See the License for the
1515
// specific language governing permissions and limitations
1616
// under the License.
17+
1718
// Make cheap clones clear: https://github.com/apache/datafusion/issues/11143
1819
#![deny(clippy::clone_on_ref_ptr)]
1920

0 commit comments

Comments
 (0)