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

Fix timeout logs #429

Merged
merged 3 commits into from
Sep 12, 2024
Merged

Fix timeout logs #429

merged 3 commits into from
Sep 12, 2024

Conversation

marcospassos
Copy link
Member

@marcospassos marcospassos commented Sep 12, 2024

Summary

Prevent logging a timeout when the request completes in time.

In addition to clearing the timeout for the evaluation request, I have also moved the logic to immediately follow the completion of the request. This ensures that the timeout only applies to the request logic and not to subsequent actions such as deserialization and logging.

Checklist

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • Any dependent changes have been merged and published in downstream modules
  • I have checked my code and corrected any misspellings

@marcospassos marcospassos added the bug Something isn't working label Sep 12, 2024
Copy link

pkg-pr-new bot commented Sep 12, 2024

Open in Stackblitz

npm i https://pkg.pr.new/@croct/sdk@429

commit: d2e93c7

Copy link

codeclimate bot commented Sep 12, 2024

Code Climate has analyzed commit ec435be and detected 0 issues on this pull request.

The test coverage on the diff in this pull request is 100.0% (50% is the threshold).

This pull request will bring the total coverage in the repository to 99.9% (0.0% change).

View more on Code Climate.

@@ -129,14 +129,15 @@ export class ContentFetcher {
}

// Types for Browser and Node environment
Copy link
Member

Choose a reason for hiding this comment

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

Move the note as well. Or remove it if you don't think it's needed.

src/contentFetcher.ts Outdated Show resolved Hide resolved
@marcospassos marcospassos merged commit 6ceb408 into master Sep 12, 2024
5 of 6 checks passed
@marcospassos marcospassos deleted the fix-timeout-log branch September 12, 2024 14:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants