cyclic
Handle cyclic relations
What it is and what it does
Cyclic is a lightweight library for detecting cycles in directed graphs where relationships are compared by value. It provides a simple API to add edges between nodes and check whether a given node participates in any cyclic relationship. The package has no external dependencies, making it trivial to install.
The library is designed for scenarios where you need to track parent-child or dependency relationships and verify that no circular chains exist. It stores relationships and can query whether adding a new edge would create a cycle. However, the package has been unmaintained since 2018 with no updates or bug fixes in over five years, so it should be considered stable but not actively developed.
Use it for:
- Validate that a new dependency relationship won't introduce a circular dependency in a package or module system.
- Check for cycles in organizational hierarchies or permission delegation chains before committing a relationship.
- Detect circular imports or module dependencies during static analysis of Python codebases.
- Verify acyclic constraints in workflow or task scheduling systems before execution.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Detects and reports cyclic relationships in a directed graph by checking whether adding a new edge would create a cycle.
Yes, if you need basic cycle detection in a small, self-contained graph and can tolerate no ongoing maintenance. The zero-dependency design and permissive license make it safe to embed. No, if you need active support, performance at scale, or assurance that edge cases are handled—consider a more actively maintained graph library instead.
Install
cyclic on PyPI
pip
pip install cyclicuv
uv add cyclicpoetry
poetry add cyclicInstalling cyclic
Before you install
Installation is frictionless with no runtime dependencies, but the package has been abandoned since its single release on 2018-09-26 with no commits after 2020-05-27, so expect no maintenance or bug fixes.
License in practice
BSD license is permissive, allowing commercial and private use with minimal restrictions—suitable for most projects.
Quickstart
pip install cyclic
from cyclic import Cyclic
cy = Cyclic()
cy.add('B', 'A')
cy.add('C', 'B')
cy.add('A', 'C')
print(cy.is_cyclic('C')) # True
Verify before relying
- Whether the package correctly handles all edge cases in cycle detection (e.g., self-loops, disconnected components).
- Performance characteristics with large graphs or high-frequency cycle checks.
- Compatibility with modern Python versions beyond the unspecified support claim.
Package facts
| License | BSD (permissive) |
| Python support | not specified |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | none |
| Maintenance | abandoned — 2,879 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 127,696/month — #11,734 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: cyclic-1.0.0-py3-none-any.whl
Keywords: cyclic, relation, circular, dependency
Tags
More Software Development packages
Provides backported and experimental type hints…
permissive · top 100 on PyPI
numpyNumPy provides an N-dimensional array object…
permissive · top 100 on PyPI
fastapiFastAPI is a Python web framework for building…
permissive · top 100 on PyPI
annotated-docProvides a way to document function parameters,…
permissive · top 100 on PyPI
typerTyper builds command-line applications from…
permissive · top 1,000 on PyPI
distlibDistlib provides low-level packaging utilities…
permissive · top 1,000 on PyPI
py-import-cyclesDetects import cycles in Python projects by…
permissive · top 15,000 on PyPI
mo-importsProvides patterns to resolve circular module…
copyleft · top 15,000 on PyPI
toposortImplements topological sorting of directed…
permissive · top 5,000 on PyPI
pipdeptreepipdeptree displays installed Python packages…
permissive · top 5,000 on PyPI
tachTach enforces module boundaries, dependency…
permissive · top 5,000 on PyPI
importlabImportlab infers Python import dependencies and…
permissive · top 5,000 on PyPI
pydepsVisualizes Python module dependencies as graphs…
permissive · top 15,000 on PyPI
cyclerCycler provides composable style cycles for…
permissive · top 1,000 on PyPI
import-depsAnalyzes Python module imports statically using…
permissive · top 5,000 on PyPI
rainflowRainflow implements the ASTM E1049-85 rainflow…
permissive · top 15,000 on PyPI