Skip to content

refactor(models): make ActionGroup and Function setters public in Res… #923

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

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

guiarcoverde
Copy link

@guiarcoverde guiarcoverde commented Jul 10, 2025

Response model

Updated the Response class to change the access modifiers of ActionGroup and Function properties from internal set to public set to allow external modification of these values. This change improves flexibility when constructing or modifying Response instances outside the defining assembly.

Please provide the issue number

Issue number:

Summary

Changes

Updated the Response class by changing the access modifiers of the ActionGroup and Function properties from internal set to public set, enabling external code to assign values to them. This change was necessary after encountering an issue where assigning values to these properties was restricted, resulting in a Bedrock error when sending the BedrockFunctionResponse. Bedrock required both properties to be explicitly set. To work around this, I initially had to create a custom model based on the Bedrock response, but this change now allows proper usage without additional workarounds.

User experience

No workaround needed to set ActionGroup and Function.

Checklist

Please leave checklist items unchecked if they do not apply to your change.

Is this a breaking change?

RFC issue number:

Checklist:

  • Migration process documented
  • Implement warnings (if it can live side by side)

Acknowledgment

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Disclaimer: We value your time and bandwidth. As such, any pull requests created on non-triaged issues might not be successful.

…ponse model

Updated the `Response` class to change the access modifiers of `ActionGroup` and `Function` properties
from `internal set` to `public set` to allow external modification of these values. This change improves
flexibility when constructing or modifying `Response` instances outside the defining assembly.

Signed-off-by: Guilherme Arcoverde <87540453+guiarcoverde@users.noreply.github.com>
@pull-request-size pull-request-size bot added the size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. label Jul 10, 2025
Copy link

boring-cyborg bot commented Jul 10, 2025

Thanks a lot for your first contribution! Please check out our contributing guidelines and don't hesitate to ask whatever you need.
In the meantime, check out the #dotnet channel on our Powertools for AWS Lambda Discord: Invite link

Copy link

@hjgraca
Copy link
Contributor

hjgraca commented Jul 11, 2025

Hi @guiarcoverde thanks for opening the pull request. I dont see the code changes, is this still in progress? Also can I ask if you can issue to associate with this pull request. thank you!

Copy link

codecov bot commented Jul 11, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 77.28%. Comparing base (e68f39c) to head (27e1512).

Additional details and impacted files
@@           Coverage Diff            @@
##           develop     #923   +/-   ##
========================================
  Coverage    77.28%   77.28%           
========================================
  Files          272      272           
  Lines        10875    10875           
  Branches      1278     1278           
========================================
  Hits          8405     8405           
  Misses        2054     2054           
  Partials       416      416           

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement size/XS Denotes a PR that changes 0-9 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants