Skip to content

Commit

Permalink
ci: reduce workflow files by merging actions (#3848)
Browse files Browse the repository at this point in the history
* ci: merge license header checker into dev ci

Signed-off-by: tison <[email protected]>

* ci: merge nightly-funtional-tests.yml into nightly-ci.yml

Signed-off-by: tison <[email protected]>

* fix typos

Signed-off-by: tison <[email protected]>

---------

Signed-off-by: tison <[email protected]>
  • Loading branch information
tisonkun authored May 1, 2024
1 parent 573d369 commit 6957461
Show file tree
Hide file tree
Showing 10 changed files with 48 additions and 61 deletions.
9 changes: 8 additions & 1 deletion .github/workflows/develop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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 }}
Expand Down
9 changes: 8 additions & 1 deletion .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,14 @@ jobs:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v4
- uses: crate-ci/[email protected]
- 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
Expand Down
16 changes: 0 additions & 16 deletions .github/workflows/license.yaml

This file was deleted.

31 changes: 23 additions & 8 deletions .github/workflows/nightly-ci.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# Nightly CI: runs tests every night for our second tier plaforms (Windows)

on:
schedule:
- cron: '0 23 * * 1-5'
Expand All @@ -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: 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: ${{ matrix.os }}
strategy:
matrix:
os: [ windows-latest-8-cores ]
runs-on: windows-latest-8-cores
timeout-minutes: 60
steps:
- uses: actions/checkout@v4
Expand Down Expand Up @@ -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
Expand Down
27 changes: 0 additions & 27 deletions .github/workflows/nightly-funtional-tests.yml

This file was deleted.

8 changes: 4 additions & 4 deletions src/common/function/src/scalars/numpy/interp.rs
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ pub fn interp(args: &[VectorRef]) -> Result<VectorRef> {

let res;
if xp.len() == 1 {
let datas = x
let data = x
.iter_data()
.map(|x| {
if Value::from(x) < xp.get(0) {
Expand All @@ -164,7 +164,7 @@ pub fn interp(args: &[VectorRef]) -> Result<VectorRef> {
}
})
.collect::<Vec<_>>();
res = Float64Vector::from(datas);
res = Float64Vector::from(data);
} else {
let mut j = 0;
/* only pre-calculate slopes if there are relatively few of them. */
Expand All @@ -191,7 +191,7 @@ pub fn interp(args: &[VectorRef]) -> Result<VectorRef> {
}
slopes = Some(slopes_tmp);
}
let datas = x
let data = x
.iter_data()
.map(|x| match x {
Some(xi) => {
Expand Down Expand Up @@ -255,7 +255,7 @@ pub fn interp(args: &[VectorRef]) -> Result<VectorRef> {
_ => None,
})
.collect::<Vec<_>>();
res = Float64Vector::from(datas);
res = Float64Vector::from(data);
}
Ok(Arc::new(res) as _)
}
Expand Down
2 changes: 1 addition & 1 deletion src/metric-engine/src/data_region.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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,
Expand Down
2 changes: 1 addition & 1 deletion src/mito2/src/cache/file_cache.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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<ParquetMetaData> {
// 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();
Expand Down
2 changes: 1 addition & 1 deletion src/promql/src/extension_plan/union_distinct_on.rs
Original file line number Diff line number Diff line change
Expand Up @@ -398,7 +398,7 @@ impl HashedData {
}
}

// Finilize the hash map
// Finalize the hash map
let batch = interleave_batches(schema, batches, interleave_indices)?;

Ok(Self {
Expand Down
3 changes: 2 additions & 1 deletion typos.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
[default.extend-words]
Pn = "Pn"
ue = "ue"
datas = "datas"
worl = "worl"

[files]
extend-exclude = [
Expand Down

0 comments on commit 6957461

Please sign in to comment.