alibaba / alibaba/ChatLearn

[BUG] env var ENABLE_VLLM is not natively a bool

Open
#261 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
450
Forks
40
PR merge metrics
No merged PRs in 30d

Description

**Describe the bug**
env variables are string types and cant be typed as bool.

```python
if os.getenv("ENABLE_VLLM", False):
something
```
os.environ["ENABLE_VLLM"] needs to be casted first from str to bool before applying if

**To Reproduce**
```bash
export ENABLE_VLLM=False
```
```python
if os.getenv("ENABLE_VLLM", False):
print('hi')
```
will print hi whereas it shouldnt.

Contributor guide

No contributing guide indexed for this repository

Research direction

Search the codebase for ENABLE_VLLM references and inspect how its environment value is read. Reproduce the issue with ENABLE_VLLM=False, then verify that the resulting condition does not print “hi” while a true value still enables the behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
machine-learning
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.