Skip to content

Type building metric values#336

Merged
esnya merged 3 commits into
mainfrom
codex/type-building-metric-values
Jun 4, 2026
Merged

Type building metric values#336
esnya merged 3 commits into
mainfrom
codex/type-building-metric-values

Conversation

@esnya
Copy link
Copy Markdown
Owner

@esnya esnya commented Jun 1, 2026

Summary

  • replace nullable/tagged building metric values with concrete Missing/Known/Invalid metric value types
  • remove the duplicate BuildingMetricValueKind tag so payload availability is represented by the runtime type
  • update metric consumers and parser tests to pattern-match known values instead of reading nullable payloads

Verification

  • dotnet restore PlateauResoniteLink.sln --locked-mode --disable-build-servers
  • dotnet format whitespace . --folder --verify-no-changes
  • dotnet build PlateauResoniteLink.sln --configuration Release --no-restore --disable-build-servers -m:1 -p:UseSharedCompilation=false
  • dotnet test PlateauResoniteLink.sln --configuration Release --no-restore --verbosity normal -m:1 --disable-build-servers -p:UseSharedCompilation=false
  • Fake Live Sink canonical scene dump compared with baseline via git diff --no-index; no diff

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 9b86cc6a06

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/PlateauResoniteLink/Application/Importing/BuildingAttributeModels.cs Outdated
@esnya esnya force-pushed the codex/type-building-metric-values branch from 9b86cc6 to ed18dd2 Compare June 1, 2026 17:14
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: ed18dd235d

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/PlateauResoniteLink/Application/Importing/BuildingAttributeModels.cs Outdated
Copy link
Copy Markdown
Owner Author

esnya commented Jun 1, 2026

このままだと Close 寄りです。Missing / Invalid を runtime 型として下流 consumer に流すのではなく、parser/import 境界で diagnostic / skip に閉じ、metric pipeline は Known だけを受ける形にしてください。

そこまでやらないなら、nullable/tag の置き換えに留まるので Close でよいと思います。

@esnya esnya force-pushed the codex/type-building-metric-values branch from ed18dd2 to 77865b8 Compare June 1, 2026 17:35
@esnya esnya force-pushed the codex/type-georeferenced-raster-sources branch from 1059dc2 to 92c3f43 Compare June 1, 2026 18:55
@esnya esnya force-pushed the codex/type-building-metric-values branch from 77865b8 to cd833cf Compare June 1, 2026 18:59
@esnya
Copy link
Copy Markdown
Owner Author

esnya commented Jun 1, 2026

レビュー対応しました。Missing / Invalid を BuildingAttributeContext に流す runtime variant は削除し、parser 境界で欠損・不正メトリックを落として BuildingMetricMeasurements には known 値だけを載せる形に変えました。下流 consumer は BuildingMetricKind ごとの known metric lookup のみを行うため、metric pipeline が Missing / Invalid を受け取る経路はなくなっています。\n\n検証:\n- dotnet restore PlateauResoniteLink.sln --locked-mode --disable-build-servers\n- dotnet format whitespace . --folder --verify-no-changes\n- dotnet build PlateauResoniteLink.sln --configuration Release --no-restore --disable-build-servers -m:1 -p:UseSharedCompilation=false\n- dotnet test PlateauResoniteLink.sln --configuration Release --no-restore --verbosity normal -m:1 --disable-build-servers -p:UseSharedCompilation=false\n- Fake Live Sink canonical dump for plateau-13213-higashimurayama-shi-2020 / 53395325 / dem,bldg / grid matched the existing semantic baseline with git diff --no-index.

@esnya esnya force-pushed the codex/type-georeferenced-raster-sources branch from 94e8676 to 4e07e62 Compare June 2, 2026 14:33
@esnya esnya force-pushed the codex/type-building-metric-values branch 2 times, most recently from ef1eec5 to bc6a4f7 Compare June 2, 2026 18:24
@esnya esnya force-pushed the codex/type-georeferenced-raster-sources branch 2 times, most recently from 7a7ea10 to b57086b Compare June 2, 2026 20:47
@esnya esnya force-pushed the codex/type-building-metric-values branch from bc6a4f7 to 98dd01b Compare June 2, 2026 20:47
@esnya esnya changed the base branch from codex/type-georeferenced-raster-sources to main June 2, 2026 20:48
@esnya
Copy link
Copy Markdown
Owner Author

esnya commented Jun 3, 2026

コード量を縮小していく前提では、この PR はまだ受け入れにくいです。最終差分は +219/-87 で、BuildingAttributeContext の明示フィールドを BuildingMetricMeasurements + BuildingMetricKind + dictionary へ置き換えていますが、現時点の metric 種別は固定的で、消費側も既知 metric を数個読むだけです。非有限値や invalid raw を downstream に流さない目的は parser 側で小さく達成できる一方、この形は compile-time に見えていた属性スキーマを dictionary lookup にして呼び出し側の記述も増やしています。増加分に見合う強い必然性がまだ見えません。受け入れるなら、少なくとも現在必要な不正値排除だけに絞って差分を縮めるか、固定フィールドを捨てて map 化する必要性を現在の要件で説明できる形にしてほしいです。

@esnya esnya force-pushed the codex/type-building-metric-values branch from 98dd01b to aebe70c Compare June 4, 2026 07:30
@esnya esnya merged commit db8e558 into main Jun 4, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant