Home / Function/ make_jsonl_iterator() — anthropic-sdk-python Function Reference

make_jsonl_iterator() — anthropic-sdk-python Function Reference

Architecture documentation for the make_jsonl_iterator() function in test_jsonl.py from the anthropic-sdk-python codebase.

Entity Profile

Dependency Diagram

graph TD
  6707cd01_7500_5cae_e645_5cf9bf66f082["make_jsonl_iterator()"]
  7e6f1ef1_47fa_dc28_4bd9_c457af975269["test_jsonl.py"]
  6707cd01_7500_5cae_e645_5cf9bf66f082 -->|defined in| 7e6f1ef1_47fa_dc28_4bd9_c457af975269
  a1a63b55_d4e5_c191_2c0c_ccd06f05d464["test_basic()"]
  a1a63b55_d4e5_c191_2c0c_ccd06f05d464 -->|calls| 6707cd01_7500_5cae_e645_5cf9bf66f082
  7d498117_8c32_2517_69d8_44577a79204b["test_new_lines_in_json()"]
  7d498117_8c32_2517_69d8_44577a79204b -->|calls| 6707cd01_7500_5cae_e645_5cf9bf66f082
  680000ee_7490_fdd4_b32d_a0559dc09eee["test_multi_byte_character_multiple_chunks()"]
  680000ee_7490_fdd4_b32d_a0559dc09eee -->|calls| 6707cd01_7500_5cae_e645_5cf9bf66f082
  44cf9ec7_7619_ae1d_5a7c_338b1782cd11["to_aiter()"]
  6707cd01_7500_5cae_e645_5cf9bf66f082 -->|calls| 44cf9ec7_7619_ae1d_5a7c_338b1782cd11
  style 6707cd01_7500_5cae_e645_5cf9bf66f082 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

tests/decoders/test_jsonl.py lines 79–88

def make_jsonl_iterator(
    content: Iterator[bytes],
    *,
    sync: bool,
    line_type: type[_T],
) -> JSONLDecoder[_T] | AsyncJSONLDecoder[_T]:
    if sync:
        return JSONLDecoder(line_type=line_type, raw_iterator=content, http_response=httpx.Response(200))

    return AsyncJSONLDecoder(line_type=line_type, raw_iterator=to_aiter(content), http_response=httpx.Response(200))

Subdomains

Calls

Frequently Asked Questions

What does make_jsonl_iterator() do?
make_jsonl_iterator() is a function in the anthropic-sdk-python codebase, defined in tests/decoders/test_jsonl.py.
Where is make_jsonl_iterator() defined?
make_jsonl_iterator() is defined in tests/decoders/test_jsonl.py at line 79.
What does make_jsonl_iterator() call?
make_jsonl_iterator() calls 1 function(s): to_aiter.
What calls make_jsonl_iterator()?
make_jsonl_iterator() is called by 3 function(s): test_basic, test_multi_byte_character_multiple_chunks, test_new_lines_in_json.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free