Skip to content

Malformed temp file paths in Windows cause post-process scripts to fail #776

Description

@unklegwar

Is there an existing issue for this problem?

  • I have searched the existing issues

Snapmaker_Orca Version

2.3.5

Operating System (OS)

Windows

OS Version

Windows 10 Pro

Additional system information

Path building mixes back slashes and forward slashes, creating a mess that Windows/Python chokes on.

Post-processing script "C:\Users\Eric\AppData\Local\Python\bin\python.exe"
"F:\Bricklayers-main\bricklayers_my.py" on file
C:\Users\Eric\AppData\Local\Temp/snapmaker_orca_model/Tue_Aug_25/23_25_58#31824#3047/M
etadata.31824.10.gcode.pp failed.
Error code: 1

Note how the Temp file path starts with backslashes, switches to forward slashes, then reverts to one last backslash at the very end.

This works correctly in vanilla Orcaslicer, and has for well over a year.

Printer

Snapmaker U1

How to reproduce

  1. Make a basic python post processing script that accepts a path from the slicer (go use the Bricklayers script from github, for a quick one)

  2. Add script to post-processing

  3. Slice

  4. Attempt to PRINT or SAVE AS GCODE file.

  5. See error similar to mine, with mangled temp path.

Actual results

Image

Expected results

Proper formation of path to temp file, and successful processing of gcode, which is then uploaded or saved.

Project file & Debug log uploads

This is not project specific

Checklist of files to include

  • Log file
  • Project file

Anything else?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions