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

chore: move some functions to a new appsec/_capabilities.py file to avoid cyclic imports #6700

Merged
merged 9 commits into from
Aug 21, 2023

Conversation

juanjux
Copy link
Collaborator

@juanjux juanjux commented Aug 21, 2023

Fixes a potencial cyclic import when importing appsec.utils._appsec_rc_capabilities.

Checklist

  • Change(s) are motivated and described in the PR description.
  • Testing strategy is described if automated tests are not included in the PR.
  • Risk is outlined (performance impact, potential for breakage, maintainability, etc).
  • Change is maintainable (easy to change, telemetry, documentation).
  • Library release note guidelines are followed. If no release note is required, add label changelog/no-changelog.
  • Documentation is included (in-code, generated user docs, public corp docs).
  • Backport labels are set (if applicable)

Reviewer Checklist

  • Title is accurate.
  • No unnecessary changes are introduced.
  • Description motivates each change.
  • Avoids breaking API changes unless absolutely necessary.
  • Testing strategy adequately addresses listed risk(s).
  • Change is maintainable (easy to change, telemetry, documentation).
  • Release note makes sense to a user of the library.
  • Reviewer has explicitly acknowledged and discussed the performance implications of this PR as reported in the benchmarks PR comment.
  • Backport labels are set in a manner that is consistent with the release branch maintenance policy

@juanjux juanjux added changelog/no-changelog A changelog entry is not required for this PR. ASM Application Security Monitoring labels Aug 21, 2023
@juanjux juanjux self-assigned this Aug 21, 2023
@juanjux juanjux requested a review from a team as a code owner August 21, 2023 09:11
Signed-off-by: Juanjo Alvarez <[email protected]>
…ic-import

# Conflicts:
#	ddtrace/appsec/utils.py
Signed-off-by: Juanjo Alvarez <[email protected]>
@juanjux juanjux changed the title Move some functions to a new appsec/_capabilities.py file to avoid cyclic imports chore: move some functions to a new appsec/_capabilities.py file to avoid cyclic imports Aug 21, 2023
avara1986
avara1986 previously approved these changes Aug 21, 2023
Signed-off-by: Juanjo Alvarez <[email protected]>
@juanjux juanjux force-pushed the juanjux/fix-utils-cyclic-import branch from 6db9562 to cac41a8 Compare August 21, 2023 09:48
avara1986
avara1986 previously approved these changes Aug 21, 2023
@pr-commenter
Copy link

pr-commenter bot commented Aug 21, 2023

Benchmarks

Benchmark execution time: 2023-08-21 12:48:16

Comparing candidate commit 27e01d9 in PR branch juanjux/fix-utils-cyclic-import with baseline commit 8973f5f in branch 1.x.

Found 1 performance improvements and 0 performance regressions! Performance is the same for 93 metrics, 0 unstable metrics.

scenario:flasksimple-appsec-telemetry

  • 🟩 max_rss_usage [-1033.060KB; -883.459KB] or [-3.027%; -2.588%]

Signed-off-by: Juanjo Alvarez <[email protected]>
Signed-off-by: Juanjo Alvarez <[email protected]>
Signed-off-by: Juanjo Alvarez <[email protected]>
@juanjux juanjux enabled auto-merge (squash) August 21, 2023 11:40
@juanjux juanjux merged commit 732ccb5 into 1.x Aug 21, 2023
@juanjux juanjux deleted the juanjux/fix-utils-cyclic-import branch August 21, 2023 13:59
@github-actions github-actions bot added this to the v1.19.0 milestone Aug 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ASM Application Security Monitoring changelog/no-changelog A changelog entry is not required for this PR.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants