fix: register LAST30DAYS_DEBUG in env keys, lazy resolution, fix xai_x crash#770
Open
23241a6749 wants to merge 1 commit into
Open
fix: register LAST30DAYS_DEBUG in env keys, lazy resolution, fix xai_x crash#77023241a6749 wants to merge 1 commit into
23241a6749 wants to merge 1 commit into
Conversation
Contributor
Greptile SummaryThis PR fixes debug-mode configuration and the xAI error logging path. The main changes are:
Confidence Score: 5/5This looks safe to merge.
Important Files Changed
Reviews (2): Last reviewed commit: "fix: register LAST30DAYS_DEBUG in env ke..." | Re-trigger Greptile |
…x crash LAST30DAYS_DEBUG had three bugs: 1. Not registered in CONFIGURATION_KEYS - .env values were silently ignored 2. Eager module-level os.environ.get() in log.py meant --debug flag and .env values were never picked up by log.debug() 3. http.DEBUG in xai_x.py referenced a non-existent attribute, causing AttributeError on xAI API errors Fixes: - Add LAST30DAYS_DEBUG to the CONFIGURATION_KEYS tuple in env.py - Export to os.environ after get_config() so log.py's lazy check picks up .env values - Replace eager DEBUG constant with lazy is_debug() function - Fix http.DEBUG -> log.is_debug() in xai_x.py - Add CONFIGURATION.md section for --debug / LAST30DAYS_DEBUG
4cc9c40 to
8649ee5
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
LAST30DAYS_DEBUGhad three bugs: