Skip to content

feat: add Elastic ECK Operator compatibility scraper - #4155

Open
MiTM-1 wants to merge 17 commits into
pluralsh:masterfrom
MiTM-1:feat/eck-operator-compatibility
Open

feat: add Elastic ECK Operator compatibility scraper#4155
MiTM-1 wants to merge 17 commits into
pluralsh:masterfrom
MiTM-1:feat/eck-operator-compatibility

Conversation

@MiTM-1

@MiTM-1 MiTM-1 commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

Adds Elastic Cloud on Kubernetes (ECK) Operator to Plural’s compatibility catalog with an automated compatibility scraper, generated compatibility data, manifest registration and focused regression tests.

Authoritative sources

The scraper reads the officially documented Kubernetes support range from tagged ECK releases, verifies release metadata against Elastic’s published ECK versions, and emits conservative Kubernetes compatibility rows for supported ECK 3.x releases.

Testing

  • 10 focused tests passed
  • Python compilation passed
  • compatibility YAML validation passed
  • official tagged release compatibility data verified
  • official Helm chart metadata verified
  • malformed or structurally changed upstream data fails closed

No live Kubernetes cluster deployment was performed; this change verifies compatibility metadata and source parsing.

AI assistance disclosure: implemented and tested using OpenAI ChatGPT/Codex under the GitHub account owner’s authorization.

I would like this submission considered under the README Contributor Program’s advertised $300 reward for a new compatibility scraper, subject to maintainer review, merge and eligibility confirmation.

Plural Flow: console

@MiTM-1 MiTM-1 changed the title Feat/eck operator compatibility feat: add Elastic ECK Operator compatibility scraper Sep 8, 2026
@soffi-ai

soffi-ai Bot commented Sep 8, 2026

Copy link
Copy Markdown
Soffi AI Summary

This PR adds Elastic Cloud on Kubernetes (ECK) operator compatibility tracking to the Plural Console's static compatibility matrix. The motivation is to allow the platform to surface Kubernetes version compatibility information for the ECK operator, consistent with how other add-ons are tracked.

The work involves four coordinated pieces: a new Python scraper that fetches ECK Helm chart versions and parses the supported Kubernetes range from tagged release READMEs on GitHub, a comprehensive unit test suite validating the scraper's parsing and error-handling logic, the initial static compatibility data file generated by the scraper, and registration of the ECK operator in the compatibility manifest so the server picks it up.

The scraper follows the established pattern in utils/compatibility/scrapers/ — it resolves the latest patch release per minor ECK version (filtering out pre-releases and versions below major 3), fetches the README for each tagged release, extracts the Kubernetes 1.X–1.Y range via regex, and writes a static/compatibilities/eck-operator.yaml file via the shared update_compatibility_info helper.

Changes

ECK operator compatibility tracking

  • Adds a Python scraper (utils/compatibility/scrapers/eck-operator.py) that fetches ECK Helm chart versions, filters to the latest patch per minor release (major ≥ 3, non-pre-release), retrieves each tagged README from GitHub, and parses the supported Kubernetes version range to produce a structured compatibility row. (334032b)
  • Adds a full unit test suite for the ECK scraper covering Kubernetes range parsing (including whitespace tolerance, reversed ranges, and missing ranges), chart version filtering, row-building with mocked HTTP fetches (including missing and non-UTF-8 payloads), and the end-to-end scrape() wiring. (f05204c)
  • Adds the initial generated static/compatibilities/eck-operator.yaml file with icon, repo URLs, Helm repository reference, and version entries produced by the new scraper. (8f2a537)
  • Registers the ECK operator in static/compatibilities/manifest.yaml so the Elixir server loads and exposes its compatibility data alongside other tracked add-ons. (f31c27f)

Updated: 2026-09-08 11:15 UTC

Deploy in Soffi

@greptile-apps

greptile-apps Bot commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

This PR adds ECK operator compatibility support, including static release metadata, manifest registration, an upstream README-based scraper, and focused parser/scraper tests.

  • Selects the latest stable ECK patch from each supported minor release.
  • Extracts Kubernetes support ranges from tagged ECK READMEs.
  • Adds ECK to the per-addon compatibility manifest.
  • The published aggregate compatibility matrix still needs regeneration before merge.

Confidence Score: 4/5

The PR should not merge until the published aggregate compatibility matrix includes ECK; the test isolation issue is also worth correcting.

The new per-addon data and scraper are structurally sound, but the synchronization workflow will publish an aggregate file that omits the newly registered operator, leaving remote compatibility consumers without the feature.

Files Needing Attention: static/compatibilities/manifest.yaml, static/compatibilities.yaml, utils/compatibility/tests/test_eck_operator.py

Important Files Changed

Filename Overview
static/compatibilities/eck-operator.yaml Adds schema-compatible ECK release, chart, and Kubernetes support metadata.
static/compatibilities/manifest.yaml Registers ECK in the per-addon manifest without updating the aggregate matrix published to remote consumers.
utils/compatibility/scrapers/eck-operator.py Adds a defensive scraper that selects stable releases and parses tagged README support ranges.
utils/compatibility/tests/test_eck_operator.py Covers parsing, filtering, payload failures, and updater wiring, but leaks a synthetic utils module into global interpreter state.

Reviews (1): Last reviewed commit: "manifest: register ECK operator" | Re-trigger Greptile

- wiz-sensor
- wiz-admission-controller
- wiz-network-analyzer
- eck-operator

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.

P1 Aggregate Matrix Omits ECK

This registers eck-operator only in the per-addon manifest. Merging this change triggers the S3 synchronization workflow, which uploads the existing static/compatibilities.yaml without an ECK entry, while remote compatibility consumers load that aggregate file. As a result, those consumers cannot discover the new operator until a later updater run regenerates the aggregate matrix. Please regenerate and include static/compatibilities.yaml in this PR.

Comment on lines +8 to +12
helpers = ModuleType("utils")
helpers.fetch_page = Mock()
helpers.get_chart_versions = Mock()
helpers.update_compatibility_info = Mock()
sys.modules["utils"] = helpers

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.

P2 Test Leaks Mock Module

This test replaces the process-wide sys.modules["utils"] entry with a synthetic module and never restores the original value. Any compatibility tests imported later in the same discovery process will receive these mocks instead of the real utility module, making the suite order-dependent as it grows. Isolate the replacement with patch.dict or restore it during cleanup.

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