community icon indicating copy to clipboard operation
community copied to clipboard

fix(UrlRequest): Add "on_finish" and add alternative implementation

Open NomadDemon opened this issue 3 years ago • 3 comments

  • Added "on_finish" callback to URlRequest, it fires always when the request is done
  • Added alternative implementation for UrlRequest based on REQUESTS lib
  • It have also implemented "on_finish" and "auth" params for easy BASICAUTH handling
  • Refactored tests of new implementation to be mocked by RESPONSES, so we dont need real network to test nor we dont ping real servers during tests

Maintainer merge checklist

  • [ ] Title is descriptive/clear for inclusion in release notes.
  • [ ] Applied a Component: xxx label.
  • [ ] Applied the api-deprecation or api-break label.
  • [ ] Applied the release-highlight label to be highlighted in release notes.
  • [ ] Added to the milestone version it was merged into.
  • [ ] Unittests are included in PR.
  • [ ] Properly documented, including versionadded, versionchanged as needed.

NomadDemon avatar Jul 10 '22 12:07 NomadDemon

Thanks for opening your first pull request here! 💖 Please check out our contributing guidelines.

welcome[bot] avatar Jul 10 '22 12:07 welcome[bot]

Iam not sure if my changes in "setup" are ok, never changed stuff in setup of any package I just wanted the project to download requests and responses with it [they are wide used in real world]

NomadDemon avatar Jul 10 '22 12:07 NomadDemon

this new implementation have same interface as old "UrlRequest" just changed backend to more flexible [and tests are now made as they should be made]

NomadDemon avatar Jul 10 '22 12:07 NomadDemon

Congrats on merging your first pull request! 🎉🎉🎉

welcome[bot] avatar Aug 22 '22 23:08 welcome[bot]