From 6a9180837c291aaf3f1e12d947a9f37f477fbf71 Mon Sep 17 00:00:00 2001 From: Yaroslav Halchenko Date: Tue, 23 Sep 2025 13:00:50 -0400 Subject: [PATCH 01/10] Add github action to codespell main on push and PRs Signed-off-by: Yaroslav Halchenko --- .github/workflows/codespell.yml | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 .github/workflows/codespell.yml diff --git a/.github/workflows/codespell.yml b/.github/workflows/codespell.yml new file mode 100644 index 0000000000..b231667430 --- /dev/null +++ b/.github/workflows/codespell.yml @@ -0,0 +1,25 @@ +# Codespell configuration is within pyproject.toml +--- +name: Codespell + +on: + push: + branches: [main] + pull_request: + branches: [main] + +permissions: + contents: read + +jobs: + codespell: + name: Check for spelling errors + runs-on: ubuntu-latest + + steps: + - name: Checkout + uses: actions/checkout@v4 + - name: Annotate locations with typos + uses: codespell-project/codespell-problem-matcher@v1 + - name: Codespell + uses: codespell-project/actions-codespell@v2 From 0e187ff90cf6b33519acbf4a0c56322c38535723 Mon Sep 17 00:00:00 2001 From: Yaroslav Halchenko Date: Tue, 23 Sep 2025 13:05:17 -0400 Subject: [PATCH 02/10] Add pre-commit definition for codespell Signed-off-by: Yaroslav Halchenko --- .pre-commit-config.yaml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 2aeca00e01..29512351f1 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -47,3 +47,9 @@ repos: - id: detect-secrets args: ['--baseline', '.secrets.baseline'] exclude: ^features/test_starter + + - repo: https://github.com/codespell-project/codespell + # Configuration for codespell is in .pre-commit-config.yaml + rev: v2.4.1 + hooks: + - id: codespell From bdef1461f51f748a2ed0f81605148f5515dfab51 Mon Sep 17 00:00:00 2001 From: Yaroslav Halchenko Date: Tue, 23 Sep 2025 13:00:50 -0400 Subject: [PATCH 03/10] Add rudimentary codespell config Signed-off-by: Yaroslav Halchenko --- pyproject.toml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/pyproject.toml b/pyproject.toml index b6b2ee7b3a..d2bc347d16 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -256,3 +256,11 @@ known-first-party = ["kedro"] ignore_missing_imports = true disable_error_code = ['misc'] exclude = ['^kedro/templates/', '^docs/', '^features/test_starter/'] + +[tool.codespell] +# Ref: https://github.com/codespell-project/codespell#using-a-config-file +skip = '.git*,*.pdf,*.svg,*.css' +check-hidden = true +# {nam} used in an example as intentional typo +ignore-regex = '(^\s*"image/\S+": ".*|{nam})' +ignore-words-list = 'ans' From 10425b1025d1400ba49c6aea426d0fbfaf797556 Mon Sep 17 00:00:00 2001 From: Yaroslav Halchenko Date: Tue, 23 Sep 2025 13:09:06 -0400 Subject: [PATCH 04/10] [DATALAD RUNCMD] Annotate to ignore some lines with 'fo' === Do not change lines below === { "chain": [], "cmd": "sed -i -e 's,\\(fo=conf_source.*\\),\\1 # codespell:ignore,g' ./kedro/config/omegaconf_config.py", "exit": 0, "extra_inputs": [], "inputs": [], "outputs": [], "pwd": "." } ^^^ Do not change lines above ^^^ Signed-off-by: Yaroslav Halchenko --- kedro/config/omegaconf_config.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/kedro/config/omegaconf_config.py b/kedro/config/omegaconf_config.py index de558855cf..ec98873652 100644 --- a/kedro/config/omegaconf_config.py +++ b/kedro/config/omegaconf_config.py @@ -389,13 +389,13 @@ def _initialise_filesystem_and_protocol( # Check if it's an archive file file_mimetype, _ = mimetypes.guess_type(conf_source) if file_mimetype == "application/x-tar": - return fsspec.filesystem(protocol="tar", fo=conf_source), "tar" + return fsspec.filesystem(protocol="tar", fo=conf_source), "tar" # codespell:ignore elif file_mimetype in ( "application/zip", "application/x-zip-compressed", "application/zip-compressed", ): - return fsspec.filesystem(protocol="zip", fo=conf_source), "zip" + return fsspec.filesystem(protocol="zip", fo=conf_source), "zip" # codespell:ignore # Parse to check for protocol options = _parse_filepath(conf_source) @@ -407,7 +407,7 @@ def _initialise_filesystem_and_protocol( return fsspec.filesystem(protocol=protocol), protocol else: # Default to local filesystem - return fsspec.filesystem(protocol="file", fo=conf_source), "file" + return fsspec.filesystem(protocol="file", fo=conf_source), "file" # codespell:ignore def _merge_configs( self, From 83bdd0893ad9fa5ec6260efdd0356428eed8a4f8 Mon Sep 17 00:00:00 2001 From: Yaroslav Halchenko Date: Tue, 23 Sep 2025 13:10:02 -0400 Subject: [PATCH 05/10] [DATALAD RUNCMD] chore: run codespell throughout fixing a few typos interactively === Do not change lines below === { "chain": [], "cmd": "codespell -w -i 3 -C 4 ./tests/framework/project/test_logging.py ./kedro/io/catalog_config_resolver.py", "exit": 0, "extra_inputs": [], "inputs": [], "outputs": [], "pwd": "." } ^^^ Do not change lines above ^^^ Signed-off-by: Yaroslav Halchenko --- kedro/io/catalog_config_resolver.py | 6 +++--- tests/framework/project/test_logging.py | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/kedro/io/catalog_config_resolver.py b/kedro/io/catalog_config_resolver.py index 17dcd21f2e..2ae840fba0 100644 --- a/kedro/io/catalog_config_resolver.py +++ b/kedro/io/catalog_config_resolver.py @@ -394,7 +394,7 @@ def list_patterns(self) -> list[str]: return patterns @classmethod - def _get_matches(cls, pattens: Iterable[str], ds_name: str) -> Generator[str]: + def _get_matches(cls, patterns: Iterable[str], ds_name: str) -> Generator[str]: """ Find all patterns that match a given dataset name. @@ -402,7 +402,7 @@ def _get_matches(cls, pattens: Iterable[str], ds_name: str) -> Generator[str]: dataset name matches any of them using the `parse` function. Args: - pattens: A collection of patterns to match against. + patterns: A collection of patterns to match against. ds_name: The name of the dataset to match. Returns: @@ -416,7 +416,7 @@ def _get_matches(cls, pattens: Iterable[str], ds_name: str) -> Generator[str]: # ['{namespace}.int_{name}'] ``` """ - return (pattern for pattern in pattens if parse(pattern, ds_name)) + return (pattern for pattern in patterns if parse(pattern, ds_name)) def match_dataset_pattern(self, ds_name: str) -> str | None: """ diff --git a/tests/framework/project/test_logging.py b/tests/framework/project/test_logging.py index 47b0a93c6a..68ec8adc96 100644 --- a/tests/framework/project/test_logging.py +++ b/tests/framework/project/test_logging.py @@ -113,7 +113,7 @@ def test_rich_traceback_configuration(mocker, default_logging_config): def test_rich_traceback_configuration_extend_suppress(mocker, default_logging_config): - """Test the configuration is not overrided but extend for `suppress`""" + """Test the configuration is not overridden but extend for `suppress`""" import click rich_traceback_install = mocker.patch("rich.traceback.install") From b9a8df5b3e16e989609aad9381e820e768e1b937 Mon Sep 17 00:00:00 2001 From: Yaroslav Halchenko Date: Wed, 24 Sep 2025 08:50:07 -0400 Subject: [PATCH 06/10] [DATALAD RUNCMD] chore: run codespell throughout fixing a few new typos automagically === Do not change lines below === { "chain": [], "cmd": "codespell -w", "exit": 0, "extra_inputs": [], "inputs": [], "outputs": [], "pwd": "." } ^^^ Do not change lines above ^^^ --- docs/catalog-data/advanced_data_catalog_usage.md | 2 +- docs/create/new_project.md | 2 +- docs/deploy/distributed.md | 2 +- docs/deploy/supported-platforms/kubeflow.md | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/catalog-data/advanced_data_catalog_usage.md b/docs/catalog-data/advanced_data_catalog_usage.md index 1c309caff3..579afa56a1 100644 --- a/docs/catalog-data/advanced_data_catalog_usage.md +++ b/docs/catalog-data/advanced_data_catalog_usage.md @@ -103,7 +103,7 @@ catalog["cars"] = ["Ferrari", "Audi"] # Add raw data ``` When raw data is added, it's automatically wrapped in a `MemoryDataset`. -## How to iterate trough datasets in the catalog +## How to iterate through datasets in the catalog `DataCatalog` supports iteration over dataset names (keys), datasets (values), and both (items). Iteration defaults to dataset names, similar to standard Python dictionaries: diff --git a/docs/create/new_project.md b/docs/create/new_project.md index 04d2561088..48a7efcae6 100644 --- a/docs/create/new_project.md +++ b/docs/create/new_project.md @@ -130,7 +130,7 @@ kedro run ``` ```{warning} -`kedro run` requires at least one pipeline with nodes. Please define a pipeline before running this command and ensure it is registred in `pipeline_registry.py`. +`kedro run` requires at least one pipeline with nodes. Please define a pipeline before running this command and ensure it is registered in `pipeline_registry.py`. ``` ## Visualise a Kedro project diff --git a/docs/deploy/distributed.md b/docs/deploy/distributed.md index da29bbdff1..88bfd1f954 100644 --- a/docs/deploy/distributed.md +++ b/docs/deploy/distributed.md @@ -40,4 +40,4 @@ We encourage you to play with different ways of parameterising your runs as you ## 4. (Optional) Create starters -You may opt to [build your own Kedro starter](../tutorials/settings.md) if you regularly have to deploy in a similar environment or to a similar platform. The starter enables you to re-use any deployment scripts written as part of step 2. +You may opt to [build your own Kedro starter](../tutorials/settings.md) if you regularly have to deploy in a similar environment or to a similar platform. The starter enables you to reuse any deployment scripts written as part of step 2. diff --git a/docs/deploy/supported-platforms/kubeflow.md b/docs/deploy/supported-platforms/kubeflow.md index 44c426597e..05fffe03ff 100644 --- a/docs/deploy/supported-platforms/kubeflow.md +++ b/docs/deploy/supported-platforms/kubeflow.md @@ -8,7 +8,7 @@ Here are the main reasons to use Kubeflow Pipelines: - It is cloud-agnostic and can run on any Kubernetes cluster - Kubeflow is tailored towards machine learning workflows for model deployment, experiment tracking, and hyperparameter tuning -- You can re-use components and pipelines to create E2E solutions +- You can reuse components and pipelines to create E2E solutions ## The `kedro-kubeflow` plugin From aecba63c919ec9e0e698126da10e604029c8cc50 Mon Sep 17 00:00:00 2001 From: Merel Theisen Date: Tue, 25 Nov 2025 12:55:19 +0100 Subject: [PATCH 07/10] Remove codespell setup, but keep typo fixes Signed-off-by: Merel Theisen --- .github/workflows/codespell.yml | 25 ------------------------- .pre-commit-config.yaml | 6 ------ kedro/config/omegaconf_config.py | 6 +++--- pyproject.toml | 8 -------- 4 files changed, 3 insertions(+), 42 deletions(-) delete mode 100644 .github/workflows/codespell.yml diff --git a/.github/workflows/codespell.yml b/.github/workflows/codespell.yml deleted file mode 100644 index b231667430..0000000000 --- a/.github/workflows/codespell.yml +++ /dev/null @@ -1,25 +0,0 @@ -# Codespell configuration is within pyproject.toml ---- -name: Codespell - -on: - push: - branches: [main] - pull_request: - branches: [main] - -permissions: - contents: read - -jobs: - codespell: - name: Check for spelling errors - runs-on: ubuntu-latest - - steps: - - name: Checkout - uses: actions/checkout@v4 - - name: Annotate locations with typos - uses: codespell-project/codespell-problem-matcher@v1 - - name: Codespell - uses: codespell-project/actions-codespell@v2 diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 29512351f1..2aeca00e01 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -47,9 +47,3 @@ repos: - id: detect-secrets args: ['--baseline', '.secrets.baseline'] exclude: ^features/test_starter - - - repo: https://github.com/codespell-project/codespell - # Configuration for codespell is in .pre-commit-config.yaml - rev: v2.4.1 - hooks: - - id: codespell diff --git a/kedro/config/omegaconf_config.py b/kedro/config/omegaconf_config.py index b4c887beec..2612199012 100644 --- a/kedro/config/omegaconf_config.py +++ b/kedro/config/omegaconf_config.py @@ -393,13 +393,13 @@ def _initialise_filesystem_and_protocol( # Check if it's an archive file file_mimetype, _ = mimetypes.guess_type(conf_source) if file_mimetype == "application/x-tar": - return fsspec.filesystem(protocol="tar", fo=conf_source), "tar" # codespell:ignore + return fsspec.filesystem(protocol="tar", fo=conf_source), "tar" elif file_mimetype in ( "application/zip", "application/x-zip-compressed", "application/zip-compressed", ): - return fsspec.filesystem(protocol="zip", fo=conf_source), "zip" # codespell:ignore + return fsspec.filesystem(protocol="zip", fo=conf_source), "zip" # Parse to check for protocol options = _parse_filepath(conf_source) @@ -411,7 +411,7 @@ def _initialise_filesystem_and_protocol( return fsspec.filesystem(protocol=protocol), protocol else: # Default to local filesystem - return fsspec.filesystem(protocol="file", fo=conf_source), "file" # codespell:ignore + return fsspec.filesystem(protocol="file", fo=conf_source), "file" def _merge_configs( self, diff --git a/pyproject.toml b/pyproject.toml index c8ae264445..7eab2e1513 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -253,11 +253,3 @@ known-first-party = ["kedro"] ignore_missing_imports = true disable_error_code = ['misc'] exclude = ['^kedro/templates/', '^docs/', '^features/test_starter/'] - -[tool.codespell] -# Ref: https://github.com/codespell-project/codespell#using-a-config-file -skip = '.git*,*.pdf,*.svg,*.css' -check-hidden = true -# {nam} used in an example as intentional typo -ignore-regex = '(^\s*"image/\S+": ".*|{nam})' -ignore-words-list = 'ans' From 8b0c3d676928b613371df0345a70071c39d19d1f Mon Sep 17 00:00:00 2001 From: Merel Theisen Date: Tue, 25 Nov 2025 13:09:19 +0100 Subject: [PATCH 08/10] Convert US spelling to UK spelling Signed-off-by: Merel Theisen --- docs/about/telemetry.md | 2 +- docs/api/framework/kedro.framework.cli.md | 2 +- docs/api/framework/kedro.framework.md | 2 +- docs/catalog-data/advanced_data_catalog_usage.md | 8 ++++---- docs/catalog-data/kedro_dataset_factories.md | 14 +++++++------- docs/catalog-data/lazy_loading.md | 14 +++++++------- docs/create/minimal_kedro_project.md | 4 ++-- .../supported-platforms/amazon_emr_serverless.md | 8 ++++---- docs/deploy/supported-platforms/prefect.md | 4 ++-- docs/extend/hooks/common_use_cases.md | 2 +- docs/extend/session.md | 2 +- docs/getting-started/install.md | 4 ++-- docs/ide/set_up_vscode.md | 2 +- 13 files changed, 34 insertions(+), 34 deletions(-) diff --git a/docs/about/telemetry.md b/docs/about/telemetry.md index 1aa8e231aa..ec526ed6a5 100644 --- a/docs/about/telemetry.md +++ b/docs/about/telemetry.md @@ -3,7 +3,7 @@ To help the [Kedro Project maintainers](../about/technical_steering_committee.md Kedro can capture anonymised telemetry. This data is collected with the sole purpose of improving Kedro by understanding feature usage. Importantly, we do not store personal information about you or sensitive data from your project, -and this process is never utilized for marketing or promotional purposes. +and this process is never utilised for marketing or promotional purposes. Participation in this program is optional, and it is enabled by default. Kedro will continue working as normal if you opt-out. The Kedro Project's telemetry has been reviewed and approved under the diff --git a/docs/api/framework/kedro.framework.cli.md b/docs/api/framework/kedro.framework.cli.md index 45fa2b0350..0e84a6429c 100644 --- a/docs/api/framework/kedro.framework.cli.md +++ b/docs/api/framework/kedro.framework.cli.md @@ -8,7 +8,7 @@ |------------------------------------|-----------------------------------------------------------------------------| | [`kedro.framework.cli.catalog`](#kedro.framework.cli.catalog) | A collection of CLI commands for working with Kedro catalog. | | [`kedro.framework.cli.cli`](#kedro.framework.cli.cli) | `kedro` is a CLI for managing Kedro projects. | -| [`kedro.framework.cli.hooks`](#kedro.framework.cli.hooks) | Provides primitives to use hooks to extend KedroCLI's behavior. | +| [`kedro.framework.cli.hooks`](#kedro.framework.cli.hooks) | Provides primitives to use hooks to extend KedroCLI's behaviour. | | [`kedro.framework.cli.jupyter`](#kedro.framework.cli.jupyter) | A collection of helper functions to integrate with Jupyter/IPython. | | [`kedro.framework.cli.pipeline`](#kedro.framework.cli.pipeline) | A collection of CLI commands for working with Kedro pipelines. | | [`kedro.framework.cli.project`](#kedro.framework.cli.project) | A collection of CLI commands for working with Kedro projects. | diff --git a/docs/api/framework/kedro.framework.md b/docs/api/framework/kedro.framework.md index 6e6b329922..40fedec6ff 100644 --- a/docs/api/framework/kedro.framework.md +++ b/docs/api/framework/kedro.framework.md @@ -8,7 +8,7 @@ |---------------------------------|-----------------------------------------------------------------------------| | [`kedro.framework.cli`](kedro.framework.cli.md) | Implements commands available from Kedro's CLI. | | [`kedro.framework.context`](kedro.framework.context.md) | Provides functionality for loading Kedro project context. | -| [`kedro.framework.hooks`](kedro.framework.hooks.md) | Provides primitives to use hooks to extend KedroContext's behavior. | +| [`kedro.framework.hooks`](kedro.framework.hooks.md) | Provides primitives to use hooks to extend KedroContext's behaviour. | | [`kedro.framework.project`](kedro.framework.project.md) | Provides utilities to configure a Kedro project and access its settings.| | [`kedro.framework.session`](kedro.framework.session.md) | Provides access to `KedroSession` responsible for project lifecycle. | | [`kedro.framework.startup`](kedro.framework.startup.md) | Provides metadata for a Kedro project. | | diff --git a/docs/catalog-data/advanced_data_catalog_usage.md b/docs/catalog-data/advanced_data_catalog_usage.md index 579afa56a1..f3bf904a7c 100644 --- a/docs/catalog-data/advanced_data_catalog_usage.md +++ b/docs/catalog-data/advanced_data_catalog_usage.md @@ -82,7 +82,7 @@ intermediate_ds = catalog.get("intermediate_ds", fallback_to_runtime_pattern=Tru ``` - Both methods retrieve a dataset by name from the catalog’s internal collection. -- If the dataset isn’t materialized but matches a configured pattern, it's instantiated and returned. +- If the dataset isn’t materialised but matches a configured pattern, it's instantiated and returned. - The `.get()` method accepts: - `fallback_to_runtime_pattern` (bool): If True, unresolved names fallback to `MemoryDataset` or `SharedMemoryDataset` (in `SharedMemoryDataCatalog`). - `version`: Specify dataset version if versioning is enabled. @@ -341,7 +341,7 @@ patterns = catalog.config_resolver.list_patterns() # List all patterns ## How to save catalog to config -You can serialize a `DataCatalog` into configuration format (e.g., for saving to a YAML file) using `.to_config()`: +You can serialise a `DataCatalog` into configuration format (e.g., for saving to a YAML file) using `.to_config()`: ```python from kedro.io import DataCatalog @@ -362,7 +362,7 @@ new_catalog = DataCatalog.from_config(config, credentials, load_versions, save_v ``` !!! note - This method only works for datasets with static, serializable parameters. For example, you can serialize credentials passed as dictionaries, but not as actual credential objects (like `google.auth.credentials.Credentials)`. In-memory datasets are excluded. + This method only works for datasets with static, serialisable parameters. For example, you can serialise credentials passed as dictionaries, but not as actual credential objects (like `google.auth.credentials.Credentials)`. In-memory datasets are excluded. ## How to filter catalog datasets @@ -382,7 +382,7 @@ catalog.filter(name_regex="data", by_type=[MemoryDataset, SQLQueryDataset]) # M ``` ## How to get dataset type -You can check the dataset type without materializing or adding it to the catalog: +You can check the dataset type without materialising or adding it to the catalog: ```python from kedro.io import DataCatalog, MemoryDataset diff --git a/docs/catalog-data/kedro_dataset_factories.md b/docs/catalog-data/kedro_dataset_factories.md index 6d03838590..c2d839b341 100644 --- a/docs/catalog-data/kedro_dataset_factories.md +++ b/docs/catalog-data/kedro_dataset_factories.md @@ -93,7 +93,7 @@ default_runtime_patterns: ClassVar = { These patterns enable automatic creation of in-memory or shared-memory datasets during execution. ## Patterns resolution order -When the `DataCatalog` is initialized, it scans the configuration to extract and validate any dataset patterns and user catch-all pattern. +When the `DataCatalog` is initialised, it scans the configuration to extract and validate any dataset patterns and user catch-all pattern. When resolving a dataset name, Kedro uses the following order of precedence: @@ -104,7 +104,7 @@ Specific patterns defined in the `catalog.yml`. These are the most explicit and A general fallback pattern (e.g., `{default_dataset}`) that is matched if no dataset patterns apply. Only one user catch-all pattern is allowed. Multiple will raise a `DatasetError`. 3. **Default runtime patterns:** -Internal fallback behavior provided by Kedro. These patterns are built-in to catalog and automatically used at runtime to create datasets (e.g., `MemoryDatase`t or `SharedMemoryDataset`) when none of the above match. +Internal fallback behaviour provided by Kedro. These patterns are built-in to catalog and automatically used at runtime to create datasets (e.g., `MemoryDatase`t or `SharedMemoryDataset`) when none of the above match. ## How resolution works in practice @@ -153,10 +153,10 @@ WARNING: Config from the dataset pattern '{default_dataset}' in the catalog will Out[2]: CSVDataset(filepath=.../data/nonexistent.csv) ``` -**Default vs runtime behavior** +**Default vs runtime behaviour** -- Default behavior: `DataCatalog` resolves dataset patterns and user catch-all patterns only. -- Runtime behavior (e.g. during `kedro run`): Default runtime patterns are automatically enabled to resolve intermediate datasets not defined in `catalog.yml`. +- Default behaviour: `DataCatalog` resolves dataset patterns and user catch-all patterns only. +- Runtime behaviour (e.g. during `kedro run`): Default runtime patterns are automatically enabled to resolve intermediate datasets not defined in `catalog.yml`. !!! note Enabling `fallback_to_runtime_pattern=True` is recommended only for advanced users with specific use cases. In most scenarios, Kedro handles it automatically during runtime. @@ -475,7 +475,7 @@ At the core of this implementation is the `CatalogCommandsMixin` - a mixin class **Why use a mixin?** -The goal was to keep pipeline logic decoupled from the core `DataCatalog`, while still providing seamless access to helpful methods utilizing pipelines. +The goal was to keep pipeline logic decoupled from the core `DataCatalog`, while still providing seamless access to helpful methods utilising pipelines. This mixin approach allows these commands to be injected only when needed - avoiding unnecessary overhead in simpler catalog use cases. @@ -486,7 +486,7 @@ You don't need to do anything if: - You're using Kedro via CLI, or - Working inside an interactive environment (e.g. IPython, Jupyter Notebook). -Kedro automatically composes the catalog with `CatalogCommandsMixin` behind the scenes when initializing the session. +Kedro automatically composes the catalog with `CatalogCommandsMixin` behind the scenes when initialising the session. If you're working outside a Kedro session and want to access the extra catalog commands, you have two options: diff --git a/docs/catalog-data/lazy_loading.md b/docs/catalog-data/lazy_loading.md index c41eef84bf..6131063f4d 100644 --- a/docs/catalog-data/lazy_loading.md +++ b/docs/catalog-data/lazy_loading.md @@ -1,14 +1,14 @@ # Lazy loading -From Kedro version **`0.19.10`** `DataCatalog` introduces a helper class called `_LazyDataset` to improve performance and optimize dataset loading. +From Kedro version **`0.19.10`** `DataCatalog` introduces a helper class called `_LazyDataset` to improve performance and optimise dataset loading. ## What is `_LazyDataset`? -`_LazyDataset` is a lightweight internal class that stores the configuration and versioning information of a dataset without immediately instantiating it. This allows the catalog to defer actual dataset creation (also called materialization) until it is explicitly accessed. -This approach reduces startup overhead, especially when working with large catalogs, since only the datasets you actually use are initialized. +`_LazyDataset` is a lightweight internal class that stores the configuration and versioning information of a dataset without immediately instantiating it. This allows the catalog to defer actual dataset creation (also called materialisation) until it is explicitly accessed. +This approach reduces startup overhead, especially when working with large catalogs, since only the datasets you actually use are initialised. ## When is `_LazyDataset` used? When you instantiate a `DataCatalog` from a config file (such as `catalog.yml`), Kedro doesn't immediately create all the underlying dataset objects. Instead, it wraps each dataset in a `_LazyDataset` and registers it in the catalog. -These placeholders are automatically materialized when a dataset is accessed for the first time-either directly or during pipeline execution. +These placeholders are automatically materialised when a dataset is accessed for the first time-either directly or during pipeline execution. ```bash In [1]: catalog @@ -27,7 +27,7 @@ Out[2]: kedro_datasets.pandas.excel_dataset.ExcelDataset( writer_args={'engine': 'openpyxl'} ) -# Accessing the dataset triggers materialization. +# Accessing the dataset triggers materialisation. In [3]: catalog Out[3]: { @@ -42,10 +42,10 @@ Out[3]: { ``` ## When is this useful? -This lazy loading mechanism is especially beneficial before runtime, during the warm-up phase of a pipeline. You can force materialization of all datasets early on to: +This lazy loading mechanism is especially beneficial before runtime, during the warm-up phase of a pipeline. You can force materialisation of all datasets early on to: - Catch configuration or import errors - Validate external dependencies - Ensure all datasets can be created before execution begins -Although `_LazyDataset` is not exposed to end users and doesn't affect your usual catalog usage, it's a useful concept to understand when debugging catalog behavior or troubleshooting dataset instantiation issues. +Although `_LazyDataset` is not exposed to end users and doesn't affect your usual catalog usage, it's a useful concept to understand when debugging catalog behaviour or troubleshooting dataset instantiation issues. diff --git a/docs/create/minimal_kedro_project.md b/docs/create/minimal_kedro_project.md index 8e8ffa5384..c990b7134d 100644 --- a/docs/create/minimal_kedro_project.md +++ b/docs/create/minimal_kedro_project.md @@ -50,12 +50,12 @@ This informs Kedro where to look for the source code, `settings.py` and `pipelin The `settings.py` file is an important configuration file in a Kedro project that allows you to define various settings and hooks for your project. Here’s a breakdown of its purpose and functionality: - Project Settings: This file is where you can configure project-wide settings, such as defining the logging level, setting environment variables, or specifying paths for data and outputs. - Hooks Registration: You can register custom hooks in `settings.py`, which are functions that can be executed at specific points in the Kedro pipeline lifecycle (e.g., before or after a node runs). This is useful for adding additional functionality, such as logging or monitoring. -- Integration with Plugins: If you are using Kedro plugins, `settings.py` can also be utilized to configure them appropriately. +- Integration with Plugins: If you are using Kedro plugins, `settings.py` can also be utilised to configure them appropriately. Even if you do not have any settings, an empty `settings.py` is still required. Typically, they are stored at `src//settings.py`. #### `pipeline_registry.py` -The `pipeline_registry.py` file is essential for managing the pipelines within your Kedro project. It provides a centralized way to register and access all pipelines defined in the project. Here are its key features: +The `pipeline_registry.py` file is essential for managing the pipelines within your Kedro project. It provides a centralised way to register and access all pipelines defined in the project. Here are its key features: - Pipeline Registration: The file must contain a top-level function called `register_pipelines()` that returns a mapping from pipeline names to Pipeline objects. This function is crucial because it enables the Kedro CLI and other tools to discover and run the defined pipelines. - Autodiscovery of Pipelines: Since Kedro 0.18.3, you can use the [`find_pipeline`](../build/pipeline_registry.md#pipeline-autodiscovery) function to automatically discover pipelines defined in your project without manually updating the registry each time you create a new pipeline. diff --git a/docs/deploy/supported-platforms/amazon_emr_serverless.md b/docs/deploy/supported-platforms/amazon_emr_serverless.md index 16668f57b2..6efd398300 100644 --- a/docs/deploy/supported-platforms/amazon_emr_serverless.md +++ b/docs/deploy/supported-platforms/amazon_emr_serverless.md @@ -5,7 +5,7 @@ can be used to manage and execute distributed computing workloads using Apache S independently allocates the resources needed for each job and releases them at completion. EMR Serverless is typically used for pipelines that are either fully or partially dependent on PySpark. -For other parts of the pipeline such as modeling, where a non-distributed computing approach may be suitable, EMR Serverless might not be needed. +For other parts of the pipeline such as modelling, where a non-distributed computing approach may be suitable, EMR Serverless might not be needed. ## Context @@ -58,7 +58,7 @@ ENV PYENV_ROOT /usr/.pyenv ENV PATH $PYENV_ROOT/shims:$PYENV_ROOT/bin:$PATH ENV PYTHON_VERSION=3.9.16 -# Install pyenv, initialize it, install desired Python version and set as global +# Install pyenv, initialise it, install desired Python version and set as global RUN curl https://pyenv.run | bash RUN eval "$(pyenv init -)" RUN pyenv install ${PYTHON_VERSION} && pyenv global ${PYTHON_VERSION} @@ -94,7 +94,7 @@ For more details, see the following resources: - [Package a Kedro project](https://docs.kedro.org/en/stable/deploy/package_a_project/#package-a-kedro-project) - [Run a packaged project](https://docs.kedro.org/en/stable/deploy/package_a_project/#run-a-packaged-project) -- [Customizing an EMR Serverless image](https://docs.aws.amazon.com/emr/latest/EMR-Serverless-UserGuide/application-custom-image.html) +- [Customising an EMR Serverless image](https://docs.aws.amazon.com/emr/latest/EMR-Serverless-UserGuide/application-custom-image.html) - [Using custom images with EMR Serverless](https://docs.aws.amazon.com/emr/latest/EMR-Serverless-UserGuide/using-custom-images.html) ## Setup @@ -154,7 +154,7 @@ for more details. !!! note On making changes to the custom image, and rebuilding and pushing to ECR, be sure to restart the EMR Serverless application before submitting a job if your application is **already started**. Otherwise, new changes may not be reflected in the job run. - This may be due to the fact that when the application has started, EMR Serverless keeps a pool of warm resources (also referred to as [pre-initialized capacity](https://docs.aws.amazon.com/emr/latest/EMR-Serverless-UserGuide/pre-init-capacity.html)) ready to run a job, and the nodes may have already used the previous version of the ECR image. + This may be due to the fact that when the application has started, EMR Serverless keeps a pool of warm resources (also referred to as [pre-initialised capacity](https://docs.aws.amazon.com/emr/latest/EMR-Serverless-UserGuide/pre-init-capacity.html)) ready to run a job, and the nodes may have already used the previous version of the ECR image. See details on [how to run a Spark job on EMR Serverless](https://docs.aws.amazon.com/emr/latest/EMR-Serverless-UserGuide/jobs-spark.html). diff --git a/docs/deploy/supported-platforms/prefect.md b/docs/deploy/supported-platforms/prefect.md index 926f1ff6bd..55d749eb1d 100644 --- a/docs/deploy/supported-platforms/prefect.md +++ b/docs/deploy/supported-platforms/prefect.md @@ -118,7 +118,7 @@ def my_flow(pipeline_name: str, env: str): metadata = bootstrap_project(project_path) logger.info("Project name: %s", metadata.project_name) - logger.info("Initializing Kedro...") + logger.info("Initialising Kedro...") execution_config = kedro_init( pipeline_name=pipeline_name, project_path=project_path, env=env ) @@ -142,7 +142,7 @@ def kedro_init( env: str, ): """ - Initializes a Kedro session and returns the DataCatalog and + Initialises a Kedro session and returns the DataCatalog and KedroSession """ # bootstrap project within task / flow scope diff --git a/docs/extend/hooks/common_use_cases.md b/docs/extend/hooks/common_use_cases.md index 8ec3a7b84f..a28cbc3571 100644 --- a/docs/extend/hooks/common_use_cases.md +++ b/docs/extend/hooks/common_use_cases.md @@ -2,7 +2,7 @@ ## Use Hooks to extend a node's behaviour -You can use the [`before_node_run` and `after_node_run` Hooks](../../api/framework/kedro.framework.hooks.md#kedro.framework.hooks.specs) to add extra behavior before and after a node's execution. Furthermore, you can apply extra behavior to not only an individual node or an entire Kedro pipeline, but also to a _subset_ of nodes, based on their tags or namespaces: for example, suppose we want to add the following extra behavior to a node: +You can use the [`before_node_run` and `after_node_run` Hooks](../../api/framework/kedro.framework.hooks.md#kedro.framework.hooks.specs) to add extra behaviour before and after a node's execution. Furthermore, you can apply extra behaviour to not only an individual node or an entire Kedro pipeline, but also to a _subset_ of nodes, based on their tags or namespaces: for example, suppose we want to add the following extra behaviour to a node: ```python from kedro.pipeline.node import Node diff --git a/docs/extend/session.md b/docs/extend/session.md index 80ab1484f8..75376ee322 100644 --- a/docs/extend/session.md +++ b/docs/extend/session.md @@ -56,7 +56,7 @@ graph LR subgraph Kedro_Startup_Flowchart A[bootstrap_project] -->|Read pyproject.toml| B A -->|Add project root to sys.path| B[configure_project] - C[Initialize KedroSession] + C[Initialise KedroSession] B --> |Read settings.py| C B --> |Read pipeline_registry.py| C end diff --git a/docs/getting-started/install.md b/docs/getting-started/install.md index 672d4e2d17..b1ed430d18 100644 --- a/docs/getting-started/install.md +++ b/docs/getting-started/install.md @@ -92,7 +92,7 @@ There are several ways to do it: === "conda" `conda` provides package, dependency, and environment management for any language. - Since it uses centralized environments, it is a good option for managing applications and tools. + Since it uses centralised environments, it is a good option for managing applications and tools. After installing it, you can use it to run `kedro new` as follows: @@ -275,7 +275,7 @@ kedro-datasets[pandas-csvdataset, pandas-exceldataset, pandas-parquetdataset]>=3 kedro-telemetry>=0.3.1 kedro-viz~=6.0 # Visualise pipelines -# For modeling in the data science pipeline +# For modelling in the data science pipeline scikit-learn~=1.0 ``` diff --git a/docs/ide/set_up_vscode.md b/docs/ide/set_up_vscode.md index f0605b783c..174c652ae3 100644 --- a/docs/ide/set_up_vscode.md +++ b/docs/ide/set_up_vscode.md @@ -195,7 +195,7 @@ This simplifies fixing dataset errors caused by things such as typos in your dat ## Visualise the pipeline with Kedro-Viz -To visualize your Kedro project using Kedro-Viz in Visual Studio Code, follow these steps: +To visualise your Kedro project using Kedro-Viz in Visual Studio Code, follow these steps: 1. **Open the Command Palette**: Press `Cmd` + `Shift` + `P` (on macOS) or `Ctrl` + `Shift` + `P` (on Windows/Linux). From 210dec68f23f77cd8168b9404c4e9d8f02439c82 Mon Sep 17 00:00:00 2001 From: Merel Theisen Date: Tue, 25 Nov 2025 13:15:24 +0100 Subject: [PATCH 09/10] Fix lint Signed-off-by: Merel Theisen --- .github/styles/Kedro/ignore.txt | 1 + docs/catalog-data/advanced_data_catalog_usage.md | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/styles/Kedro/ignore.txt b/.github/styles/Kedro/ignore.txt index 87a12192f5..792636807c 100644 --- a/.github/styles/Kedro/ignore.txt +++ b/.github/styles/Kedro/ignore.txt @@ -49,3 +49,4 @@ Claypot ethanknights Aneira Printify +show_source diff --git a/docs/catalog-data/advanced_data_catalog_usage.md b/docs/catalog-data/advanced_data_catalog_usage.md index f3bf904a7c..6fa0e85b5e 100644 --- a/docs/catalog-data/advanced_data_catalog_usage.md +++ b/docs/catalog-data/advanced_data_catalog_usage.md @@ -11,7 +11,7 @@ This page contains a set of guides for advanced usage of the `DataCatalog` API i - [How to configure the Data Catalog](#how-to-configure-the-data-catalog) - [How to access datasets in the catalog](#how-to-access-datasets-in-the-catalog) - [How to add datasets to the catalog](#how-to-add-datasets-to-the-catalog) -- [How to iterate through datasets in the catalog](#how-to-iterate-trough-datasets-in-the-catalog) +- [How to iterate through datasets in the catalog](#how-to-iterate-through-datasets-in-the-catalog) - [How to get the number of datasets in the catalog](#how-to-get-the-number-of-datasets-in-the-catalog) - [How to print the full catalog and individual datasets](#how-to-print-the-full-catalog-and-individual-datasets) - [How to load datasets programmatically](#how-to-load-datasets-programmatically) From 664f9acc4dfa62174bb11e8ae3544a839e781db7 Mon Sep 17 00:00:00 2001 From: Merel Theisen Date: Tue, 25 Nov 2025 13:19:32 +0100 Subject: [PATCH 10/10] Ignore common tool names Signed-off-by: Merel Theisen --- .github/styles/Kedro/ignore.txt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/styles/Kedro/ignore.txt b/.github/styles/Kedro/ignore.txt index 792636807c..e17db91cc8 100644 --- a/.github/styles/Kedro/ignore.txt +++ b/.github/styles/Kedro/ignore.txt @@ -12,6 +12,10 @@ doxenix fsspec globals Globals +iPython +ipython +jupyter +Jupyter Kaggle namespace namespaces