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

telemetry(amazonq): invalid zip event #5265

Merged
merged 4 commits into from
Jan 15, 2025
Merged

Conversation

ctlai95
Copy link
Contributor

@ctlai95 ctlai95 commented Jan 15, 2025

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)

Description

Service is receiving invalid zip files which are created with invalid entry path. This change adds a telemetry metric to capture more data when this happens.

Checklist

  • My code follows the code style of this project
  • I have added tests to cover my changes
  • A short description of the change has been added to the CHANGELOG if the change is customer-facing in the IDE.
  • I have added metrics for my changes (if required)

License

I confirm that my contribution is made under the terms of the Apache 2.0 license.

@ctlai95 ctlai95 marked this pull request as ready for review January 15, 2025 17:59
@ctlai95 ctlai95 requested review from a team as code owners January 15, 2025 17:59
@@ -177,6 +177,21 @@
"reloaded"
],
"description": "Toolkit run state."
},
Copy link
Contributor

Choose a reason for hiding this comment

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

can this be added to common?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I can follow up with a separate PR after this

@@ -195,6 +196,9 @@ class CodeScanSessionConfig(
files.forEach { file ->
try {
val relativePath = "${project.name}/${file.relativeTo(projectRoot.toNioPath())}"
if (relativePath.contains("../") || relativePath.contains("..\\")) {
Copy link
Contributor

Choose a reason for hiding this comment

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

test?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

will follow up

@ctlai95 ctlai95 merged commit 809538a into aws:main Jan 15, 2025
9 checks passed
karanA-aws pushed a commit to karanA-aws/aws-toolkit-jetbrains that referenced this pull request Jan 17, 2025
* telemetry(amazonq): invalid zip event

* check windows path
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.

4 participants