Skip to content

fix: pin pygments<2.20.0 to avoid pymdownx highlight crash#61

Merged
MuhammedSenn merged 1 commit into
mainfrom
fix/pin-pygments-below-2.20.0
May 14, 2026
Merged

fix: pin pygments<2.20.0 to avoid pymdownx highlight crash#61
MuhammedSenn merged 1 commit into
mainfrom
fix/pin-pygments-below-2.20.0

Conversation

@baranylcn
Copy link
Copy Markdown
Member

@baranylcn baranylcn commented May 14, 2026

Summary by CodeRabbit

  • Chores
    • Updated build system dependency version constraints to enhance development environment stability and toolchain compatibility, ensuring consistent builds across development workflows without impacting user-facing functionality.

Review Change Stack

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 14, 2026

Walkthrough

This PR adds Pygments as a development dependency with version constraints to the project's configuration, pinning it between versions 2.18.0 and 2.20.0.

Changes

Development Dependency Update

Layer / File(s) Summary
Pygments dev dependency constraint
pyproject.toml
Pygments is added to the development dependency group with version constraint >=2.18.0,<2.20.0.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

Poem

🐰 A syntax highlighter hops into view,
Pygments shines bright, version two-point-two,
Dev tools grow richer with colors so true,
Building a brighter LevelUp through and through! ✨

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main change: pinning pygments to avoid a crash in pymdownx highlight, which matches the single-line addition to pyproject.toml.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/pin-pygments-below-2.20.0

Tip

💬 Introducing Slack Agent: The best way for teams to turn conversations into code.

Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.

  • Generate code and open pull requests
  • Plan features and break down work
  • Investigate incidents and troubleshoot customer tickets together
  • Automate recurring tasks and respond to alerts with triggers
  • Summarize progress and report instantly

Built for teams:

  • Shared memory across your entire org—no repeating context
  • Per-thread sandboxes to safely plan and execute work
  • Governance built-in—scoped access, auditability, and budget controls

One agent for your entire SDLC. Right inside Slack.

👉 Get started


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

🧹 Nitpick comments (1)
pyproject.toml (1)

42-42: ⚡ Quick win

Add documentation explaining the Pygments version constraint.

The version pinning is appropriate—Pygments 2.20.0 introduced a change that breaks pymdownx.highlight, causing AttributeError crashes with code blocks. Pinning <2.20.0 is the correct approach. Consider adding a comment above line 42 to document this constraint for future maintainers, either directly in pyproject.toml or in a related issue reference.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@pyproject.toml` at line 42, Add a short comment near the
"pygments>=2.18.0,<2.20.0" dependency in pyproject.toml documenting why the
upper bound is set: note that Pygments 2.20.0 introduced changes that break
pymdownx.highlight (causing AttributeError with code blocks) and reference
either the related issue/PR or its tracker URL for future follow-up; ensure the
comment mentions "pygments" and "pymdownx.highlight" so maintainers can find
context quickly.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Nitpick comments:
In `@pyproject.toml`:
- Line 42: Add a short comment near the "pygments>=2.18.0,<2.20.0" dependency in
pyproject.toml documenting why the upper bound is set: note that Pygments 2.20.0
introduced changes that break pymdownx.highlight (causing AttributeError with
code blocks) and reference either the related issue/PR or its tracker URL for
future follow-up; ensure the comment mentions "pygments" and
"pymdownx.highlight" so maintainers can find context quickly.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 80a318c2-66fd-46fd-8c39-f3a97a7c9088

📥 Commits

Reviewing files that changed from the base of the PR and between 7dc7d43 and 4a6ed84.

⛔ Files ignored due to path filters (1)
  • uv.lock is excluded by !**/*.lock
📒 Files selected for processing (1)
  • pyproject.toml

@baranylcn baranylcn requested a review from MuhammedSenn May 14, 2026 19:04
@MuhammedSenn MuhammedSenn merged commit d73ff92 into main May 14, 2026
6 checks passed
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