MCPcopy Create free account

hub / github.com/anthropics/anthropic-sdk-python / functions

Functions12,522 in github.com/anthropics/anthropic-sdk-python

Methodtest_copy_inherits_the_parents_credential
( self, respx_mock: MockRouter, credential_arguments: dict[str, Any], client_c
tests/lib/test_credentials.py:4519
Methodtest_copy_inherits_the_parents_host_and_headers
( self, respx_mock: MockRouter, parent_arguments: dict[str, Any], client_cls:
tests/lib/test_credentials.py:4638
Functiontest_copy_keeps_every_constructor_argument
( client_class: ClientClass, arguments: dict[str, object], all_arguments: bool )
tests/lib/test_client_copy.py:255
Functiontest_copy_keeps_propagation
(new_client: NewClient)
tests/test_tracing.py:285
Methodtest_copy_keeps_routing
(self, respx_mock: MockRouter)
tests/lib/test_google_cloud.py:1652
Methodtest_copy_keeps_user_supplied_base_url
(self)
tests/lib/test_google_cloud.py:960
Methodtest_copy_location_rederives_base_url
(self)
tests/lib/test_google_cloud.py:952
Methodtest_copy_lower_tier_credential_takes_effect
(self, respx_mock: MockRouter)
tests/lib/test_google_cloud.py:975
Methodtest_copy_of_a_client_assigned_a_second_credential
( self, respx_mock: MockRouter, credential_arguments: dict[str, Any], client_c
tests/lib/test_credentials.py:4545
Functiontest_copy_of_a_client_built_from_the_environment
( client_class: ClientClass, monkeypatch: pytest.MonkeyPatch )
tests/lib/test_client_copy.py:267
Methodtest_copy_of_a_client_resolved_from_both_env_vars
( self, respx_mock: MockRouter, clean_env: pytest.MonkeyPatch, client_cls: typ
tests/lib/test_credentials.py:4531
Methodtest_copy_of_a_client_whose_constructor_takes_no_open_telemetry_keeps_the_option
( self, sync: bool, spans: Spans, respx_mock: MockRouter )
tests/test_open_telemetry.py:4682
Functiontest_copy_of_a_scoped_client_keeps_its_bearer_alone
A new client reads `ANTHROPIC_CUSTOM_HEADERS` again, and a custom header goes before the client's own credentials. A plain `copy()` of the scoped
tests/lib/test_scoped_client.py:275
Functiontest_copy_of_deferred_client_still_backfills_and_shares_adc
( respx_mock: MockRouter, monkeypatch: pytest.MonkeyPatch )
tests/lib/test_google_cloud.py:879
Methodtest_copy_of_federation_profile_client_exchanges_per_client
Profile-backed federation: the copy exchanges at its own host and stays out of the profile's on-disk token cache, which belongs to the
tests/lib/test_credentials.py:2966
Methodtest_copy_of_user_oauth_profile_client_keeps_refresh_endpoint
A user_oauth profile's refresh token belongs to the deployment that issued it: a copy pointed at another host still refreshes at the p
tests/lib/test_credentials.py:2999
Methodtest_copy_of_workspaceless_client_keeps_assigned_base_url
(self, respx_mock: MockRouter)
tests/lib/test_google_cloud.py:1626
Methodtest_copy_of_workspaceless_client_keeps_assigned_base_url
(self, respx_mock: MockRouter)
tests/lib/test_google_cloud.py:1770
Functiontest_copy_overrides_aws_options
()
tests/lib/test_aws.py:736
Functiontest_copy_overrides_aws_profile
(client_class: "type[AnthropicBedrock] | type[AsyncAnthropicBedrock]")
tests/lib/test_bedrock.py:448
Methodtest_copy_overrides_region
(self)
tests/lib/test_bedrock_mantle.py:395
Methodtest_copy_plain_roundtrip_keeps_derived_base_url
(self)
tests/lib/test_google_cloud.py:967
Functiontest_copy_preserves_aws_options
()
tests/lib/test_aws.py:718
Methodtest_copy_preserves_config
(self)
tests/lib/test_bedrock_mantle.py:386
Methodtest_copy_preserves_header_removal
(self, client: Anthropic)
tests/test_client.py:917
Methodtest_copy_preserves_header_removal
(self, async_client: AsyncAnthropic)
tests/test_client.py:2372
Methodtest_copy_project_rederives_base_url
(self)
tests/lib/test_google_cloud.py:945
Methodtest_copy_propagates_credentials
(self)
tests/lib/test_credentials.py:2888
Functiontest_copy_region_change_explicit_base_url_wins
( client_cls: _AWSClientClass, monkeypatch: pytest.MonkeyPatch )
tests/lib/test_aws.py:802
Functiontest_copy_region_change_keeps_base_url_assigned_after_construction
( client_cls: _AWSClientClass, monkeypatch: pytest.MonkeyPatch )
tests/lib/test_aws.py:843
Functiontest_copy_region_change_keeps_custom_base_url
(client_cls: _AWSClientClass, monkeypatch: pytest.MonkeyPatch)
tests/lib/test_aws.py:817
Functiontest_copy_region_change_keeps_env_base_url
(client_cls: _AWSClientClass, monkeypatch: pytest.MonkeyPatch)
tests/lib/test_aws.py:833
Functiontest_copy_region_change_rederives_base_url
(client_cls: _AWSClientClass, monkeypatch: pytest.MonkeyPatch)
tests/lib/test_aws.py:760
Functiontest_copy_region_change_rederives_base_url_api_key_mode
( client_cls: _AWSClientClass, monkeypatch: pytest.MonkeyPatch )
tests/lib/test_aws.py:778
Functiontest_copy_region_change_rederives_base_url_skip_auth
( client_cls: _AWSClientClass, monkeypatch: pytest.MonkeyPatch )
tests/lib/test_aws.py:788
Methodtest_copy_rejects_first_party_kwargs
(self)
tests/lib/test_google_cloud.py:1036
Functiontest_copy_rejects_real_credentials_provider
()
tests/lib/test_aws.py:882
Functiontest_copy_rejects_real_credentials_provider_async
()
tests/lib/test_aws.py:893
Methodtest_copy_returns_new_instance_with_changes
(self)
tests/test_middleware.py:408
Functiontest_copy_sends_requests_through_the_http_client
(client_class: ClientClass)
tests/lib/test_client_copy.py:281
Methodtest_copy_sends_requests_to_the_resource
( self, sync: bool, method: str, respx_mock: MockRouter, monkeypatch: pytest.MonkeyPatch )
tests/lib/test_azure.py:199
Methodtest_copy_signature
(self, client: Anthropic)
tests/test_client.py:266
Methodtest_copy_signature
(self, async_client: AsyncAnthropic)
tests/test_client.py:1711
Methodtest_copy_skip_auth_clears_workspace_and_credentials
(self, respx_mock: MockRouter)
tests/lib/test_google_cloud.py:1012
Methodtest_copy_token_provider_replaces_credentials
(self, respx_mock: MockRouter)
tests/lib/test_google_cloud.py:995
Functiontest_copy_with_auth_token_keeps_the_api_key
(client_cls: _AWSClientClass)
tests/lib/test_aws.py:752
Methodtest_copy_with_different_base_url_exchanges_per_client
`copy(base_url=...)` must not move the parent's token exchange: each client exchanges its assertion at its own host and only ever pres
tests/lib/test_credentials.py:2913
Methodtest_copy_with_same_base_url_shares_token_exchange
A copy targeting the same deployment (here spelled without the trailing slash the client normalises to) keeps sharing the parent's pro
tests/lib/test_credentials.py:2949
Functiontest_copy_x_stainless_helper_header_appends
()
tests/lib/test_bedrock.py:725
Methodtest_copy_x_stainless_helper_header_appends
(self, client: Anthropic)
tests/test_client.py:907
Methodtest_copy_x_stainless_helper_header_appends
(self, async_client: AsyncAnthropic)
tests/test_client.py:2362
Methodtest_copy_x_stainless_helper_header_appends
(self)
tests/lib/test_vertex.py:341
Methodtest_copy_x_stainless_helper_header_appends
(self)
tests/lib/test_vertex.py:862
Methodtest_copy_x_stainless_helper_header_appends
x-stainless-helper accumulates across copies instead of being clobbered.
tests/lib/test_azure.py:113
Methodtest_copy_x_stainless_helper_header_appends
x-stainless-helper accumulates across copies instead of being clobbered.
tests/lib/test_azure.py:182
Methodtest_copy_x_stainless_helper_header_appends
(self)
tests/lib/test_bedrock_mantle.py:403
Methodtest_corrupt_expires_at_does_not_retain_tokens
`_coerce_expires_at` raises in a secret-free frame, but the error propagates through `_call_user_oauth` whose locals hold the creds di
tests/lib/test_credentials.py:5132
Methodtest_corrupt_expires_at_external_profile_does_not_retain_token
Same as above via the no-client_id (externally rotated) path.
tests/lib/test_credentials.py:5156
Methodtest_count_tokens
(self, body: dict[str, Any], raw: bool, spans: Spans, respx_mock: MockRouter)
tests/test_open_telemetry.py:7862
Functiontest_count_tokens_accepts_a_type
(client: Anthropic, respx_mock: MockRouter)
tests/lib/test_output_format_helpers.py:28
Functiontest_count_tokens_merges_the_type_into_an_existing_output_config
(client: Anthropic, respx_mock: MockRouter)
tests/lib/test_output_format_helpers.py:45
Functiontest_count_tokens_output_config_dict_still_works
(client: Anthropic, respx_mock: MockRouter)
tests/lib/test_output_format_helpers.py:79
Functiontest_count_tokens_rejects_a_schema_dict
(client: Anthropic)
tests/lib/test_output_format_helpers.py:60
Methodtest_count_tokens_takes_a_tool_object
(self, client: Anthropic, respx_mock: respx.MockRouter)
tests/lib/test_stainless_helpers.py:116
Methodtest_count_tokens_takes_a_tool_object
( self, async_client: AsyncAnthropic, respx_mock: respx.MockRouter )
tests/lib/test_stainless_helpers.py:217
Methodtest_create
(self, message: dict[str, Any], content_mode: str, spans: Spans, respx_mock: MockRouter)
tests/test_open_telemetry.py:7769
Methodtest_create
(self, sync_local_filesystem_tool: BetaLocalFilesystemMemoryTool)
tests/lib/tools/memory_tools/test_filesystem.py:101
Methodtest_create
(self, async_local_filesystem_tool: BetaAsyncLocalFilesystemMemoryTool)
tests/lib/tools/memory_tools/test_filesystem.py:723
Methodtest_create_error_if_file_already_exists
( self, sync_local_filesystem_tool: BetaLocalFilesystemMemoryTool )
tests/lib/tools/memory_tools/test_filesystem.py:125
Methodtest_create_error_if_file_already_exists
( self, async_local_filesystem_tool: BetaAsyncLocalFilesystemMemoryTool )
tests/lib/tools/memory_tools/test_filesystem.py:749
Methodtest_create_has_the_id_of_what_it_created
(self, raw: bool, spans: Spans, respx_mock: MockRouter)
tests/test_open_telemetry.py:7407
Methodtest_create_nested_directories
(self, sync_local_filesystem_tool: BetaLocalFilesystemMemoryTool)
tests/lib/tools/memory_tools/test_filesystem.py:113
Methodtest_create_nested_directories
( self, async_local_filesystem_tool: BetaAsyncLocalFilesystemMemoryTool )
tests/lib/tools/memory_tools/test_filesystem.py:735
Methodtest_create_without_an_id_in_its_response
( self, body: dict[str, Any], spans: Spans, respx_mock: MockRouter )
tests/test_open_telemetry.py:7445
Methodtest_credentials_file_absent_type_is_lenient
Hand-written credentials files without `type` are accepted.
tests/lib/test_credentials.py:319
Methodtest_credentials_file_group_or_other_access_rejected
(self, tmp_path: pathlib.Path, mode: int)
tests/lib/test_credentials.py:902
Methodtest_credentials_file_owner_only_accepted
(self, tmp_path: pathlib.Path)
tests/lib/test_credentials.py:910
Methodtest_credentials_file_symlink_rejected
(self, tmp_path: pathlib.Path)
tests/lib/test_credentials.py:922
Methodtest_credentials_file_wrong_type_raises
(self, tmp_path: pathlib.Path)
tests/lib/test_credentials.py:306
Functiontest_credentials_object_attaches_bearer
(respx_mock: MockRouter)
tests/lib/test_google_cloud.py:495
Methodtest_credentials_only_still_works
(self, caplog: pytest.LogCaptureFixture)
tests/lib/test_credentials.py:4718
Methodtest_credentials_path_override
Config's `credentials_path` field redirects to a custom location.
tests/lib/test_credentials.py:1050
Methodtest_credentials_type_mismatch_does_not_retain_tokens
( self, clean_env: pytest.MonkeyPatch, tmp_path: pathlib.Path )
tests/lib/test_credentials.py:5114
Functiontest_cursor_position_renders_as_a_text_line
()
tests/lib/tools/toolsets/test_computer_pipeline.py:78
Methodtest_custom_env_var
(self, monkeypatch: pytest.MonkeyPatch)
tests/lib/test_aws_auth.py:145
Methodtest_custom_env_var
(self, monkeypatch: pytest.MonkeyPatch)
tests/lib/test_aws_auth.py:245
Methodtest_custom_env_var
(self, monkeypatch: pytest.MonkeyPatch)
tests/lib/test_aws_auth.py:331
Methodtest_custom_env_var
(self, monkeypatch: pytest.MonkeyPatch)
tests/lib/test_aws_auth.py:413
Methodtest_custom_env_var_not_set_defaults_to_sigv4
(self, monkeypatch: pytest.MonkeyPatch)
tests/lib/test_aws_auth.py:159
Functiontest_custom_headers_env_authorization_never_conflicts
( respx_mock: MockRouter, monkeypatch: pytest.MonkeyPatch )
tests/lib/test_google_cloud.py:755
Functiontest_custom_headers_env_flows_through
(respx_mock: MockRouter, monkeypatch: pytest.MonkeyPatch)
tests/lib/test_google_cloud.py:736
Methodtest_custom_headers_env_var_is_overridden_case_insensitively
(self, client_cls: ClientClass)
tests/test_header_case_sensitivity.py:118
Functiontest_custom_headers_from_the_environment
( client_class: ClientClass, copied: bool, monkeypatch: pytest.MonkeyPatch )
tests/lib/test_client_copy.py:305
Functiontest_custom_headers_from_the_environment_are_signed
(sync: bool, monkeypatch: pytest.MonkeyPatch)
tests/lib/test_bedrock.py:1055
Methodtest_custom_input_schema_with_dict
(self)
tests/lib/tools/test_functions.py:132
Methodtest_custom_input_schema_with_pydantic_model
(self)
tests/lib/tools/test_functions.py:147
Methodtest_custom_name_and_description
(self)
tests/lib/tools/test_functions.py:122
Methodtest_custom_url_template
(self, monkeypatch: pytest.MonkeyPatch)
tests/lib/test_aws_auth.py:402
Functiontest_data_json_escaped_double_new_line
(sync: bool, client: Anthropic, async_client: AsyncAnthropic)
tests/test_streaming.py:148
Functiontest_data_missing_event
(sync: bool, client: Anthropic, async_client: AsyncAnthropic)
tests/test_streaming.py:48
← previousnext →5,901–6,000 of 12,522, ranked by callers