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: sanitize Piccolo columns with secret=True from PydanticDTO output #3030

Merged

Conversation

patrickneise
Copy link
Contributor

Pull Request Checklist

  • New code has 100% test coverage
  • (If applicable) The prose documentation has been updated to reflect the changes introduced by this PR
  • (If applicable) The reference documentation has been updated to reflect the changes introduced by this PR
  • Pre-Commit Checks were ran and passed
  • Tests were ran and passed

Description

For Picollo columns with secret=True set, mark those columns as WRITE_ONLY to prevent the column being included in return_dto.

Close Issue(s)

Closes #2976

@patrickneise patrickneise requested review from a team as code owners January 26, 2024 15:04
@patrickneise patrickneise changed the title Enhancement: sanitize Piccolo columns with secret=True from PydanticDTO output feat: sanitize Piccolo columns with secret=True from PydanticDTO output Jan 26, 2024
Copy link
Member

@provinzkraut provinzkraut left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, thanks @patrickneise!

Copy link

codecov bot commented Jan 26, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (b16a984) 98.26% compared to head (27f8fef) 98.26%.

❗ Current head 27f8fef differs from pull request most recent head c317ec4. Consider uploading reports for the commit c317ec4 to get more accurate results

Additional details and impacted files
@@           Coverage Diff            @@
##           develop    #3030   +/-   ##
========================================
  Coverage    98.26%   98.26%           
========================================
  Files          317      317           
  Lines        14273    14274    +1     
  Branches      2458     2458           
========================================
+ Hits         14025    14026    +1     
  Misses         107      107           
  Partials       141      141           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@provinzkraut provinzkraut merged commit d3b8bf2 into litestar-org:develop Jan 26, 2024
14 checks passed
@provinzkraut
Copy link
Member

@all-contributors add @patrickneise for code

Copy link
Contributor

@provinzkraut

I've put up a pull request to add @patrickneise! 🎉

Copy link

Documentation preview will be available shortly at https://litestar-org.github.io/litestar-docs-preview/3030

provinzkraut pushed a commit that referenced this pull request Jan 26, 2024
…ut (#3030)

* feature(piccolo): sanitize columns with  from PydanticDTO output
* feature(piccolo): modify logic to assign  to secret columns

---------

Co-authored-by: Patrick Neise <neise.patrick@solute.us>
provinzkraut pushed a commit that referenced this pull request Jan 27, 2024
…ut (#3030)

* feature(piccolo): sanitize columns with  from PydanticDTO output
* feature(piccolo): modify logic to assign  to secret columns

---------

Co-authored-by: Patrick Neise <neise.patrick@solute.us>
provinzkraut pushed a commit that referenced this pull request Feb 3, 2024
…ut (#3030)

* feature(piccolo): sanitize columns with  from PydanticDTO output
* feature(piccolo): modify logic to assign  to secret columns

---------

Co-authored-by: Patrick Neise <neise.patrick@solute.us>
provinzkraut pushed a commit that referenced this pull request Feb 3, 2024
…ut (#3030)

* feature(piccolo): sanitize columns with  from PydanticDTO output
* feature(piccolo): modify logic to assign  to secret columns

---------

Co-authored-by: Patrick Neise <neise.patrick@solute.us>
provinzkraut pushed a commit that referenced this pull request Feb 4, 2024
…ut (#3030)

* feature(piccolo): sanitize columns with  from PydanticDTO output
* feature(piccolo): modify logic to assign  to secret columns

---------

Co-authored-by: Patrick Neise <neise.patrick@solute.us>
provinzkraut pushed a commit that referenced this pull request Feb 6, 2024
…ut (#3030)

* feature(piccolo): sanitize columns with  from PydanticDTO output
* feature(piccolo): modify logic to assign  to secret columns

---------

Co-authored-by: Patrick Neise <neise.patrick@solute.us>
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.

Enhancement: sanitize Piccolo columns with secret=True from PydanticDTO output
2 participants