You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "Apache Spark (JIRA)" <ji...@apache.org> on 2018/09/02 18:05:04 UTC
[jira] [Commented] (AIRFLOW-1177) variable json deserialize does
not work at set defaults
[ https://issues.apache.org/jira/browse/AIRFLOW-1177?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16601529#comment-16601529 ]
Apache Spark commented on AIRFLOW-1177:
---------------------------------------
User 'ashb' has created a pull request for this issue:
https://github.com/apache/incubator-airflow/pull/2540
> variable json deserialize does not work at set defaults
> -------------------------------------------------------
>
> Key: AIRFLOW-1177
> URL: https://issues.apache.org/jira/browse/AIRFLOW-1177
> Project: Apache Airflow
> Issue Type: Bug
> Components: models
> Affects Versions: Airflow 1.8
> Reporter: barak schoster
> Assignee: barak schoster
> Priority: Major
> Fix For: 1.9.0, 1.8.3
>
>
> at line:
> https://github.com/apache/incubator-airflow/blob/master/airflow/models.py#L3685
> obj has no attribute val, it is the val itself.
> it will throw error like:
> Variable.setdefault("some_key", deserialize_json=True,default=json.dumps(default_dag_variables))
> File "/usr/local/lib/python2.7/site-packages/airflow/models.py", line 3586, in setdefault
> return json.loads(obj.val)
> AttributeError: 'unicode' object has no attribute 'val'
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)