Skip to content

Conversation

@Dargon789
Copy link
Owner

@Dargon789 Dargon789 commented Jan 25, 2026

This configuration file sets up GitHub Actions workflows for various Python environments and jobs, including dependency installation and testing with Tox.

What was wrong?

Related to Issue #
Closes #

How was it fixed?

Todo:

  • Clean up commit history
  • Add or update documentation related to these changes
  • Add entry to the release notes

Cute Animal Picture

Put a link to a cute animal picture inside the parenthesis-->

Summary by Sourcery

Introduce a comprehensive CI workflow configuration to run tox-based test suites and builds across multiple Python versions, platforms, and Ethereum fork scenarios, including scheduled nightly runs.

Build:

  • Add workflow configuration to install dependencies, manage caching, and run tox for docs, tests, and wheel builds across Python 3.8–3.13 on Linux and Windows.
  • Configure nightly scheduled runs on the main branch to execute the full job matrix.

This configuration file sets up GitHub Actions workflows for various Python environments and jobs, including dependency installation and testing with Tox.

Signed-off-by: Dargon789 <64915515+Dargon789@users.noreply.github.com>
@gemini-code-assist
Copy link

Note

Gemini is unable to generate a summary for this pull request due to the file types involved not being currently supported.

@sourcery-ai
Copy link

sourcery-ai bot commented Jan 25, 2026

Reviewer's Guide

Adds a comprehensive CI configuration (ported from CircleCI-style config) that runs tox-based test, blockchain scenario, docs, lint, and wheel-building jobs across multiple Python versions (3.8–3.13) and platforms (Linux and Windows), with caching and nightly scheduling.

Sequence diagram for PR-triggered CI pipeline

sequenceDiagram
  actor Developer
  participant GitHub
  participant GitHub_Actions
  participant Workflow_test
  participant Linux_runner
  participant Windows_runner
  participant tox
  participant Cache

  Developer->>GitHub: Push branch / open PR
  GitHub->>GitHub_Actions: Trigger workflow test
  GitHub_Actions->>Workflow_test: Instantiate with all_jobs

  par Linux_jobs
    Workflow_test->>Linux_runner: Run docs/core/database/difficulty/lint/transactions/vm/wheel jobs
    Linux_runner->>Linux_runner: Checkout repo and submodules
    Linux_runner->>Linux_runner: Patch openssl.cnf
    Linux_runner->>Cache: Restore cache by job and checksums
    Linux_runner->>tox: Install and execute tox environments
    tox-->>Linux_runner: Test results and artifacts
    Linux_runner->>Cache: Save updated caches
  end

  par Windows_wheel_jobs
    Workflow_test->>Windows_runner: Run py311/py312/py313 windows-wheel jobs
    Windows_runner->>Windows_runner: Install pyenv-win
    Windows_runner->>Windows_runner: Install latest patch Python for minor version
    Windows_runner->>tox: Install and execute tox windows-wheel env
    tox-->>Windows_runner: Wheel build results
    Windows_runner->>Cache: Save .tox cache
  end

  Workflow_test->>GitHub_Actions: Aggregate job statuses
  GitHub_Actions->>GitHub: Report CI status on PR
  GitHub-->>Developer: Display checks and logs
Loading

Flow diagram for common Linux CI job steps

flowchart TD
  A["Start job (common template)"] --> B["Checkout repository"]
  B --> C["Check openssl version"]
  C --> D["Patch openssl.cnf to enable legacy provider"]
  D --> E["Update git submodules"]
  E --> F["Merge PR base (attempt 1)"]
  F --> G{Merge succeeded?}
  G --> H["Continue"]
  G --> I["Merge PR base (attempt 2)"]
  I --> J{Merge succeeded?}
  J --> H
  J --> K["Merge PR base (attempt 3)"]
  K --> L{Merge succeeded?}
  L --> H
  H --> M["Restore cache by job and checksums"]
  M --> N["Upgrade pip and install tox"]
  N --> O["Run tox: python -m tox run -r"]
  O --> P["Save cache (.hypothesis, .tox, pip, local)"]
  P --> Q["Job complete"]
Loading

File-Level Changes

Change Details Files
Introduce shared Linux test job template that runs tox with caching and OpenSSL tweaks across multiple Python images.
  • Define a reusable common job anchor that checks out the repo, adjusts OpenSSL configuration for ripemd160, updates git submodules, repeatedly attempts PR base merge via existing CircleCI script, restores and saves caches, installs tox, and runs the configured tox environment.
  • Configure multiple Linux jobs for docs, core, database, difficulty, lint, transactions, vm, wheel, and various native blockchain scenarios by reusing the common anchor with different cimg/python images and TOXENV values.
.github/workflows/config.yml
Add a specialized documentation build job that installs LaTeX toolchain and stores built docs as artifacts.
  • Create a docs anchor that installs tox, LaTeX-related system packages, runs tox for docs, and uploads the Sphinx build directory as CI artifacts.
  • Instantiate a docs job using the docs anchor with Python 3.10 and TOXENV=docs.
.github/workflows/config.yml
Define Windows wheel-building jobs using pyenv-win to install latest patch versions of Python and run tox.
  • Introduce a windows wheel setup anchor with a Windows executor, working directory, and TOXENV configuration plus shared cache logic.
  • Add steps to install pyenv-win, resolve and install the latest 3.11/3.12/3.13 patch versions, install tox, run tox for windows-wheel, and cache .tox results for each Windows job.
.github/workflows/config.yml
Configure workflows to run the full job matrix on pushes and on a scheduled weekday nightly build.
  • Define an all_jobs anchor listing all defined jobs across versions and platforms.
  • Create a test workflow that runs all jobs on the default trigger and a nightly workflow that triggers on a weekday cron schedule for main, reusing the all_jobs job list.
.github/workflows/config.yml

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

Copy link

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

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

Hey - I've left some high level feedback:

  • The file is placed under .github/workflows/config.yml but is written in CircleCI 2.1 syntax (e.g. version: 2.1, orbs:, workflows: with Circle-specific keys), so GitHub Actions will ignore it; you’ll need to convert this to valid GitHub Actions YAML (on:, jobs:, runs-on, etc.) for it to actually run.
  • A lot of the configuration (per-Python-version jobs, repeated TOXENV-based jobs, cache keys) is highly repetitive; consider using a GitHub Actions matrix strategy and shared composite actions or reusable workflows instead of expanding every combination manually.
Prompt for AI Agents
Please address the comments from this code review:

## Overall Comments
- The file is placed under `.github/workflows/config.yml` but is written in CircleCI 2.1 syntax (e.g. `version: 2.1`, `orbs:`, `workflows:` with Circle-specific keys), so GitHub Actions will ignore it; you’ll need to convert this to valid GitHub Actions YAML (`on:`, `jobs:`, `runs-on`, etc.) for it to actually run.
- A lot of the configuration (per-Python-version jobs, repeated `TOXENV`-based jobs, cache keys) is highly repetitive; consider using a GitHub Actions matrix strategy and shared composite actions or reusable workflows instead of expanding every combination manually.

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@Dargon789 Dargon789 merged commit 70b51ba into main Jan 25, 2026
4 of 7 checks passed
@Dargon789 Dargon789 deleted the Dargon789-patch-2 branch January 25, 2026 08:10
@Dargon789 Dargon789 linked an issue Jan 25, 2026 that may be closed by this pull request
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.

# Sequence diagram for PR-triggered CI pipeline

2 participants