open-telemetry / semantic-conventions

Defines standards for generating consistent, accessible telemetry across a variety of domains
Apache License 2.0
283 stars 175 forks source link

Semconv for cli command executions #1577

Open xrmx opened 1 week ago

xrmx commented 1 week ago

Area(s)

area:new

Is your change request related to a problem? Please describe.

Would be nice to formalize semantic conventions for cli command execution regarding span name, status and attributes.

Describe the solution you'd like

For the attributes we can reuse something from Process.

Describe alternatives you've considered

No response

Additional context

I'm implementing an instrumentation for the click library:

# hello.py
import click

@click.command()
def hello():
    click.echo('Hello World!')

if __name__ == '__main__':
    hello()

and you call them as python hello.py

This is also the underlying library used by flask where you can run the server itself, e.g. flask run or implement your own command, e.g. flask createuser myusername.