question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[print_settings] Hide secret field values by default

See original GitHub issue

User story: I am a well-intentioned sysadmin. I want to print and share Django settings with my colleague, so that I can investigate a problem without revealing secret values.

Proposed solution:

  1. Define the following “sensitive” patterns: SECRET, PASSWORD

  2. All settings matching these patterns show a value of **********

  3. If the user passes the parameter --show-secrets, then show the actual values.

Issue Analytics

  • State:open
  • Created 3 years ago
  • Reactions:1
  • Comments:8 (6 by maintainers)

github_iconTop GitHub Comments

2reactions
pdewachtcommented, May 9, 2020

FYI, Django already has a get_safe_settings function which applies the filtering.

1reaction
trbscommented, May 7, 2020

Very good idea !

We should also allow users to override the sensitive patterns in settings.py so people can add their own as needed.

Could you make a PR for this ? Happy to merge it !

Read more comments on GitHub >

github_iconTop Results From Across the Web

Keep default values of conditionally hidden fields - Jotform
I want the fields that will be hidden due to the conditional logic from the multiple-choice answer to populate with a default "N/A"...
Read more >
Printing and Managing Print Settings | Revit 2021
How to print and control print settings. ... Leave this set to default tray. ... In the Hidden Line Views area, you can...
Read more >
Hidden Field Codes - Atlas Systems
The field codes hide the Word Fields that allow the system to change the label based on the information in the record. For...
Read more >
Solved: Hidden fields changes default field to blank
Solved: Hi, I've got a power apps form that I want to hide 2 fields when the form loads. It's based on a...
Read more >
Settings management - pydantic
Variables loaded from a dotenv ( .env ) file. Variables loaded from the secrets directory. The default field values for the Settings model....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found