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

Update utils.py to handle SecretStr field type as str with password and load_from_db attributes #2005

Merged
merged 3 commits into from
May 30, 2024

Conversation

ogabrielluiz
Copy link
Contributor

@ogabrielluiz ogabrielluiz commented May 29, 2024

This pull request updates the utils.py file to handle the SecretStr field type as a string with the password and load_from_db attributes. This ensures that the SecretStr field type is properly handled and allows for more secure and efficient handling of sensitive information.

I'm proposing we use SecretStr as a replacement for passing password and load_from_db in the build_config. We'd also instantiate a SecretStr as soon as we got the Global Variable value from the database and pass it to the CustomComponent.

This means that all credential fields would be passed in as SecretStr and not as str anymore.

Copy link

vercel bot commented May 29, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
langflow ✅ Ready (Inspect) Visit Preview 💬 Add feedback May 30, 2024 3:53pm

@dosubot dosubot bot added size:XS This PR changes 0-9 lines, ignoring generated files. python Pull requests that update Python code labels May 29, 2024
@ogabrielluiz ogabrielluiz marked this pull request as draft May 29, 2024 01:55
@ogabrielluiz ogabrielluiz marked this pull request as ready for review May 30, 2024 15:52
@dosubot dosubot bot added size:S This PR changes 10-29 lines, ignoring generated files. and removed size:XS This PR changes 0-9 lines, ignoring generated files. labels May 30, 2024
@ogabrielluiz ogabrielluiz merged commit eb68558 into dev May 30, 2024
12 of 16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
python Pull requests that update Python code size:S This PR changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant