User agent string components based on legacy "extra" settings. Creates components from the session-level and client-level ``user_agent_extra`` setting, if present. Both are passed through verbatim and should be appended at the end of the string. Preferred ways to in
(self)
| 598 | return [] |
| 599 | |
| 600 | def _build_extra(self): |
| 601 | """User agent string components based on legacy "extra" settings. |
| 602 | |
| 603 | Creates components from the session-level and client-level |
| 604 | ``user_agent_extra`` setting, if present. Both are passed through |
| 605 | verbatim and should be appended at the end of the string. |
| 606 | |
| 607 | Preferred ways to inject application-specific information into |
| 608 | botocore's User-Agent header string are the ``user_agent_appid` field |
| 609 | in :py:class:`botocore.config.Config`. The ``AWS_SDK_UA_APP_ID`` |
| 610 | environment variable and the ``sdk_ua_app_id`` configuration file |
| 611 | setting are alternative ways to set the ``user_agent_appid`` config. |
| 612 | """ |
| 613 | extra = [] |
| 614 | if self._session_user_agent_extra: |
| 615 | extra.append( |
| 616 | RawStringUserAgentComponent(self._session_user_agent_extra) |
| 617 | ) |
| 618 | if self._client_config and self._client_config.user_agent_extra: |
| 619 | extra.append( |
| 620 | RawStringUserAgentComponent( |
| 621 | self._client_config.user_agent_extra |
| 622 | ) |
| 623 | ) |
| 624 | return extra |
| 625 | |
| 626 | def _build_legacy_ua_string(self, config_ua_override): |
| 627 | components = [config_ua_override] |
no test coverage detected