Skip to content

Added option to include endpoint details #62

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

Merged
merged 7 commits into from
Nov 29, 2024
Merged

Conversation

alex-gts
Copy link
Contributor

Allows for setting if full endpoint details are returned, and fixes a bug where endpoint details weren't returned when retrieving results from cache.

@Shutgun
Copy link
Collaborator

Shutgun commented Nov 21, 2024

Hi @alex-gts , the more I think about it, I guess it was not intended to hide the endpoint details. Am I right that by adding

all="done",

as line 77 the issue is fixed? By reading the API docs and doing some tests I didn't find any reason to use off on the high level. And if it really is that easy, I guess I would also strip the include_details parameter.

@alex-gts
Copy link
Contributor Author

Hi @Shutgun,

The only reason I added it in is that not requesting full details could be quicker. Therefore, if someone was optimising for speed they could omit the slower, more detailed report.

This is why I added the extra check at line 86, so that you can choose to not return details, extending the existing functionality that returned full details regardless.

It is fully backward compatible, and so having the extra parameter poses no risk to existing implementations.

That said, it does not directly affect my use case and so my issue would be fixed by just all="done" as you mentioned.

@Shutgun
Copy link
Collaborator

Shutgun commented Nov 25, 2024

I made a few (to be honest not many) tests on the performance and I don't think it makes any difference. To keep the code simple: could you change the PR to just adding the all parameter?

@Shutgun
Copy link
Collaborator

Shutgun commented Nov 25, 2024

The test failure in unrelated and comes from a change in behavior of pytest-httpx. Don't worry about that.

@alex-gts
Copy link
Contributor Author

All done, I've removed the include_details parameter.

The only change now is the addition of all="done" at line 77.

Shutgun
Shutgun previously approved these changes Nov 27, 2024
@Shutgun
Copy link
Collaborator

Shutgun commented Nov 29, 2024

Hi @alex-gts , the workflow does not allow me to merge your code with a broken CI. So we need to do two more things, please:

  1. I fixed pytest-httpx errors in Fix tests #63, so you'd need to rebase your branch.
  2. In order to respect your change and make the tests green, you need to change two lines in tests/test_ssllabs.py.

Line 47 gets to:
host="devolo.de", ignoreMismatch="off", publish="off", startNew="on", fromCache="off", maxAge=None, all="done"
Line 52 gets to:
host="devolo.de", ignoreMismatch="off", publish="off", startNew="off", fromCache="on", maxAge=1, all="done"

Shutgun and others added 4 commits November 29, 2024 14:36
Bumps [actions/checkout](https://github.com/actions/checkout) from 4.1.7 to 4.2.2.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](actions/checkout@v4.1.7...v4.2.2)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [actions/setup-python](https://github.com/actions/setup-python) from 5.1.0 to 5.3.0.
- [Release notes](https://github.com/actions/setup-python/releases)
- [Commits](actions/setup-python@v5.1.0...v5.3.0)

---
updated-dependencies:
- dependency-name: actions/setup-python
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
@alex-gts
Copy link
Contributor Author

Hi @Shutgun,

Thank you, I've rebased and updated the test conditions.

@Shutgun Shutgun merged commit 0bd3a39 into devolo:main Nov 29, 2024
9 checks passed
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.

2 participants