Skip to content

deps: add missing colorlog and PyYAML to requirements.txt#414

Open
AswaniSahoo wants to merge 1 commit intokubeedge:mainfrom
AswaniSahoo:fix/add-missing-core-dependencies
Open

deps: add missing colorlog and PyYAML to requirements.txt#414
AswaniSahoo wants to merge 1 commit intokubeedge:mainfrom
AswaniSahoo:fix/add-missing-core-dependencies

Conversation

@AswaniSahoo
Copy link
Copy Markdown

What this PR does

Adds two missing runtime dependencies to requirements.txt that are imported unconditionally in core/common/ modules.

Problem

Following the install guide, a user runs pip install -r requirements.txt and then pip install -e .. Since colorlog and PyYAML are not listed in requirements.txt, the installation completes without error but any subsequent ianvs command crashes:

  • core/common/log.py line 18: import colorlogModuleNotFoundError: No module named 'colorlog'
  • core/common/utils.py line 24: import yamlModuleNotFoundError: No module named 'yaml'

Changes

requirements.txt:

  • Add colorlog (required by core/common/log.py)
  • Add PyYAML (required by core/common/utils.py)
  • Sort all entries alphabetically for consistency

Before / After

-prettytable~=2.5.0 # BSD
-scikit-learn
-numpy
-pandas
-tqdm
-matplotlib
-onnx
+colorlog
+matplotlib
+numpy
+onnx
+pandas
+prettytable~=2.5.0 # BSD
+PyYAML
+scikit-learn
+tqdm

Fixes #413

@kubeedge-bot
Copy link
Copy Markdown
Collaborator

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: AswaniSahoo
To complete the pull request process, please assign jaypume after the PR has been reviewed.
You can assign the PR to them by writing /assign @jaypume in a comment when ready.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@kubeedge-bot kubeedge-bot added the size/S Denotes a PR that changes 10-29 lines, ignoring generated files. label May 4, 2026
Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request updates the requirements.txt file by adding colorlog and PyYAML dependencies and reordering the list alphabetically. Feedback was provided regarding an inline comment on the prettytable requirement, which may cause installation failures because the project's custom requirement parser in setup.py does not handle inline comments correctly.

Comment thread requirements.txt Outdated
tqdm
matplotlib
onnx No newline at end of file
prettytable~=2.5.0 # BSD
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

The inline comment # BSD on this line will cause the setup.py script to fail during installation (e.g., when running pip install -e .). The _read_requirements function in setup.py (lines 75-78) does not strip inline comments before passing the requirement strings to setuptools, which leads to a RequirementParseError. It is recommended to remove the inline comment to ensure compatibility with the project's custom requirement parser.

prettytable~=2.5.0

Both packages are imported unconditionally in core/common/ but were absent from requirements.txt, causing ModuleNotFoundError on fresh installs. Also sorts entries alphabetically for consistency.

Signed-off-by: AswaniSahoo <aswanisahoo1012@gmail.com>
@AswaniSahoo AswaniSahoo force-pushed the fix/add-missing-core-dependencies branch from 6f6dd7b to fe96cf6 Compare May 8, 2026 01:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/S Denotes a PR that changes 10-29 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Dependencies] Add missing colorlog and PyYAML to requirements.txt

2 participants