云处理后如何将 DWG 保存到 BIM 360 Docs
Posted
技术标签:
【中文标题】云处理后如何将 DWG 保存到 BIM 360 Docs【英文标题】:How to save DWG to BIM 360 Docs after cloud processing 【发布时间】:2019-09-05 21:16:45 【问题描述】:我正在编写一个设计自动化程序,它从 BIM 360 Docs 项目中读取文件,在它们上运行 lisp 例程,然后将它们保存回同一个项目。该程序可以访问文件并运行例程,但无法将它们保存回项目。目前,我在输出中使用与输入相同的 url,我确信这是导致问题的原因。但是,我不知道应该为输出使用什么 url。它也可能是我用于 accoreconsole 的命令行,但我认为前者更有可能。有人有什么想法吗?
命令行:
["$(engine.path)\\accoreconsole.exe /i $(args[inputFile].path) /al $(appbundles[" + bundleName + "].path) /s $(settings[script].path)"]
参数:
"inputFile":"ondemand":False,"required":True,"verb":"get","zip":False,"description":zipname,"localName":"$(inputFile)","outputFile":"ondemand":False,"required":True,"zip":False,"verb":"put","description":zipname,"localName":"outputFile.dwg"
输入网址示例:
https://developer.api.autodesk.com/oss/v2/buckets/wip.dm.prod/objects/234790a4-d279-4839-b00b-6f3aab9297bb.dwg
工作项参数:
"inputFile":"url":url,"headers":"Authorization":"Bearer " + token,"outputFile":"verb":"put","url":output_url,"headers":"Authorization":"Bearer " + token
日志:
[04/12/2019 20:51:12] Starting work item d5bfa4f107684a69a39e6c0c00380de4
[04/12/2019 20:51:12] Start download phase.
[04/12/2019 20:51:12] Start preparing AppPackage 41205.
[04/12/2019 20:51:12] Start download phase.
[04/12/2019 20:51:12] Download bits and install app to local cache.
[04/12/2019 20:51:12] Start downloading file https://developer.api.autodesk.com/oss/v2/buckets/wip.dm.prod/objects/234790a4-d279-4839-b00b-6f3aab9297bb.dwg.
[04/12/2019 20:51:12] End downloading file https://developer.api.autodesk.com/oss/v2/buckets/wip.dm.prod/objects/234790a4-d279-4839-b00b-6f3aab9297bb.dwg. 38839 bytes have been written to T:\Aces\Jobs\d5bfa4f107684a69a39e6c0c00380de4\234790a4-d279-4839-b00b-6f3aab9297bb.dwg.
[04/12/2019 20:51:12] End download phase.
[04/12/2019 20:51:12] Start preparing script and command line parameters.
[04/12/2019 20:51:12] Command line: [ /i T:\Aces\Jobs\d5bfa4f107684a69a39e6c0c00380de4\234790a4-d279-4839-b00b-6f3aab9297bb.dwg /al T:\Aces\Applications\3110fac452e9ee4c4d8c00a56aceef4f.gufcCWA4iPj1YRork8Qhgf75TnysvKiu.41205[1].package /s T:\Aces\Jobs\d5bfa4f107684a69a39e6c0c00380de4\setting_514.scr]
[04/12/2019 20:51:12] End preparing script and command line parameters.
[04/12/2019 20:51:12] Start script phase.
[04/12/2019 20:51:12] ### Command line arguments: /isolate HKEY_CURRENT_USER\SOFTWARE\AppDataLow\Software\Autodesk\CoreUser\WorkItem_d5bfa4f107684a69a39e6c0c00380de4 "T:\Aces\Jobs\d5bfa4f107684a69a39e6c0c00380de4\userdata" /exe "T:\Aces\AcesRoot\23.0\coreEngine\Exe\accoreconsole.exe" /i T:\Aces\Jobs\d5bfa4f107684a69a39e6c0c00380de4\234790a4-d279-4839-b00b-6f3aab9297bb.dwg /al T:\Aces\Applications\3110fac452e9ee4c4d8c00a56aceef4f.gufcCWA4iPj1YRork8Qhgf75TnysvKiu.41205[1].package /s T:\Aces\Jobs\d5bfa4f107684a69a39e6c0c00380de4\setting_514.scr.
[04/12/2019 20:51:12] Start AutoCAD Core Engine standard output dump.
[04/12/2019 20:51:12] Redirect stdout (file: T:\Aces\Jobs\d5bfa4f107684a69a39e6c0c00380de4\tmp\accc6882).
[04/12/2019 20:51:12] Sandboxer: StdOutConsoleMode: processed-output: disabled,auto
[04/12/2019 20:51:12] Isolating to regKey=HKEY_CURRENT_USER\SOFTWARE\AppDataLow\Software\Autodesk\CoreUser\WorkItem_d5bfa4f107684a69a39e6c0c00380de4, userDataFolder=T:\Aces\Jobs\d5bfa4f107684a69a39e6c0c00380de4\userdata.
[04/12/2019 20:51:12] Launching sandbox process: [T:\Aces\AcesRoot\23.0\coreEngine\Exe\accoreconsole.exe /i T:\Aces\Jobs\d5bfa4f107684a69a39e6c0c00380de4\234790a4-d279-4839-b00b-6f3aab9297bb.dwg /al T:\Aces\Applications\3110fac452e9ee4c4d8c00a56aceef4f.gufcCWA4iPj1YRork8Qhgf75TnysvKiu.41205[1].package /s T:\Aces\Jobs\d5bfa4f107684a69a39e6c0c00380de4\setting_514.scr /isolate HKEY_CURRENT_USER\SOFTWARE\AppDataLow\Software\Autodesk\CoreUser\WorkItem_d5bfa4f107684a69a39e6c0c00380de4 T:\Aces\Jobs\d5bfa4f107684a69a39e6c0c00380de4\userdata]
[04/12/2019 20:51:12] Waiting for child process to complete: 216
[04/12/2019 20:51:12] Redirect stdout (file: T:\Aces\Jobs\d5bfa4f107684a69a39e6c0c00380de4\tmp\accc37042).
[04/12/2019 20:51:12] AcCoreConsole: StdOutConsoleMode: processed-output: disabled,auto
[04/12/2019 20:51:12] AutoCAD Core Engine Console - Copyright 2018 Autodesk, Inc. All rights reserved. (P.45.Z.52)
[04/12/2019 20:51:12] Execution Path:
[04/12/2019 20:51:12] T:\Aces\AcesRoot\23.0\coreEngine\Exe\accoreconsole.exe
[04/12/2019 20:51:12] Isolating to regkey=HKEY_CURRENT_USER\SOFTWARE\AppDataLow\Software\Autodesk\CoreUser\WorkItem_d5bfa4f107684a69a39e6c0c00380de4, userDataFolder=T:\Aces\Jobs\d5bfa4f107684a69a39e6c0c00380de4\userdata.
[04/12/2019 20:51:12] Version Number: P.45.Z.52 (UNICODE)
[04/12/2019 20:51:12] Current Directory: T:\Aces\Jobs\d5bfa4f107684a69a39e6c0c00380de4
[04/12/2019 20:51:13] Regenerating model.
[04/12/2019 20:51:13] Command:
[04/12/2019 20:51:13] Command: Enter BACKSPACE to interrupt script.
[04/12/2019 20:51:13] Command:
[04/12/2019 20:51:13] Process exit code: 0
[04/12/2019 20:51:13] End AutoCAD Core Engine standard output dump.
[04/12/2019 20:51:13] End script phase.
[04/12/2019 20:51:13] Start upload phase.
[04/12/2019 20:51:13] Error: Non-optional output [outputFile.dwg] is missing .
[04/12/2019 20:51:13] Error: An unexpected error happened during phase Publishing of job.
[04/12/2019 20:51:13] Job finished with result FailedMissingOutput
[04/12/2019 20:51:13] Job Status:
"status": "failedInstructions",
【问题讨论】:
【参考方案1】:我在 AutoCAD 命令行启动后看不到任何命令。您能否检查您的“设置/脚本”部分(您的活动)是否包含任何 AutoCAD 命令?或者每个命令后面是否都有换行符?
【讨论】:
我的设置/脚本部分指向应用程序包中的 lisp 例程。 嗨 Ryan,您可以通过 qun.lu@autodesk.com 联系我,以便我们更仔细地了解您与此工作项相关的活动和应用程序吗?谢谢, - 群 Ryan,在您的活动“设置”中,更改为:“设置”:“脚本”:“值”:“accore\n”。您需要在“accore”命令后换行才能输入命令。 嗨 Qun,我添加了换行符,但我仍然收到与之前相同的错误,但现在我收到一条错误消息,提示“未知命令“ACCORE”。”您认为问题可能出在我在应用程序包中创建的 xml 文件上吗?以上是关于云处理后如何将 DWG 保存到 BIM 360 Docs的主要内容,如果未能解决你的问题,请参考以下文章
如何使用 BIM360 存储的 dwfx 文件在网页中实现模型查看器
上传到 BIM 360 或 Forge Viewer 时如何防止某些元素爆炸