{"id":22555463,"url":"https://github.com/eclipse-cdt-cloud/tsp-python-client","last_synced_at":"2025-07-29T08:10:03.928Z","repository":{"id":39852038,"uuid":"236827000","full_name":"eclipse-cdt-cloud/tsp-python-client","owner":"eclipse-cdt-cloud","description":"Client-side implementation, in Python, of the Trace Server Protocol (TSP)","archived":false,"fork":false,"pushed_at":"2025-07-22T13:34:15.000Z","size":200,"stargazers_count":6,"open_issues_count":10,"forks_count":16,"subscribers_count":9,"default_branch":"master","last_synced_at":"2025-07-22T15:28:05.562Z","etag":null,"topics":["eclipse","eclipse-foundation","python","trace","trace-server-protocol","trace-visualization","tsp","tsp-python-client"],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/eclipse-cdt-cloud.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-01-28T19:52:50.000Z","updated_at":"2025-07-22T13:34:20.000Z","dependencies_parsed_at":"2022-09-21T03:24:26.719Z","dependency_job_id":"21696ce4-5e95-4ed0-9322-d4009f634f6a","html_url":"https://github.com/eclipse-cdt-cloud/tsp-python-client","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/eclipse-cdt-cloud/tsp-python-client","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eclipse-cdt-cloud%2Ftsp-python-client","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eclipse-cdt-cloud%2Ftsp-python-client/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eclipse-cdt-cloud%2Ftsp-python-client/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eclipse-cdt-cloud%2Ftsp-python-client/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/eclipse-cdt-cloud","download_url":"https://codeload.github.com/eclipse-cdt-cloud/tsp-python-client/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eclipse-cdt-cloud%2Ftsp-python-client/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267652785,"owners_count":24122099,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-07-29T02:00:12.549Z","response_time":2574,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["eclipse","eclipse-foundation","python","trace","trace-server-protocol","trace-visualization","tsp","tsp-python-client"],"created_at":"2024-12-07T19:07:57.169Z","updated_at":"2025-07-29T08:10:03.892Z","avatar_url":"https://github.com/eclipse-cdt-cloud.png","language":"Python","readme":"# tsp-python-client\n\nClient-side implementation, in Python, of the [Trace Server Protocol (TSP)][tsp].\n\nIt provides a module that can be included in Python scripts to query a trace server via the Trace Server Protocol (TSP).\nThe script **tsp_cli_client** provides a command-line interface for querying a trace server.\n\nAn example trace server implementation is provided by the [Eclipse Trace Compass Incubator][inc] project and can be downloaded [here][rcp].\nIt can be used to test this script and module.\n\nThis trace server bundles non-UI, core plug-ins of the [Eclipse Trace Compass][etc] project and comes with a server-side TSP implementation.\n\n**👋 Want to help?** Read our [contributor guide][contributing].\n\n## Status\n\n- The **tsp_cli_client** script and the **tsp** module is under construction.\n- This is an initial draft and only limited features have been currently implemented.\n- **tsp** module only provides some limited number of TSP calls.\n- The API will undergo revision till a stable version is reached.\n\n## Setup\n\nTo initialize a local virtual environment, type the following commands in the root directory:\n\n```shell\npython3 -m venv .venv\nsource .venv/bin/activate\npip install -r requirements.txt\n```\n\nThe virtual environment can be replaced with another local setup.\n\n## Tests\n\nTo run currently available integration tests, launch a server and type the following command in the root directory:\n\n**Note: Executing the tests will delete all traces and experiments from trace server workspace. Backup workspace before running the tests or start from fresh workspace.**\n\n```shell\ngit submodule update --init\n.venv/bin/pytest\n```\n\nAbove, the pytest command can be replaced with another local installation.\n\nAdd this to that command to also get **tsp** module code test coverage, here listing uncovered line numbers only:\n\n```shell\npytest --cov tsp --cov-report term-missing:skip-covered\n```\n\n## Usage\n\nTo activate completion for **tsp_cli_client** options, follow [these instructions][agc].\n\nTo use the **tsp_cli_client** script, type the following command in the root directory to get the usage:\n\n```python\n./tsp_cli_client -h\n\nusage: tsp_cli_client [-h] [--ip IP] [--port PORT] \n                      [--open-trace TRACE_PATH]\n                      [--name NAME] [--list-trace UUID] [--list-traces]\n                      [--delete-trace UUID] [--open-experiment EXP_NAME]\n                      [--list-experiment UUID] [--list-experiments]\n                      [--delete-experiment UUID] [--list-outputs UUID]\n                      [--list-output OUTPUT_ID] [--get-tree OUTPUT_ID]\n                      [--get-virtual-table-columns OUTPUT_ID]\n                      [--get-virtual-table-lines OUTPUT_ID] \n                      [--table-line-index INDEX] [--table-line-count COUNT]\n                      [--table-times [TIMES ...]] [--table-column-ids [IDs ...]]\n                      [--table-search-direction DIRECTION]\n                      [--table-search-expression COLUMN_ID EXPRESSION]\n                      [--get-timegraph-tree OUTPUT_ID] \n                      [--get-xy-tree OUTPUT_ID] [--get-xy OUTPUT_ID]\n                      [--items [ITEMS ...]] [--time-range START END NUM_TIMES]\n                      [--uuid UUID] [--uuids [UUIDS ...]] [--do-delete-traces]\n                      [--paths [PATHS ...]]\n                      [--list-configuration-sources] \n                      [--list-configuration-source TYPE_ID] \n                      [--list-configurations TYPE_ID]\n                      [--list-configuration CONFIG_ID] \n                      [--load-configuration] \n                      [--update-configuration] \n                      [--delete-configuration CONFIGURATION_ID]\n                      [--type-id TYPE_ID] \n                      [--config-id CONFIG_ID] \n                      [--params PARAMS]\n                      [--get-health]\n                      [--get-identifier]\n                      [--list-output-configuration-sources OUTPUT_ID]\n                      [--list-output-configuration-source TYPE_ID]\n                      [--create-output OUTPUT_ID]\n                      [--delete-output DERIVED_OUTPUT_ID]\n                      [--output-id OUTPUT_ID]\n                      [--json-file JSON_FILE]\n\nCLI client to send Trace Server Protocol commands to a Trace Server.\n\noptional arguments:\n  -h, --help            show this help message and exit\n  --ip IP               IP address of trace server\n  --port PORT           port of trace server\n  --open-trace TRACE_PATH\n                        Path to trace to open\n  --name NAME           trace name\n  --list-trace UUID     Get details on the given trace\n  --list-traces         List all open traces on the server\n  --delete-trace UUID   Delete a trace on the server\n  --open-experiment EXP_NAME\n                        Open experiment on the server\n  --list-experiment UUID\n                        Get details on the given experiment\n  --list-experiments    List all open experiments on the server\n  --delete-experiment UUID\n                        Delete an experiment on the server\n  --list-outputs UUID   Get details on the given trace\n  --list-output OUTPUT_ID\n                        Get details on the given output of a trace\n  --get-tree OUTPUT_ID  Get the tree of an output of type DATA_TREE\n  --get-virtual-table-columns OUTPUT_ID\n                        Get the columns of an output of type DATA_TREE\n  --get-virtual-table-lines OUTPUT_ID\n                        Get the tree lines of an output of type DATA_TREE\n  --table-line-index TABLE_LINE_INDEX\n                        The index of the table line to start fetching\n  --table-line-count TABLE_LINE_COUNT\n                        The number of table lines to fetch\n  --table-times [TABLE_TIMES ...]\n                        The list of times to fetch from table\n  --table-column-ids [TABLE_COLUMN_IDS ...]\n                        The list of column ids to fetch\n  --table-search-direction TABLE_LINE_SEARCH_DIRECTION\n                        The direction to search for the table lines\n  --table-search-expression COLUMN_ID EXPRESSION\n                        The columns expression to search for the table lines\n  --get-timegraph-tree OUTPUT_ID\n                        Get the tree of an output of type TIME_GRAPH\n  --get-xy-tree OUTPUT_ID\n                        Get the tree of an output of type TREE_TIME_XY\n  --get-xy OUTPUT_ID    Get the XY data of an output\n  --items [ITEMS ...]   The list of XY items requested\n  --time-range START END NUM_TIMES\n                        The time range requested\n  --uuid UUID           The UUID of a trace\n  --uuids [UUIDS ...]   The list of UUIDs\n  --do-delete-traces    Also delete traces when deleting experiment\n  --paths [PATHS ...]   List of trace paths to be part of an experiment\n  --list-configuration-sources\n                        Get the available configuration sources\n  --list-configuration-source TYPE_ID\n                        Get a available configuration source\n  --list-configurations TYPE_ID\n                        Get the configurations loaded for given type\n  --list-configuration CONFIG_ID\n                        Get a configuration loaded for given type and config id\n  --load-configuration  Load an configuration using paramemeters provided by --params\n  --update-configuration\n                        Update an configuration using paramemeters provided by --params\n  --delete-configuration CONFIGURATION_ID\n                        Delete a configuration\n  --type-id TYPE_ID     id of configuration source type\n  --config-id CONFIG_ID\n                        id of configuration\n  --params PARAMS       comma separated key value pairs (key1=val1,key2=val2)\n  --get-health          Get the health status of the server\n  --get-identifier      Identify important information regarding the server and the system\n  --list-output-configuration-sources OUTPUT_ID\n                        Get available configuration sources for a given experiment and output\n  --list-output-configuration-source TYPE_ID\n                        Get configuration source for a given experiment, output and type\n  --create-output OUTPUT_ID\n                        Create derived output provided by --param or --json-file\n  --delete-output DERIVED_OUTPUT_ID\n                        Delete derived output\n  --output-id OUTPUT_ID\n                        The output ID\n  --json-file JSON_FILE\n                        JSON file with parameter\n```\n\nExamples:\n```python\n  '''Open trace ''' \n  ./tsp_cli_client --open-trace TRACE_PATH [--name NAME]\n  ./tsp_cli_client --list-traces\n  ./tsp_cli_client --list-trace UUID\n  ./tsp_cli_client --list-trace UUID\n  ./tsp_cli_client --delete-trace UUID\n  ./tsp_cli_client --open-experiment EXP_NAME --uuids UUIDS \n  ./tsp_cli_client --open-experiment EXP_NAME --paths PATHS\n  ./tsp_cli_client --list-experiments\n  ./tsp_cli_client --list-experiment UUID\n  ./tsp_cli_client --delete-experiment UUID [--do-delete-traces]\n  ./tsp_cli_client --list-outputs UUID\n  ./tsp_cli_client --list-output OUTPUT_ID --uuid UUID\n  ./tsp_cli_client --get-tree OUTPUT_ID --uuid UUID\n  ./tsp_cli_client --get-virtual-table-columns OUTPUT_ID --uuid UUID\n  ./tsp_cli_client --get-virtual-table-lines --table-line-index INDEX --table-line-count COUNT --table-column-ids IDs --table-search-direction DIRECTION --table-search-expression COLUMN_ID EXPRESSION\n  ./tsp_cli_client --get-timegraph-tree OUTPUT_ID --uuid UUID\n  ./tsp_cli_client --get-xy-tree OUTPUT_ID --uuid UUID\n  ./tsp_cli_client --get-xy OUTPUT_ID --uuid UUID --items ITEMS --time-range START END NUM_TIMES\n  ./tsp_cli_client --list-configuration-sources\n  ./tsp_cli_client --list-configuration-source TYPE_ID\n  ./tsp_cli_client --list-configurations TYPE_ID\n  ./tsp_cli_client --list-configuration CONFIG_ID --type-id TYPE_ID\n  ./tsp_cli_client --load-configuration --type-id TYPE_ID --json-file absolute-path-to-json-file\n  ./tsp_cli_client --load-configuration --type-id TYPE_ID --params key1:value1\n  ./tsp_cli_client --update-configuration --type-id TYPE_ID --config-id CONFIG_ID --json-file absolute-path-to-json-file\n  ./tsp_cli_client --update-configuration --type-id TYPE_ID --config-id CONFIG_ID --params key1=value1,key2=value2\n  ./tsp_cli_client --delete-configuration CONFIGURATION_ID --type-id TYPE_ID\n  ./tsp_cli_client --list-output-configuration-sources OUTPUT_ID --uuid UUID\n  ./tsp_cli_client --list-output-configuration-source TYPE_ID --output-id OUTPUT_ID --uuid UUID\n  ./tsp_cli_client --create-output OUTPUT_ID --uuid UUID --json-file absolute-path-to-json-file\n  ./tsp_cli_client --delete-output DERIVED_OUTPUT_ID --output-id  OUTPUT_ID --uuid UUID\n  ./tsp_cli_client --get-health\n  ./tsp_cli_client --get-identifier\n```\n\n[agc]: https://kislyuk.github.io/argcomplete/#activating-global-completion\n[contributing]: CONTRIBUTING.md\n[etc]: https://www.eclipse.org/tracecompass/\n[inc]: https://projects.eclipse.org/projects/tools.tracecompass.incubator\n[rcp]: https://download.eclipse.org/tracecompass.incubator/trace-server/rcp/\n[tsp]: https://github.com/eclipse-cdt-cloud/trace-server-protocol\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feclipse-cdt-cloud%2Ftsp-python-client","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Feclipse-cdt-cloud%2Ftsp-python-client","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feclipse-cdt-cloud%2Ftsp-python-client/lists"}