Github user JoshRosen commented on a diff in the pull request:

    https://github.com/apache/spark/pull/14469#discussion_r73794005
  
    --- Diff: python/pyspark/sql/session.py ---
    @@ -384,17 +384,15 @@ def _createFromLocal(self, data, schema):
     
             if schema is None or isinstance(schema, (list, tuple)):
                 struct = self._inferSchemaFromList(data)
    +            converter = _create_converter(struct)
    --- End diff --
    
    This [`_create_converter` 
method](https://github.com/davies/spark/blob/c0ad8668ba22e51b07ba08b8e19c312783cd1b87/python/pyspark/sql/types.py#L1054)
 is confusingly-named: what it's actually doing here is converting `data` from 
a dict to a tuple in case the schema is a StructType and data is a Python 
dictionary.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to