scala Python3.10是pyspark/spark 3.0.预览的默认PyCharm更新--这两者兼容吗?

wkyowqbh  于 2022-11-09  发布在  Scala
关注(0)|答案(1)|浏览(334)

有文档表明,Python3.9是与Spark 3.0.0.preview兼容的最后一个版本。对于使用Hadoop、Spark、Scala、Python和PyCharm在Windows上设置兼容性的新手来说,兼容性的可能性是令人望而生畏的,在浏览前几个可能性的同时,给出了课程建议,它正在试图找到Python和Spark的兼容性。用于Anaconda3的解释器版本为3.8.8。
在下面的图片中,它看起来像是从学校的硬碰硬,兼容性可能不存在。downloads并不表示Python的版本控制。包含该课程的Scala是2.11。最新版本还指出,Scala需要2.12(相同的链接)。在所有这些选择中(使用Windows 10),有一个解决方案,但它是难以捉摸的。Hadoop版本似乎也是一个问题。(Hadoop 2.7)
其他兼容性问题发生在为每个项目设置编辑配置之前,包括文件丢失或访问错误(这是公司计算机特权管理,但不是完全管理员权限)
从线程转储来看,似乎有一个信息日志,但又是新的,很难对所有调试信息进行排序。可能JDK是错误的?但建议与JRE1.8.0_201一起使用。我还看到了一些关于“Program Files”中可能存在的空格与JAVA_HOME路径有关的问题。在其中一次试验设置期间,当Java被安装到不同的目录时,它似乎并不高兴。

Anaconda3>pycharm
    CompileCommand: exclude com/intellij/openapi/vfs/impl/FilePartNodeRoot.trieDescend bool exclude = true
    2022-11-04 08:40:31,040 [   1132]   WARN - #c.i.o.f.i.FileTypeManagerImpl -
    com.adacore.adaintellij.file.AdaSpecFileType@4f671e00 from 'PluginDescriptor(name=Ada, id=com.adacore.Ada-IntelliJ, descriptorPath=plugin.xml, path=~\AppData\Roaming\JetBrains\PyCharmCE2022.2\plugins\Ada-IntelliJ, version=0.6-dev, package=null, isBundled=false)' (class com.adacore.adaintellij.file.AdaSpecFileType) and
    com.adacore.adaintellij.file.AdaBodyFileType@22a64016 from 'PluginDescriptor(name=Ada, id=com.adacore.Ada-IntelliJ, descriptorPath=plugin.xml, path=~\AppData\Roaming\JetBrains\PyCharmCE2022.2\plugins\Ada-IntelliJ, version=0.6-dev, package=null, isBundled=false)' (class com.adacore.adaintellij.file.AdaBodyFileType)
     both have the same .getDisplayName(): 'Ada'. Please override either one's getDisplayName() to something unique.
    com.intellij.diagnostic.PluginException:
    com.adacore.adaintellij.file.AdaSpecFileType@4f671e00 from 'PluginDescriptor(name=Ada, id=com.adacore.Ada-IntelliJ, descriptorPath=plugin.xml, path=~\AppData\Roaming\JetBrains\PyCharmCE2022.2\plugins\Ada-IntelliJ, version=0.6-dev, package=null, isBundled=false)' (class com.adacore.adaintellij.file.AdaSpecFileType) and
    com.adacore.adaintellij.file.AdaBodyFileType@22a64016 from 'PluginDescriptor(name=Ada, id=com.adacore.Ada-IntelliJ, descriptorPath=plugin.xml, path=~\AppData\Roaming\JetBrains\PyCharmCE2022.2\plugins\Ada-IntelliJ, version=0.6-dev, package=null, isBundled=false)' (class com.adacore.adaintellij.file.AdaBodyFileType)
     both have the same .getDisplayName(): 'Ada'. Please override either one's getDisplayName() to something unique. 
2022-11-04 08:40:45,822 [  15914] SEVERE - #c.i.u.m.i.MessageBusImpl - PyCharm 2022.2.3  Build #PC-222.4345.23
2022-11-04 08:40:45,825 [  15917] SEVERE - #c.i.u.m.i.MessageBusImpl - JDK: 17.0.4.1; VM: OpenJDK 64-Bit Server VM; Vendor: JetBrains s.r.o.
2022-11-04 08:40:45,826 [  15918] SEVERE - #c.i.u.m.i.MessageBusImpl - OS: Windows 10

[1]: https://spark.apache.org/downloads.html
  [2]: https://i.stack.imgur.com/C6BGc.png
mbzjlibv

mbzjlibv1#

首先,不要使用预览版。Spark 3发布已经两年多了,至少使用最新的次要版本。
话虽如此,Spark 3主要是为了与Hadoop 3一起使用。所有这些都应该在Windows上运行良好,使用的是Java 11(你的日志显示是17)。
Spark可以使用Scala 2.12或2.13。
在Python3.9上应该可以很好地支持Pyspark。如果你不需要,不要使用Python。直接下载Python。pip install pyspark。就这样。您甚至不需要Hadoop来运行Spark代码。
并且不清楚您为什么要尝试从终端运行PyCharm。从spark-shell开始,如果有效,则可以运行pyspark。然后您可以使用spark-submit。只有当这些都起作用时,您才应该实际地转向IDE。
或者,不要用一堆软件污染您的主机,而是安装Docker,并使用它来运行预配置了Spark-https://jupyter-docker-stacks.readthedocs.io/en/latest/using/running.html的Jupyter

相关问题