Comments (8)
Hmm, thanks. I'll try reproducing it later today or tomorrow. Will assign it to myself for now.
from airflow.
Thanks for opening your first issue here! Be sure to follow the issue template! If you are willing to raise PR to address this issue please do so, no need to wait for approval.
from airflow.
@MialLewis could you share a complete example, ie a complete dag that could be used to replicate the behaviour and any other configs/etc?
from airflow.
Here is a minimal dag that reproduces the issue:
from airflow import DAG
from airflow.utils.dates import days_ago
default_args = {
'owner': 'airflow',
}
with DAG(
dag_id='issue_dag',
default_args=default_args,
start_date=days_ago(2),
tags=['issue'],
) as dag:
@dag.task
def error_fn():
import pandas as pd
output_df = pd.DataFrame({'col1': [1, 2], 'col2': [3, 4]})
engine = _get_engine_from_conn(conn_id='MariaDB')
output_df.to_sql(name='test_table', con=engine, schema='temp', if_exists='replace')
def _get_engine_from_conn(conn_id):
from airflow.providers.mysql.hooks.mysql import MySqlHook as hook
db_hook = hook(mysql_conn_id=conn_id)
engine = db_hook.get_sqlalchemy_engine()
return engine
error_task = error_fn()
The connection I am using to a simple MariaDB of the latest version:
from airflow.
I tried reproducing it, I see that the issue is because of the values in extra, ie the {}. Removing them removes the extra field from the engine and doesn't cause the issue. Though the existence of the extra field is odd to be because to my knowledge mysql doesn't accept it... 🤔 @potiuk would you know if that should probably not exist in the mysql connection type? Or maybe it should be encoded some other way?
Also @MialLewis to fix your issue you can just remove the {} from extras and you should be good.
from airflow.
I can’t remove the ‘{}’, it gets put there by default when the extra field is left empty.
I mentioned this in the issue post:
“Looking at previous versions of airflow, the default value in the extras field in a connection appears to have gone from None to {}.”
Thanks for taking the time to look into this.
from airflow.
from airflow.
This issue has been automatically marked as stale because it has been open for 14 days with no response from the author. It will be closed in next 7 days if no further activity occurs from the issue author.
from airflow.
Related Issues (20)
- admin canot see admin components HOT 2
- Azure Datalake Storage V2 ObjectStoragePath connection issues HOT 1
- PythonVirtualOperator fails silently when virtualenv is not installed. HOT 9
- RedshiftDataOperator fails when `return_sql_result` is true, and SQL statements are provided HOT 1
- ElasticsearchSQLHook fails with AttributeError: __enter__ HOT 4
- Airflow log cannot be displayed on logs page HOT 6
- ProcessingJobName is not preserved after execution returns from deferred state in SM proceesing job HOT 1
- deferred tasks get kill during heartbeat callback in some rare cases
- Enhance Variable.set to create versions in GCP Secret Manager when backend is connected
- Task processes killed with SIGTERM signal - task PID of job runner does not match
- Add task status filters to Task Duration Histogram view HOT 1
- Deferred operator do not preserve attribute values set during execution HOT 1
- Missing `usePgbouncer` key for Triggerer
- Logging out from Web UI raises Airflow 405 error HOT 8
- Vertex AI job operators in deferrable mode assume job uses Managed Model HOT 3
- EmrContainerOperator in Async mode doesn't respect default "infinite" polling number HOT 2
- Change signature of `cleanup_stuck_queued_tasks` to return TIs or TI Keys
- SparkKubernetesOperator fails to fetch the driver pod when SparkApplication is still in pending state
- ImportError: /usr/lib/x86_64-linux-gnu/libstdc++.so.6: cannot allocate memory in static TLS block
- SparkSqlOperator and SparkSubmitOperator are using different types for configurations HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from airflow.