简体   繁体   English

你能在 VS Code 中本地预览/运行 Palantir Foundry Transforms

[英]Can you preview/run Palantir Foundry Transforms locally in VS Code

After I run ./gradlew idea the build is succesful and I have been able to push code changes to the cloud via git very easily.在我运行./gradlew idea之后,构建成功并且我已经能够非常轻松地通过 git 将代码更改推送到云端。

However, I've yet been able to preview or run any of the .py transform files.但是,我还不能预览或运行任何.py转换文件。 Does anyone know if this is possible?有谁知道这是否可能?

This is the error I get which I understand but do not know how to install the package since I believe it's a Palantir Foundry thing.这是我得到的错误,我理解但不知道如何安装 package,因为我相信这是 Palantir Foundry 的东西。

from transforms.api import transform_df, Input, Output, configure
ModuleNotFoundError: No module named 'transforms'

Any help is appreciated!任何帮助表示赞赏!

Unfortunately this isn't possible.不幸的是,这是不可能的。 A workaround could be to make your changes locally and commit to your repo, then go back to Foundry and run a preview.一种解决方法可能是在本地进行更改并提交到您的存储库,然后将 go 返回 Foundry 并运行预览。

You could locally re-implement the decorators transform_df, configure and classes Input, Output of the transforms.api of Foundry until Palantir provides a workaround to run code unmodified locally.您可以在本地重新实现装饰器transform_df, configure和类Input, Outputtransforms.api的 Foundry,直到 Palantir 提供一种解决方法来在本地运行未修改的代码。

In your implementation you would need to fetch the dataset from Foundry, read it with pyspark and pass it as argument to your compute function.在您的实现中,您需要从 Foundry 获取数据集,使用 pyspark 读取它,并将其作为参数传递给您的计算 function。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 无法将地理空间工具依赖项添加到 Palantir Foundry 代码库 - Can not add geospatial-tools dependency to Palantir Foundry code repository 在 Palantir-Foundry 转换中使用 Python package “请求” - Use Python package "requests" within Palantir-Foundry transforms 在 Palantir Foundry 的代码工作簿中如何分配执行者? - How are executors assigned in Code Workbooks in Palantir Foundry? 在 Palantir Foundry 中,我怎样才能只在我的 Python Transform 的某些分支上运行测试? - In Palantir Foundry, how can I only run tests on some branches of my Python Transform? 在多个代码库中搜索关键字 - Palantir Foundry - Searching for keywords in multiple code repositories - Palantir Foundry 如何在 Palantir Foundry 的 Code Workbook 中使用 sparkcontext 创建一个空数据集? - How can I create an empty dataset using sparkcontext in Code Workbook in Palantir Foundry? 您可以在 Palantir Foundry 的操作中编辑的内容是否有任何限制? - Are there any limits around what you can edit in Palantir Foundry's Actions? 我们可以使用 Palantir Foundry 进行图像处理吗? - Can we do image processing with Palantir Foundry? 在 Palantir Foundry 代码库中创建模式数据健康预期 - Creating a schema data health expectation in Palantir Foundry Code Repositories 在 Palantir Foundry 代码库中创建主键数据健康预期 - Creating a primary key data health expectation in Palantir Foundry Code Repositories
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM