Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🔼 feat: "Run Code" Button Toggle #5988

Merged
merged 8 commits into from
Feb 23, 2025
Merged

🔼 feat: "Run Code" Button Toggle #5988

merged 8 commits into from
Feb 23, 2025

Conversation

danny-avila
Copy link
Owner

@danny-avila danny-avila commented Feb 23, 2025

Summary

  • Convert REDIS_MAX_LISTENERS to a number to ensure proper configuration
  • Integrate permission checks in the tool controller and Markdown code block so that code execution capability is enabled only if the user has access.
  • Refactor permission middleware by extracting and improving the checkAccess function with enhanced logging and better error reporting.
  • Update the role schema to add Temporary Chat and Run Code permissions with correct default values.
  • Define the NextFunction typedef in the API for improved type clarity.
  • Augment interface tests to cover the new permission features and validate configuration settings.

Documentation: LibreChat-AI/librechat.ai#244

Change Type

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)

Testing

  • I ran local unit tests and verified that the Redis listener fix applies correctly.
  • I performed manual tests by executing tool calls and checking that permission validations in both the tools controller and Markdown component behave as expected.
  • I simulated API calls to ensure proper 403 responses when a user lacks the required permissions.
  • I confirmed that updated role defaults are correctly applied in the interface specifications.

Checklist

  • My code adheres to this project's style guidelines
  • I have performed a self-review of my own code
  • I have commented in any complex areas of my code
  • I have made pertinent documentation changes
  • My changes do not introduce new warnings
  • I have written tests demonstrating that my changes are effective or that my feature works
  • Local unit tests pass with my changes
  • Any changes dependent on mine have been merged and published in downstream modules

@danny-avila danny-avila merged commit 0e71959 into main Feb 23, 2025
7 checks passed
@danny-avila danny-avila deleted the feat/run-code-toggle branch February 23, 2025 19:01
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.

[Bug]: REDIS_MAX_LISTENERS does not work - argument must be of type number. Received type string
1 participant