# General Translation Python SDKs: declare_static
URL: https://generaltranslation.com/en-GB/docs/python/reference/functions/declare-static.mdx
Docs index: https://generaltranslation.com/llms.txt
Description: Deprecated alias for derive that marks content for build-time extraction in General Translation Python. API Reference for declare_static.

A deprecated alias for [`derive`](/docs/python/reference/functions/derive). It marks content as statically analysable for the General Translation CLI, then delegates to [`derive`](/docs/python/reference/functions/derive). Use [`derive`](/docs/python/reference/functions/derive) in new code.

## Overview [#overview]

Call `declare_static` exactly like [`derive`](/docs/python/reference/functions/derive): wrap a static expression with a finite set of outcomes. It emits a `DeprecationWarning` and returns its input unchanged.

```python
from gt_i18n import declare_static

message = t(f"The {declare_static('boy' if gender == 'male' else 'girl')} is playing.")
```

Signature:

```python
declare_static(content: object) -> object
```

Re-exported from `generaltranslation.static` by `gt_i18n` and the framework packages.

## How it works [#how-it-works]

* **Deprecation warning.** It raises a `DeprecationWarning` recommending [`derive`](/docs/python/reference/functions/derive).
* **Delegates to [`derive`](/docs/python/reference/functions/derive).** It returns `derive(content)` — the content unchanged — so behaviour is identical to [`derive`](/docs/python/reference/functions/derive).

## Parameters [#parameters]

| Parameter             | Description                                               | Type     | Optional | Default |
| --------------------- | --------------------------------------------------------- | -------- | -------- | ------- |
| [`content`](#content) | A static expression with a finite set of possible values. | `object` | No       | —       |

### `content` [#content]

**Type** `object` · **Required**

A static expression with a finite set of possible values.

## Returns [#returns]

**Type** `object`

Returns `content` unchanged.

## Example [#example]

```python
# Deprecated — prefer derive()
from gt_i18n import declare_static  # ❌ Deprecated
from gt_i18n import derive          # ✅ Use this instead
```

## Sitemap

See the full [sitemap](https://generaltranslation.com/sitemap.md) for all pages.
