Skip to content

[THIS-1080] 👨‍✈️Governed spaces.#1591

Merged
doctrino merged 13 commits intomainfrom
deploy-other-spaces
Mar 16, 2026
Merged

[THIS-1080] 👨‍✈️Governed spaces.#1591
doctrino merged 13 commits intomainfrom
deploy-other-spaces

Conversation

@doctrino
Copy link
Copy Markdown
Contributor

@doctrino doctrino commented Mar 15, 2026

Description

New alpha feature, - governed spaces. This enable the user to include containres/views in the validation and deployment that are not part of the data model.

Bump

  • Patch
  • Skip

Changelog

Added

  • [alpha] Alpha flag that enables you to govern containers/views in different spaces than the data model. This means Neat will allow you to deploy to these spaces as well as account for it in its validation.

@gemini-code-assist
Copy link
Copy Markdown
Contributor

Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here.

@github-actions
Copy link
Copy Markdown

github-actions bot commented Mar 15, 2026

☂️ Python Coverage

current status: ✅

Overall Coverage

Lines Covered Coverage Threshold Status
7330 6774 92% 90% 🟢

New Files

No new covered files...

Modified Files

File Coverage Status
cognite/neat/_config.py 86% 🟢
cognite/neat/_data_model/_analysis.py 96% 🟢
cognite/neat/_data_model/deployer/deployer.py 95% 🟢
cognite/neat/_data_model/exporters/_table_exporter/writer.py 95% 🟢
cognite/neat/_data_model/importers/_table_importer/reader.py 92% 🟢
cognite/neat/_data_model/models/dms/_schema.py 100% 🟢
cognite/neat/_data_model/rules/dms/_containers.py 94% 🟢
cognite/neat/_data_model/rules/dms/_orchestrator.py 98% 🟢
cognite/neat/_session/_physical.py 73% 🟢
TOTAL 92% 🟢

updated for commit: 646270a by action🐍

@codecov
Copy link
Copy Markdown

codecov bot commented Mar 15, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 91.85%. Comparing base (15ad6fa) to head (646270a).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1591      +/-   ##
==========================================
+ Coverage   91.79%   91.85%   +0.05%     
==========================================
  Files         126      126              
  Lines        7451     7468      +17     
==========================================
+ Hits         6840     6860      +20     
+ Misses        611      608       -3     
Files with missing lines Coverage Δ
cognite/neat/_config.py 86.23% <100.00%> (+0.12%) ⬆️
cognite/neat/_data_model/_analysis.py 95.49% <100.00%> (+0.01%) ⬆️
cognite/neat/_data_model/deployer/deployer.py 93.04% <100.00%> (+1.33%) ⬆️
...at/_data_model/exporters/_table_exporter/writer.py 95.29% <100.00%> (ø)
...at/_data_model/importers/_table_importer/reader.py 91.65% <100.00%> (+0.01%) ⬆️
cognite/neat/_data_model/models/dms/_schema.py 100.00% <100.00%> (+6.25%) ⬆️
cognite/neat/_data_model/rules/dms/_containers.py 93.40% <100.00%> (ø)
...ognite/neat/_data_model/rules/dms/_orchestrator.py 97.50% <100.00%> (+0.27%) ⬆️
cognite/neat/_session/_physical.py 73.10% <ø> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@doctrino doctrino force-pushed the deploy-other-spaces branch from 20340e5 to 3ce89c6 Compare March 15, 2026 11:05
Comment on lines -24 to +25
enable_alpha_validators: bool = False,
alpha_flags: AlphaFlagConfig | None = None,
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Switch this one and pas the entire alpha flag config.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thing to consider is to enable users to set a global Alpha == True, as I have feeling we will accumulate a number of alpha features, and it could be tedious if user needs to set each individually to True.

@doctrino
Copy link
Copy Markdown
Contributor Author

/gemini review

@doctrino doctrino marked this pull request as ready for review March 15, 2026 12:44
@doctrino doctrino requested a review from a team as a code owner March 15, 2026 12:44
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request introduces the 'governed spaces' alpha feature, allowing containers and views from spaces other than the main data model space to be included in validation and deployment. The changes are spread across configuration, data model analysis, deployment logic, and schema definitions. My review focuses on ensuring the new logic is correctly implemented and adheres to the project's coding standards. I've identified a typo in a variable name and an opportunity to improve type safety by avoiding typing.Any.

Copy link
Copy Markdown
Contributor

@nikokaoja nikokaoja left a comment

Choose a reason for hiding this comment

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

Good stuff!

continue

if property_.container.space == self.validation_resources.merged_data_model.space:
if property_.container.space in self.validation_resources.governed_spaces:
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

this is now super clean, and that self.validation_resources.merged_data_model space was not the most cleanest implementation (I must say, taking blame)

Comment on lines -24 to +25
enable_alpha_validators: bool = False,
alpha_flags: AlphaFlagConfig | None = None,
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thing to consider is to enable users to set a global Alpha == True, as I have feeling we will accumulate a number of alpha features, and it could be tedious if user needs to set each individually to True.

@doctrino doctrino merged commit 9a95a2e into main Mar 16, 2026
10 checks passed
@doctrino doctrino deleted the deploy-other-spaces branch March 16, 2026 13:07
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.

2 participants