# PEP 736: Shorthand syntax for keyword arguments at invocation

**URL:** <https://discuss.python.org/t/pep-736-shorthand-syntax-for-keyword-arguments-at-invocation/43432>\
**Category:** PEPs\
**Created:** [January 17, 2024, 2:11pm UTC](https://discuss.python.org/t/pep-736-shorthand-syntax-for-keyword-arguments-at-invocation/43432 "2024-01-17T14:11:03Z")\
**Posts on this page:** 1\
**Showing post:** 110

<div class="post-metadata">

**Author:** ![Jacob-Stevens-Haas](https://sea2.discourse-cdn.com/flex002/user_avatar/discuss.python.org/jacob-stevens-haas/32/3998_2.png) [@Jacob-Stevens-Haas](https://discuss.python.org/u/Jacob-Stevens-Haas)\
**Post date:** [January 24, 2024, 2:28pm UTC](https://discuss.python.org/t/pep-736-shorthand-syntax-for-keyword-arguments-at-invocation/43432/110 "2024-01-24T14:28:39Z")

</div>

That’s fair. My point is that examples like this show when eliding a kwarg illuminates an important name. We should also consider whether the API could’ve used more context-appropriate names in the first place, and how PEP-736 would look with those names.

In this case, it seems like the function does have more context on `meter` and `excluded_urls` (and maybe more, depending upon what’s in the …), which could use a more context-appropriate name. This is a case where the poster’s missing context was only missed because it came from the global scope, and only stood out so much in PEP 736 because the `add_instrument` didn’t use a more context-appropriate name for `meter` and `excluded_urls`. Maybe this is the appropriate comparison?

```python
app.add_middleware(
        OpenTelemetryMiddleware,
        excluded_urls=parsed_exclusions,
        default_span_details=_get_default_span_details,
        server_request_hook=,
        client_request_hook=,
        client_response_hook=,
        tracer_provider=,
        meter=instrument_meter,
    )

```

…which still stands out. So the more I think about this example, the more I agree with it’s author. Wrappers and factories like `instrument_app()` will usually only have more context for some subset of the arguments they pass along, which are exactly the arguments that would stand out if the others are elided.

So to paraphrase the author, the PEP makes important differences become more visible _so long as the important differences are given different names_.

---

_[View the full topic](https://discuss.python.org/t/pep-736-shorthand-syntax-for-keyword-arguments-at-invocation/43432)._
