plutaniano opened a new issue, #56401:
URL: https://github.com/apache/airflow/issues/56401
### Apache Airflow version
3.1.0
### If "Other Airflow 2 version" selected, which one?
_No response_
### What happened?
The following DAG produces an error when triggered.
```python
from airflow.sdk import asset
@asset(
schedule=None,
name="custom_name",
)
def function_name(self): ...
```
```
[2025-10-04 22:40:51] INFO - DAG bundles loaded: dags-folder
source=airflow.dag_processing.bundles.manager.DagBundlesManager
loc=manager.py:179
[2025-10-04 22:40:51] INFO - Filling up the DagBag from
/opt/airflow/dags/a.py source=airflow.models.dagbag.DagBag loc=dagbag.py:593
[2025-10-04 22:40:51] ERROR - Task failed with exception source=task
loc=task_runner.py:972
AirflowRuntimeError: ASSET_NOT_FOUND: {'name': 'function_name'}
Arquivo
"/home/airflow/.local/lib/python3.12/site-packages/airflow/sdk/execution_time/task_runner.py",
linha 920 em run
Arquivo
"/home/airflow/.local/lib/python3.12/site-packages/airflow/sdk/execution_time/task_runner.py",
linha 1307 em _execute_task
Arquivo
"/home/airflow/.local/lib/python3.12/site-packages/airflow/sdk/bases/operator.py",
linha 416 em wrapper
Arquivo
"/home/airflow/.local/lib/python3.12/site-packages/airflow/providers/standard/operators/python.py",
linha 199 em execute
Arquivo
"/home/airflow/.local/lib/python3.12/site-packages/airflow/sdk/definitions/asset/decorators.py",
linha 97 em determine_kwargs
Arquivo
"/home/airflow/.local/lib/python3.12/site-packages/airflow/sdk/definitions/asset/decorators.py",
linha 89 em _iter_kwargs
Arquivo
"/home/airflow/.local/lib/python3.12/site-packages/airflow/sdk/definitions/asset/decorators.py",
linha 81 em _fetch_asset
```
### What you think should happen instead?
The error shouldn't happen and the DAG should run normally.
### How to reproduce
In an AIrflow 3.1.0 instance, add the following DAG and trigger it. The
error will appear in the logs.
```python
from airflow.sdk import asset
@asset(
schedule=None,
name="custom_name",
)
def function_name(self): ...
```
### Operating System
Debian 12
### Versions of Apache Airflow Providers
apache-airflow-core==3.1.0
### Deployment
Official Apache Airflow Helm Chart
### Deployment details
_No response_
### Anything else?
_No response_
### Are you willing to submit PR?
- [x] Yes I am willing to submit a PR!
### Code of Conduct
- [x] I agree to follow this project's [Code of
Conduct](https://github.com/apache/airflow/blob/main/CODE_OF_CONDUCT.md)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]