Skip to content

Refactor: improve REST API client#1335

Merged
josecelano merged 1 commit intotorrust:developfrom
josecelano:689-extract-tracker-api-client-packages
Feb 28, 2025
Merged

Refactor: improve REST API client#1335
josecelano merged 1 commit intotorrust:developfrom
josecelano:689-extract-tracker-api-client-packages

Conversation

@josecelano
Copy link
Copy Markdown
Member

@josecelano josecelano commented Feb 28, 2025

Refactor: improve REST API client:

  • Add a timeout to the requests.
  • Return an error in the constructor if it can't build the HTTP client.
  • Extract constants.

- Add a timeout to the requests.
- Return an error in the construction if it can't build the HTTP client.
- Extract constants.
@josecelano josecelano self-assigned this Feb 28, 2025
@josecelano josecelano added the Code Cleanup / Refactoring Tidying and Making Neat label Feb 28, 2025
@josecelano josecelano added the - Developer - Torrust Improvement Experience label Feb 28, 2025
@josecelano josecelano linked an issue Feb 28, 2025 that may be closed by this pull request
@josecelano
Copy link
Copy Markdown
Member Author

ACK 89b0bfd

@codecov
Copy link
Copy Markdown

codecov bot commented Feb 28, 2025

Codecov Report

Attention: Patch coverage is 94.73684% with 1 line in your changes missing coverage. Please review.

Project coverage is 81.52%. Comparing base (1f69e02) to head (89b0bfd).
Report is 2 commits behind head on develop.

Files with missing lines Patch % Lines
packages/rest-tracker-api-client/src/v1/client.rs 94.73% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #1335      +/-   ##
===========================================
- Coverage    81.53%   81.52%   -0.02%     
===========================================
  Files          230      230              
  Lines        16358    16368      +10     
  Branches     16358    16368      +10     
===========================================
+ Hits         13338    13344       +6     
  Misses        2792     2792              
- Partials       228      232       +4     

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

@josecelano josecelano merged commit 809b85b into torrust:develop Feb 28, 2025
23 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

- Developer - Torrust Improvement Experience Code Cleanup / Refactoring Tidying and Making Neat

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Extract Tracker API Client packages

1 participant