Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[NEAT-374, NEAT-368 Part 2]👻 Refactor utility module part2 #549

Merged
merged 12 commits into from
Jul 18, 2024

Conversation

doctrino
Copy link
Collaborator

No description provided.

@doctrino doctrino requested a review from a team as a code owner July 17, 2024 15:30
@doctrino doctrino changed the base branch from main to refactor-utility-module July 17, 2024 15:30
Base automatically changed from refactor-utility-module to main July 18, 2024 07:26
Copy link
Collaborator

@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.

Great work! Now UTILS is neatly organized

@@ -12,7 +12,7 @@
from cognite.neat.constants import DEFAULT_NAMESPACE
from cognite.neat.graph.extractors._base import BaseExtractor
from cognite.neat.graph.models import Triple
from cognite.neat.utils.utils import create_sha256_hash, string_to_ideal_type
from cognite.neat.utils.auxiliary import create_sha256_hash, string_to_ideal_type
Copy link
Collaborator

Choose a reason for hiding this comment

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

:) finally it is renamed :D , I like the new name of module

@@ -15,8 +15,8 @@
from cognite.neat.legacy.graph.stores import NeatGraphStoreBase
from cognite.neat.legacy.rules.models import Rules
from cognite.neat.legacy.rules.models.rules import Property
from cognite.neat.utils import remove_namespace_from_uri
from cognite.neat.utils.utils import epoch_now_ms
from cognite.neat.utils.rdf_ import remove_namespace_from_uri
Copy link
Collaborator

Choose a reason for hiding this comment

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

nice to move rdf specific methods to appropriate submodule

Copy link
Collaborator

Choose a reason for hiding this comment

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

is there a reason for having _ at the end of the module?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

To avoid naming conflicts, but might now be necessary.

Copy link

☂️ Python Coverage

current status: ✅

Overall Coverage

Lines Covered Coverage Threshold Status
22764 15973 70% 60% 🟢

New Files

File Coverage Status
cognite/neat/utils/collection_.py 73% 🟢
cognite/neat/utils/rdf_.py 80% 🟢
cognite/neat/utils/time_.py 80% 🟢
TOTAL 77% 🟢

Modified Files

File Coverage Status
cognite/neat/app/api/routers/data_exploration.py 56% 🟢
cognite/neat/graph/extractors/_classic_cdf/_assets.py 91% 🟢
cognite/neat/graph/extractors/_classic_cdf/_events.py 81% 🟢
cognite/neat/graph/extractors/_classic_cdf/_files.py 78% 🟢
cognite/neat/graph/extractors/_classic_cdf/_labels.py 95% 🟢
cognite/neat/graph/extractors/_classic_cdf/_relationships.py 96% 🟢
cognite/neat/graph/extractors/_classic_cdf/_sequences.py 82% 🟢
cognite/neat/graph/extractors/_classic_cdf/_timeseries.py 76% 🟢
cognite/neat/graph/extractors/_dexpi.py 89% 🟢
cognite/neat/graph/extractors/_mock_graph_generator.py 19% 🟢
cognite/neat/graph/loaders/_rdf2dms.py 75% 🟢
cognite/neat/graph/queries/_base.py 72% 🟢
cognite/neat/graph/queries/_construct.py 35% 🟢
cognite/neat/graph/queries/_shared.py 40% 🟢
cognite/neat/legacy/graph/extractors/_mock_graph_generator.py 83% 🟢
cognite/neat/legacy/graph/loaders/_asset_loader.py 86% 🟢
cognite/neat/legacy/graph/loaders/core/rdf_to_assets.py 79% 🟢
cognite/neat/legacy/graph/loaders/core/rdf_to_relationships.py 64% 🟢
cognite/neat/legacy/graph/loaders/rdf_to_dms.py 55% 🟢
cognite/neat/legacy/graph/transformations/query_generator/sparql.py 85% 🟢
cognite/neat/legacy/graph/transformations/transformer.py 87% 🟢
cognite/neat/legacy/rules/exporters/_rules2dms.py 48% 🟢
cognite/neat/legacy/rules/exporters/_rules2graphql.py 91% 🟢
cognite/neat/legacy/rules/exporters/_rules2ontology.py 84% 🟢
cognite/neat/legacy/rules/exporters/_rules2pydantic_models.py 86% 🟢
cognite/neat/legacy/rules/importers/_graph2rules.py 90% 🟢
cognite/neat/legacy/rules/importers/_owl2rules/_owl2classes.py 95% 🟢
cognite/neat/legacy/rules/importers/_owl2rules/_owl2metadata.py 65% 🟢
cognite/neat/legacy/rules/importers/_owl2rules/_owl2properties.py 97% 🟢
cognite/neat/legacy/rules/models/raw_rules.py 82% 🟢
cognite/neat/rules/analysis/_base.py 83% 🟢
cognite/neat/rules/analysis/_information.py 84% 🟢
cognite/neat/rules/exporters/_rules2ontology.py 88% 🟢
cognite/neat/rules/importers/_inference2rules.py 92% 🟢
cognite/neat/rules/importers/_owl2rules/_owl2classes.py 96% 🟢
cognite/neat/rules/importers/_owl2rules/_owl2metadata.py 70% 🟢
cognite/neat/rules/importers/_owl2rules/_owl2properties.py 96% 🟢
cognite/neat/rules/models/dms/_schema.py 85% 🟢
cognite/neat/rules/models/entities.py 88% 🟢
cognite/neat/rules/models/information/_validation.py 86% 🟢
cognite/neat/utils/init.py 100% 🟢
cognite/neat/utils/auxiliary.py 86% 🟢
cognite/neat/utils/text.py 70% 🟢
cognite/neat/workflows/base.py 65% 🟢
cognite/neat/workflows/steps/lib/legacy/graph_extractor.py 24% 🟢
cognite/neat/workflows/steps/lib/legacy/graph_loader.py 57% 🟢
cognite/neat/workflows/steps/lib/legacy/rules_exporter.py 37% 🟢
cognite/neat/workflows/steps/lib/legacy/rules_importer.py 30% 🟢
TOTAL 75% 🟢

updated for commit: a6662d7 by action🐍

@doctrino doctrino merged commit 1664ed0 into main Jul 18, 2024
7 checks passed
@doctrino doctrino deleted the refactor-utility-module-part2 branch July 18, 2024 07:42
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