Skip to content

Conversation

@theyostalservice
Copy link
Contributor

@theyostalservice theyostalservice commented Nov 7, 2025

Resolves LINEAR JIRA

Depends on #12386 (Update: MERGED :-) )

Problem

We need to support new yaml specs for metrics in the new V2 semantic layer YAML, although there is a lot of overlap. This PR addresses creating the spec for the YAML itself.

Solution

I broke the unparsed metric class into a base class and two different sub-classes based for v1 and v2. I did the same thing for the tests for unparsed metrics. (Sharing a base class and test is especially reasonable in this case because they share validation logic.)

The design goal here is to DRY as much as possible while also making it reasonable to do maintenance on only one version of YAML at once (including eventually surgically removing the old YAML format one day).

Checklist

  • I have read the contributing guide and understand what's expected of me.
  • I have run this code in development, and it appears to resolve the stated issue.
  • This PR includes tests, or tests are not required or relevant for this PR.
  • This PR has no interface changes (e.g., macros, CLI, logs, JSON artifacts, config files, adapter interface, etc.) or this PR has already received feedback and approval from Product or DX.
  • This PR includes type annotations for new and modified functions.

@cla-bot cla-bot bot added the cla:yes label Nov 7, 2025
@github-actions
Copy link
Contributor

github-actions bot commented Nov 7, 2025

Thank you for your pull request! We could not find a changelog entry for this change. For details on how to document a change, see the contributing guide.

Copy link
Contributor Author

theyostalservice commented Nov 7, 2025

@codecov
Copy link

codecov bot commented Nov 7, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 91.37%. Comparing base (a5ff83d) to head (d65cf65).
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #12157      +/-   ##
==========================================
- Coverage   91.40%   91.37%   -0.03%     
==========================================
  Files         203      203              
  Lines       25144    25207      +63     
==========================================
+ Hits        22982    23033      +51     
- Misses       2162     2174      +12     
Flag Coverage Δ
integration 88.20% <100.00%> (-0.10%) ⬇️
unit 65.33% <83.75%> (+0.03%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Components Coverage Δ
Unit Tests 65.33% <83.75%> (+0.03%) ⬆️
Integration Tests 88.20% <100.00%> (-0.10%) ⬇️
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@theyostalservice theyostalservice changed the base branch from main to graphite-base/12157 November 8, 2025 00:36
@theyostalservice theyostalservice force-pushed the patricky/add-new-metric-yaml branch from b833b17 to 77e7cc4 Compare November 8, 2025 00:36
@theyostalservice theyostalservice changed the base branch from graphite-base/12157 to patricky/fix-metric-name-validation-and-add-tests November 8, 2025 00:36
@theyostalservice theyostalservice force-pushed the patricky/add-new-metric-yaml branch 2 times, most recently from 4f23379 to 3bc5c35 Compare November 8, 2025 01:15
@theyostalservice theyostalservice changed the base branch from patricky/fix-metric-name-validation-and-add-tests to graphite-base/12157 November 10, 2025 23:51
@theyostalservice theyostalservice force-pushed the patricky/add-new-metric-yaml branch from 3bc5c35 to 4986d43 Compare November 11, 2025 00:21
@theyostalservice theyostalservice changed the base branch from graphite-base/12157 to patricky/fix-metric-name-validation-and-add-tests November 11, 2025 00:21
@theyostalservice theyostalservice force-pushed the patricky/add-new-metric-yaml branch from 4986d43 to 8930660 Compare November 11, 2025 00:42
@theyostalservice theyostalservice changed the title Add new-syle YAML metric Add new-syle YAML unparsed metric Nov 11, 2025
Base automatically changed from patricky/fix-metric-name-validation-and-add-tests to main November 11, 2025 00:53
@theyostalservice theyostalservice force-pushed the patricky/add-new-metric-yaml branch 3 times, most recently from c8778fa to f5cdb1d Compare November 12, 2025 21:00
@theyostalservice theyostalservice changed the base branch from main to graphite-base/12157 January 25, 2026 20:48
@theyostalservice theyostalservice force-pushed the patricky/add-new-metric-yaml branch from f5cdb1d to 75ed3c5 Compare January 25, 2026 20:48
@theyostalservice theyostalservice changed the base branch from graphite-base/12157 to patricky/parse-column-dimensions January 25, 2026 20:48
@theyostalservice theyostalservice marked this pull request as ready for review January 25, 2026 22:13
@theyostalservice theyostalservice requested a review from a team as a code owner January 25, 2026 22:13
@github-actions github-actions bot added the community This PR is from a community member label Jan 25, 2026
@theyostalservice theyostalservice force-pushed the patricky/add-new-metric-yaml branch from 75ed3c5 to e839e7a Compare January 26, 2026 18:27
Base automatically changed from patricky/parse-column-dimensions to main January 26, 2026 19:18
@github-actions
Copy link
Contributor

Additional Artifact Review Required

Changes to artifact directory files requires at least 2 approvals from core team members.

@theyostalservice theyostalservice added the artifact_minor_upgrade To bypass the CI check by confirming that the change is not breaking label Jan 26, 2026 — with Graphite App
@theyostalservice theyostalservice force-pushed the patricky/add-new-metric-yaml branch from e839e7a to 21e1cc6 Compare January 27, 2026 02:09
theyostalservice and others added 2 commits January 28, 2026 13:03
* Add Semantic entities to columns for new YAML

* Change changie issue number
@QMalcolm QMalcolm merged commit db5a9e0 into main Jan 28, 2026
55 checks passed
@QMalcolm QMalcolm deleted the patricky/add-new-metric-yaml branch January 28, 2026 23:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

artifact_minor_upgrade To bypass the CI check by confirming that the change is not breaking cla:yes community This PR is from a community member

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants