# `Snakepit.PythonThreadLimits`
[🔗](https://github.com/nshkrdotcom/snakepit/blob/v0.13.0/lib/snakepit/python_thread_limits.ex#L1)

Normalizes Python threading configuration with safe defaults.

Resolves partial overrides pulled from application environment and
produces a complete map ready for runtime consumption.

# `t`

```elixir
@type t() :: %{
  optional(:openblas) =&gt; pos_integer(),
  optional(:omp) =&gt; pos_integer(),
  optional(:mkl) =&gt; pos_integer(),
  optional(:numexpr) =&gt; pos_integer(),
  optional(:grpc_poll_threads) =&gt; pos_integer()
}
```

Thread limit configuration keyed by known library identifiers.

# `defaults`

```elixir
@spec defaults() :: t()
```

Default thread limit configuration.

# `resolve`

```elixir
@spec resolve(nil | map() | keyword()) :: t()
```

Merge a user-supplied configuration with defaults.

Accepts `nil`, maps with atom keys, or keyword lists.
Unknown keys are ignored; non-integer values are coerced with `String.to_integer/1`
when possible.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
