Build the language components of the User-Agent header string. Returns the Python version in a component with prefix "lang" and name "python". The Python implementation (e.g. CPython, PyPy) is returned as separate metadata component with prefix "md" and name "pyimpl
(self)
| 511 | return [] |
| 512 | |
| 513 | def _build_language_metadata(self): |
| 514 | """ |
| 515 | Build the language components of the User-Agent header string. |
| 516 | |
| 517 | Returns the Python version in a component with prefix "lang" and name |
| 518 | "python". The Python implementation (e.g. CPython, PyPy) is returned as |
| 519 | separate metadata component with prefix "md" and name "pyimpl". |
| 520 | |
| 521 | String representation of an example return value: |
| 522 | ``lang/python#3.10.4 md/pyimpl#CPython`` |
| 523 | """ |
| 524 | lang_md = [ |
| 525 | UserAgentComponent('lang', 'python', self._python_version), |
| 526 | ] |
| 527 | if self._python_implementation: |
| 528 | lang_md.append( |
| 529 | UserAgentComponent('md', 'pyimpl', self._python_implementation) |
| 530 | ) |
| 531 | return lang_md |
| 532 | |
| 533 | def _build_execution_env_metadata(self): |
| 534 | """ |
no test coverage detected