diff --git a/.github/workflows/develop.yml b/.github/workflows/develop.yml index 8b904daff4..1657962d51 100644 --- a/.github/workflows/develop.yml +++ b/.github/workflows/develop.yml @@ -38,13 +38,20 @@ jobs: runs-on: ubuntu-20.04 steps: - uses: actions/checkout@v4 - - uses: crate-ci/typos@v1.13.10 + - uses: crate-ci/typos@master - name: Check the config docs run: | make config-docs && \ git diff --name-only --exit-code ./config/config.md \ || (echo "'config/config.md' is not up-to-date, please run 'make config-docs'." && exit 1) + license-header-check: + runs-on: ubuntu-20.04 + name: Check License Header + steps: + - uses: actions/checkout@v4 + - uses: korandoru/hawkeye@v5 + check: name: Check runs-on: ${{ matrix.os }} diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml index c9c516c576..37d92ea4dd 100644 --- a/.github/workflows/docs.yml +++ b/.github/workflows/docs.yml @@ -34,7 +34,14 @@ jobs: runs-on: ubuntu-20.04 steps: - uses: actions/checkout@v4 - - uses: crate-ci/typos@v1.13.10 + - uses: crate-ci/typos@master + + license-header-check: + runs-on: ubuntu-20.04 + name: Check License Header + steps: + - uses: actions/checkout@v4 + - uses: korandoru/hawkeye@v5 check: name: Check diff --git a/.github/workflows/license.yaml b/.github/workflows/license.yaml deleted file mode 100644 index b7fc58267c..0000000000 --- a/.github/workflows/license.yaml +++ /dev/null @@ -1,16 +0,0 @@ -name: License checker - -on: - push: - branches: - - main - pull_request: - types: [opened, synchronize, reopened, ready_for_review] -jobs: - license-header-check: - runs-on: ubuntu-20.04 - name: license-header-check - steps: - - uses: actions/checkout@v4 - - name: Check License Header - uses: korandoru/hawkeye@v5 diff --git a/.github/workflows/nightly-ci.yml b/.github/workflows/nightly-ci.yml index b635ab16d6..e4d6a793d0 100644 --- a/.github/workflows/nightly-ci.yml +++ b/.github/workflows/nightly-ci.yml @@ -1,5 +1,3 @@ -# Nightly CI: runs tests every night for our second tier plaforms (Windows) - on: schedule: - cron: '0 23 * * 1-5' @@ -15,13 +13,29 @@ env: RUST_TOOLCHAIN: nightly-2024-04-18 jobs: - sqlness: - name: Sqlness Test + sqlness-test: + name: Run sqlness test if: ${{ github.repository == 'GreptimeTeam/greptimedb' }} - runs-on: ${{ matrix.os }} - strategy: - matrix: - os: [ windows-latest-8-cores ] + runs-on: ubuntu-22.04 + steps: + - name: Checkout + uses: actions/checkout@v4 + with: + fetch-depth: 0 + + - name: Run sqlness test + uses: ./.github/actions/sqlness-test + with: + data-root: sqlness-test + aws-ci-test-bucket: ${{ vars.AWS_CI_TEST_BUCKET }} + aws-region: ${{ vars.AWS_CI_TEST_BUCKET_REGION }} + aws-access-key-id: ${{ secrets.AWS_CI_TEST_ACCESS_KEY_ID }} + aws-secret-access-key: ${{ secrets.AWS_CI_TEST_SECRET_ACCESS_KEY }} + + sqlness-windows: + name: Sqlness tests on Windows + if: ${{ github.repository == 'GreptimeTeam/greptimedb' }} + runs-on: windows-latest-8-cores timeout-minutes: 60 steps: - uses: actions/checkout@v4 @@ -52,6 +66,7 @@ jobs: retention-days: 3 test-on-windows: + name: Run tests on Windows if: ${{ github.repository == 'GreptimeTeam/greptimedb' }} runs-on: windows-latest-8-cores timeout-minutes: 60 diff --git a/.github/workflows/nightly-funtional-tests.yml b/.github/workflows/nightly-funtional-tests.yml deleted file mode 100644 index b4e7ebf927..0000000000 --- a/.github/workflows/nightly-funtional-tests.yml +++ /dev/null @@ -1,27 +0,0 @@ -name: Nightly functional tests - -on: - schedule: - # At 00:00 on Tuesday. - - cron: '0 0 * * 2' - workflow_dispatch: - -jobs: - sqlness-test: - name: Run sqlness test - if: ${{ github.repository == 'GreptimeTeam/greptimedb' }} - runs-on: ubuntu-22.04 - steps: - - name: Checkout - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - - name: Run sqlness test - uses: ./.github/actions/sqlness-test - with: - data-root: sqlness-test - aws-ci-test-bucket: ${{ vars.AWS_CI_TEST_BUCKET }} - aws-region: ${{ vars.AWS_CI_TEST_BUCKET_REGION }} - aws-access-key-id: ${{ secrets.AWS_CI_TEST_ACCESS_KEY_ID }} - aws-secret-access-key: ${{ secrets.AWS_CI_TEST_SECRET_ACCESS_KEY }} diff --git a/src/common/function/src/scalars/numpy/interp.rs b/src/common/function/src/scalars/numpy/interp.rs index 0ae9275032..85f25d8b3b 100644 --- a/src/common/function/src/scalars/numpy/interp.rs +++ b/src/common/function/src/scalars/numpy/interp.rs @@ -152,7 +152,7 @@ pub fn interp(args: &[VectorRef]) -> Result { let res; if xp.len() == 1 { - let datas = x + let data = x .iter_data() .map(|x| { if Value::from(x) < xp.get(0) { @@ -164,7 +164,7 @@ pub fn interp(args: &[VectorRef]) -> Result { } }) .collect::>(); - res = Float64Vector::from(datas); + res = Float64Vector::from(data); } else { let mut j = 0; /* only pre-calculate slopes if there are relatively few of them. */ @@ -191,7 +191,7 @@ pub fn interp(args: &[VectorRef]) -> Result { } slopes = Some(slopes_tmp); } - let datas = x + let data = x .iter_data() .map(|x| match x { Some(xi) => { @@ -255,7 +255,7 @@ pub fn interp(args: &[VectorRef]) -> Result { _ => None, }) .collect::>(); - res = Float64Vector::from(datas); + res = Float64Vector::from(data); } Ok(Arc::new(res) as _) } diff --git a/src/metric-engine/src/data_region.rs b/src/metric-engine/src/data_region.rs index 1dd1b53faa..0ed19db600 100644 --- a/src/metric-engine/src/data_region.rs +++ b/src/metric-engine/src/data_region.rs @@ -91,7 +91,7 @@ impl DataRegion { Ok(()) } - /// Generate warpped [RegionAlterRequest] with given [ColumnMetadata]. + /// Generate wrapped [RegionAlterRequest] with given [ColumnMetadata]. /// This method will modify `columns` in-place. async fn assemble_alter_request( &self, diff --git a/src/mito2/src/cache/file_cache.rs b/src/mito2/src/cache/file_cache.rs index 457f881c43..890d0b7739 100644 --- a/src/mito2/src/cache/file_cache.rs +++ b/src/mito2/src/cache/file_cache.rs @@ -231,7 +231,7 @@ impl FileCache { /// Get the parquet metadata in file cache. /// If the file is not in the cache or fail to load metadata, return None. pub(crate) async fn get_parquet_meta_data(&self, key: IndexKey) -> Option { - // Check if file cache contrains the key + // Check if file cache contains the key if let Some(index_value) = self.memory_index.get(&key).await { // Load metadata from file cache let local_store = self.local_store(); diff --git a/src/promql/src/extension_plan/union_distinct_on.rs b/src/promql/src/extension_plan/union_distinct_on.rs index 4624544645..78a2cc913d 100644 --- a/src/promql/src/extension_plan/union_distinct_on.rs +++ b/src/promql/src/extension_plan/union_distinct_on.rs @@ -398,7 +398,7 @@ impl HashedData { } } - // Finilize the hash map + // Finalize the hash map let batch = interleave_batches(schema, batches, interleave_indices)?; Ok(Self { diff --git a/typos.toml b/typos.toml index 61ba5dd444..02f2ed6e69 100644 --- a/typos.toml +++ b/typos.toml @@ -1,6 +1,7 @@ [default.extend-words] +Pn = "Pn" ue = "ue" -datas = "datas" +worl = "worl" [files] extend-exclude = [