Skip to content

fix(plugin-meetings): improved logging#5011

Open
marcin-bazyl wants to merge 1 commit into
webex:nextfrom
marcin-bazyl:improved-logging
Open

fix(plugin-meetings): improved logging#5011
marcin-bazyl wants to merge 1 commit into
webex:nextfrom
marcin-bazyl:improved-logging

Conversation

@marcin-bazyl
Copy link
Copy Markdown
Collaborator

@marcin-bazyl marcin-bazyl commented May 29, 2026

This pull request addresses

When some network request fails and the error is not caught anywhere, we have a log that shows the status code but not the body. The body usually contains more specific backend error message and error code, very useful for debugging

by making the following changes

Modified log to show also the response body. Error responses should always be quite short and small, so I think it should be fine to just log the whole response.

Also improved some logs in LocusInfo based on recent experience when debugging various issues.

Change Type

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation update
  • Tooling change
  • Internal code refactor

The following scenarios were tested

unit tests

The GAI Coding Policy And Copyright Annotation Best Practices

  • GAI was not used (or, no additional notation is required)
  • Code was generated entirely by GAI
  • GAI was used to create a draft that was subsequently customized or modified
  • Coder created a draft manually that was non-substantively modified by GAI (e.g., refactoring was performed by GAI on manually written code)
  • Tool used for AI assistance (GitHub Copilot / Other - specify)
    • Github Copilot
    • Other - Please Specify
  • This PR is related to
    • Feature
    • Defect fix
    • Tech Debt
    • Automation

I certified that

  • I have read and followed contributing guidelines

  • I discussed changes with code owners prior to submitting this pull request

  • I have not skipped any automated checks

  • All existing and new tests passed

  • I have updated the documentation accordingly


Make sure to have followed the contributing guidelines before submitting.

@marcin-bazyl marcin-bazyl requested review from a team as code owners May 29, 2026 12:41
@marcin-bazyl marcin-bazyl added the validated If the pull request is validated for automation. label May 29, 2026
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 80bcc08b45

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment on lines 64 to 68
options.logger.warn(
`http ${options.method ? options.method : 'request'} to ${options.uri} result: ${
response.statusCode
}`
} body: ${JSON.stringify(response.body)}`
);
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Gate response bodies behind verbose logging

In browser builds, every 4xx/5xx response now writes the full response body at warn level, even when ENABLE_VERBOSE_NETWORK_LOGGING is disabled. For requests to auth or other endpoints whose error payloads can include user-provided content or sensitive details, this bypasses the existing response logger's verbose-only behavior and can persist those payloads in the configured SDK logs; please keep body logging behind the verbose flag or redact/limit it before logging.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

i tend to agree with codex here ^

@aws-amplify-us-east-2
Copy link
Copy Markdown

This pull request is automatically being deployed by Amplify Hosting (learn more).

Access this pull request here: https://pr-5011.d3m3l2kee0btzx.amplifyapp.com

Copy link
Copy Markdown
Collaborator

@chrisadubois chrisadubois left a comment

Choose a reason for hiding this comment

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

  1. running JSON.stringify could throw
  2. I kind of agree with codex re: auth logs. I don't think it needs to be behind verbose, but i think we want to be careful about logging PII

Comment on lines 64 to 68
options.logger.warn(
`http ${options.method ? options.method : 'request'} to ${options.uri} result: ${
response.statusCode
}`
} body: ${JSON.stringify(response.body)}`
);
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

i tend to agree with codex here ^

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

validated If the pull request is validated for automation.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants