Skip to content

add basic check CLI command#702

Open
MattShirley wants to merge 7 commits intomasterfrom
685-add-servicex-check-cli-command
Open

add basic check CLI command#702
MattShirley wants to merge 7 commits intomasterfrom
685-add-servicex-check-cli-command

Conversation

@MattShirley
Copy link
Collaborator

Checks all endpoints in servicex.yaml and verifies the connection with token.

@MattShirley MattShirley linked an issue Jan 21, 2026 that may be closed by this pull request
@codecov
Copy link

codecov bot commented Jan 21, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 98.38%. Comparing base (e761557) to head (8aed261).

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #702      +/-   ##
==========================================
+ Coverage   98.35%   98.38%   +0.03%     
==========================================
  Files          30       31       +1     
  Lines        2191     2234      +43     
==========================================
+ Hits         2155     2198      +43     
  Misses         36       36              
Flag Coverage Δ
unittests 98.38% <100.00%> (+0.03%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

results = {}

async def wrapped_verify_token(endpoint):
result = await verify_token(endpoint.endpoint, endpoint.token)
Copy link
Contributor

Choose a reason for hiding this comment

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

the Info endpoint in the ServiceX backend doesn't require authentication, so this is not a great test. We could add some authenticated call to the server, or for now just throw away the results from a benign endpoint that does check auth, like /servicex/datasets

import typer
from rich import get_console

from servicex.app.init import verify_token
Copy link
Contributor

Choose a reason for hiding this comment

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

Don't use methods from one cli command in another. If you need a common function for this, move it into the servicex_client

@BenGalewsky
Copy link
Contributor

hey, how about some unit tests?

@BenGalewsky BenGalewsky self-requested a review February 6, 2026 17:37
Copy link
Contributor

@BenGalewsky BenGalewsky left a comment

Choose a reason for hiding this comment

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

These changes need unit tests

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.

Add ServiceX Check CLI Command

2 participants