From 958a32545c11786fc4db6b3b7c3d9fce979bacf1 Mon Sep 17 00:00:00 2001 From: tlento Date: Tue, 19 Mar 2024 18:05:05 -0700 Subject: [PATCH 1/2] Remove unused ci configuration file The validation duration file was a temporary benchmarking action that is so old it still references poetry commands, which have not worked inside the MetricFlow repo for nearly a year now. This was uncovered in a rename operation associated with forking the test package out to repo root, so we just tidy it up here. --- .github/workflows/ci-validation-duration.yaml | 24 ------------------- 1 file changed, 24 deletions(-) delete mode 100644 .github/workflows/ci-validation-duration.yaml diff --git a/.github/workflows/ci-validation-duration.yaml b/.github/workflows/ci-validation-duration.yaml deleted file mode 100644 index d8277dbf36..0000000000 --- a/.github/workflows/ci-validation-duration.yaml +++ /dev/null @@ -1,24 +0,0 @@ -name: Measure Validation Test Duration - -on: - workflow_dispatch: - -jobs: - validation-tests: - name: Run validation tests and measure duration - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - name: Set up Python 3.9 - uses: actions/setup-python@v4 - with: - python-version: "3.9" - - - name: Install Poetry - run: pip install poetry - - - name: Install Deps - run: cd metricflow && poetry install - - - name: Run Validation Tests - run: poetry run pytest --durations=0 metricflow/test/model/validations/ From 7ff6846ad3b91127ffd3ec2febdedd736521f384 Mon Sep 17 00:00:00 2001 From: tlento Date: Wed, 20 Mar 2024 12:15:55 -0700 Subject: [PATCH 2/2] Exclude unused package components from metricflow build The MetricFlow build was taking up 1.5-3 MB on disk, a large part of which was the test package. Confusingly, the MetricFlow build also included the contents of dbt-metricflow, which is meant to be a separate distribution wrapper for MetricFlow itself, so that's odd. This commit cleans up the exclude list to be more appropriate to MetricFlow's repository structure, and finishes the job of reducing the size of the MetricFlow distribution packages by a factor of 4. Most of the work was handled incidentally by moving the tests under the repository root tests directory, which happened to be in the exclude list already. --- .changes/unreleased/Under the Hood-20240320-172307.yaml | 6 ++++++ pyproject.toml | 5 ++++- 2 files changed, 10 insertions(+), 1 deletion(-) create mode 100644 .changes/unreleased/Under the Hood-20240320-172307.yaml diff --git a/.changes/unreleased/Under the Hood-20240320-172307.yaml b/.changes/unreleased/Under the Hood-20240320-172307.yaml new file mode 100644 index 0000000000..6ef367026b --- /dev/null +++ b/.changes/unreleased/Under the Hood-20240320-172307.yaml @@ -0,0 +1,6 @@ +kind: Under the Hood +body: Clean up files included in MetricFlow package distribution +time: 2024-03-20T17:23:07.114845-07:00 +custom: + Author: tlento + Issue: "1092" diff --git a/pyproject.toml b/pyproject.toml index a9ea6a3a29..bc87b832ee 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -110,7 +110,10 @@ exclude = [ ".gitignore", ".pre-commit-config.yaml", "CONTRIBUTING.md", - "MAKEFILE", + "Makefile", + "/dbt-metricflow", + "/local-data-warehouses", + "/scripts", "/tests", ]