You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by "zhengruifeng (via GitHub)" <gi...@apache.org> on 2023/12/01 10:08:01 UTC

[PR] [SPARK-46201][PYTHON][DOCS] Correct the typing of `schema_of_{csv, json, xml}` [spark]

zhengruifeng opened a new pull request, #44108:
URL: https://github.com/apache/spark/pull/44108

   ### What changes were proposed in this pull request?
   Correct the typing of `schema_of_{csv, json, xml}`
   
   
   ### Why are the changes needed?
   although `ColumnOrName` is defined as `ColumnOrName = Union[Column, str]`,
   we should not use it when the string here is not a column name.
   
   e.g. https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.functions.schema_of_csv.html
   
   ![image](https://github.com/apache/spark/assets/7322292/97681f11-a360-4bce-8557-2366aa07a0b5)
   
   in this case, we should follow parameter `schema` in `from_csv`:
   ![image](https://github.com/apache/spark/assets/7322292/3e05da85-6aba-4d23-b6a6-6a2fb8c9b8fd)
   
   
   
   ### Does this PR introduce _any_ user-facing change?
   yes, doc-change
   
   ### How was this patch tested?
   ci
   
   
   ### Was this patch authored or co-authored using generative AI tooling?
   no
   


-- 
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: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


Re: [PR] [SPARK-46201][PYTHON][DOCS] Correct the typing of `schema_of_{csv, json, xml}` [spark]

Posted by "dongjoon-hyun (via GitHub)" <gi...@apache.org>.
dongjoon-hyun closed pull request #44108: [SPARK-46201][PYTHON][DOCS] Correct the typing of `schema_of_{csv, json, xml}`
URL: https://github.com/apache/spark/pull/44108


-- 
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: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


Re: [PR] [SPARK-46201][PYTHON][DOCS] Correct the typing of `schema_of_{csv, json, xml}` [spark]

Posted by "zhengruifeng (via GitHub)" <gi...@apache.org>.
zhengruifeng commented on PR #44108:
URL: https://github.com/apache/spark/pull/44108#issuecomment-1835826378

   ci link: https://github.com/zhengruifeng/spark/actions/runs/7058294427/job/19214006235


-- 
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: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


Re: [PR] [SPARK-46201][PYTHON][DOCS] Correct the typing of `schema_of_{csv, json, xml}` [spark]

Posted by "zhengruifeng (via GitHub)" <gi...@apache.org>.
zhengruifeng commented on PR #44108:
URL: https://github.com/apache/spark/pull/44108#issuecomment-1836933654

   thanks @dongjoon-hyun for reviews


-- 
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: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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