f3d2solidcraft 0.3.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- f3d2solidcraft-0.3.0/.github/workflows/ci.yml +171 -0
- f3d2solidcraft-0.3.0/.github/workflows/release.yml +152 -0
- f3d2solidcraft-0.3.0/CHANGELOG.md +20 -0
- f3d2solidcraft-0.3.0/LICENSE +21 -0
- f3d2solidcraft-0.3.0/PKG-INFO +189 -0
- f3d2solidcraft-0.3.0/README.md +160 -0
- f3d2solidcraft-0.3.0/docs/guia.md +173 -0
- f3d2solidcraft-0.3.0/pyproject.toml +88 -0
- f3d2solidcraft-0.3.0/scripts/fetch_cadmpeg.py +81 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/__init__.py +3 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/__main__.py +3 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/_vendor/__init__.py +0 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/_vendor/ezf3d/LICENSE +21 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/_vendor/ezf3d/__init__.py +1 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/_vendor/ezf3d/container/__init__.py +1 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/_vendor/ezf3d/container/archive.py +204 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/_vendor/ezf3d/model/__init__.py +1 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/_vendor/ezf3d/model/parameters.py +365 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/_vendor/ezf3d/model/sketch.py +645 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/_vendor/ezf3d/model/timeline.py +493 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/_vendor/ezf3d/streams/__init__.py +1 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/_vendor/ezf3d/streams/manifest.py +262 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/_vendor/ezf3d/streams/primitives.py +191 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/_vendor/ezf3d/streams/segment.py +521 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/cli.py +574 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/engine.py +458 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/fallback.py +250 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/geometry.py +397 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/mappers/__init__.py +141 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/mappers/bodies.py +99 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/mappers/combine.py +73 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/mappers/components.py +542 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/mappers/edges.py +449 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/mappers/extrude.py +1501 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/mappers/faces.py +50 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/mappers/loft.py +149 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/mappers/outputs.py +73 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/mappers/params.py +134 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/mappers/pattern.py +68 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/mappers/planes.py +222 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/mappers/primitives.py +144 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/mappers/records.py +51 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/mappers/revolve.py +134 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/mappers/sheet.py +95 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/mappers/shell.py +180 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/mappers/sketch.py +455 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/mcp.py +218 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/model.py +503 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/oracle.py +905 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/pairing.py +105 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/reader/__init__.py +77 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/reader/cadir.py +832 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/reader/fusion.py +218 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/reader/locale.py +115 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/replay.py +322 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/report.py +107 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/tools.py +219 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/verify.py +186 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft/visibility.py +95 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft_app/__init__.py +5 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft_app/__main__.py +40 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft_app/engines.py +158 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft_app/events.py +35 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft_app/opener.py +22 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft_app/outcome.py +54 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft_app/resources/icon-128.png +0 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft_app/resources/icon-16.png +0 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft_app/resources/icon-256.png +0 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft_app/resources/icon-32.png +0 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft_app/resources/icon-512.png +0 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft_app/resources/icon-64.png +0 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft_app/resources/icon.icns +0 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft_app/resources/icon.ico +0 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft_app/resources/icon.svg +26 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft_app/runner.py +91 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft_app/texts.py +98 -0
- f3d2solidcraft-0.3.0/src/f3d2solidcraft_app/window.py +677 -0
- f3d2solidcraft-0.3.0/tests/app/__init__.py +0 -0
- f3d2solidcraft-0.3.0/tests/app/conftest.py +4 -0
- f3d2solidcraft-0.3.0/tests/app/test_engines_runner.py +228 -0
- f3d2solidcraft-0.3.0/tests/app/test_events_outcome.py +109 -0
- f3d2solidcraft-0.3.0/tests/app/test_icon.py +22 -0
- f3d2solidcraft-0.3.0/tests/app/test_opener.py +19 -0
- f3d2solidcraft-0.3.0/tests/app/test_packaging.py +28 -0
- f3d2solidcraft-0.3.0/tests/app/test_texts.py +25 -0
- f3d2solidcraft-0.3.0/tests/app/test_window.py +570 -0
- f3d2solidcraft-0.3.0/tests/conftest.py +203 -0
- f3d2solidcraft-0.3.0/tests/test_bench.py +81 -0
- f3d2solidcraft-0.3.0/tests/test_bezier_spans.py +57 -0
- f3d2solidcraft-0.3.0/tests/test_bodies.py +36 -0
- f3d2solidcraft-0.3.0/tests/test_cli.py +280 -0
- f3d2solidcraft-0.3.0/tests/test_combine.py +130 -0
- f3d2solidcraft-0.3.0/tests/test_components.py +329 -0
- f3d2solidcraft-0.3.0/tests/test_condemnation.py +54 -0
- f3d2solidcraft-0.3.0/tests/test_conics.py +51 -0
- f3d2solidcraft-0.3.0/tests/test_declared_edges.py +189 -0
- f3d2solidcraft-0.3.0/tests/test_engine.py +121 -0
- f3d2solidcraft-0.3.0/tests/test_extents.py +50 -0
- f3d2solidcraft-0.3.0/tests/test_faces.py +81 -0
- f3d2solidcraft-0.3.0/tests/test_geometry.py +143 -0
- f3d2solidcraft-0.3.0/tests/test_inspect_json.py +12 -0
- f3d2solidcraft-0.3.0/tests/test_locations.py +71 -0
- f3d2solidcraft-0.3.0/tests/test_loft.py +186 -0
- f3d2solidcraft-0.3.0/tests/test_mappers.py +300 -0
- f3d2solidcraft-0.3.0/tests/test_mcp.py +136 -0
- f3d2solidcraft-0.3.0/tests/test_naming.py +55 -0
- f3d2solidcraft-0.3.0/tests/test_oracle.py +713 -0
- f3d2solidcraft-0.3.0/tests/test_pairing.py +47 -0
- f3d2solidcraft-0.3.0/tests/test_partial_sketches.py +81 -0
- f3d2solidcraft-0.3.0/tests/test_pattern.py +90 -0
- f3d2solidcraft-0.3.0/tests/test_primitives.py +32 -0
- f3d2solidcraft-0.3.0/tests/test_progress.py +69 -0
- f3d2solidcraft-0.3.0/tests/test_reader.py +361 -0
- f3d2solidcraft-0.3.0/tests/test_replay.py +157 -0
- f3d2solidcraft-0.3.0/tests/test_revolve.py +283 -0
- f3d2solidcraft-0.3.0/tests/test_rollback.py +103 -0
- f3d2solidcraft-0.3.0/tests/test_sheet.py +106 -0
- f3d2solidcraft-0.3.0/tests/test_shell.py +130 -0
- f3d2solidcraft-0.3.0/tests/test_tilted_planes.py +79 -0
- f3d2solidcraft-0.3.0/tests/test_tools.py +181 -0
- f3d2solidcraft-0.3.0/tests/test_trimmed_region.py +240 -0
- f3d2solidcraft-0.3.0/tests/test_unmeasurable.py +74 -0
- f3d2solidcraft-0.3.0/tests/test_unnamed_sketches.py +44 -0
- f3d2solidcraft-0.3.0/tests/test_verify.py +251 -0
- f3d2solidcraft-0.3.0/tests/test_visibility.py +96 -0
|
@@ -0,0 +1,171 @@
|
|
|
1
|
+
name: ci
|
|
2
|
+
# GitHub-hosted runners only. This repository is public, so a pull request from a fork must never
|
|
3
|
+
# reach a machine of ours: no self-hosted runner here.
|
|
4
|
+
#
|
|
5
|
+
# The suite needs the two engines the converter drives, installed as the release publishes them and
|
|
6
|
+
# checked against the sha256 it publishes beside them, and the public sample from
|
|
7
|
+
# tangency-labs/solidcraft#2346, and the author's three public designs. Tests that need a design which
|
|
8
|
+
# is not public skip.
|
|
9
|
+
on:
|
|
10
|
+
push:
|
|
11
|
+
branches: [main]
|
|
12
|
+
pull_request:
|
|
13
|
+
permissions:
|
|
14
|
+
contents: read
|
|
15
|
+
jobs:
|
|
16
|
+
test:
|
|
17
|
+
runs-on: ${{ matrix.os }}
|
|
18
|
+
strategy:
|
|
19
|
+
fail-fast: false
|
|
20
|
+
matrix:
|
|
21
|
+
os: [ubuntu-latest, windows-latest, macos-latest]
|
|
22
|
+
python: ["3.13", "3.14"]
|
|
23
|
+
env:
|
|
24
|
+
SOLIDCRAFT: "0.43.0"
|
|
25
|
+
CADMPEG: "0.6.11"
|
|
26
|
+
SAMPLE_URL: https://github.com/user-attachments/files/33617507/test.weird.box_f3d.zip
|
|
27
|
+
defaults:
|
|
28
|
+
run:
|
|
29
|
+
shell: bash
|
|
30
|
+
steps:
|
|
31
|
+
- uses: actions/checkout@v4
|
|
32
|
+
- uses: astral-sh/setup-uv@v6
|
|
33
|
+
with:
|
|
34
|
+
python-version: ${{ matrix.python }}
|
|
35
|
+
|
|
36
|
+
- name: Engines (Linux)
|
|
37
|
+
if: runner.os == 'Linux'
|
|
38
|
+
run: |
|
|
39
|
+
set -euo pipefail
|
|
40
|
+
bin="$RUNNER_TEMP/bin"; mkdir -p "$bin"; echo "$bin" >> "$GITHUB_PATH"; tmp=$(mktemp -d)
|
|
41
|
+
base="cadmpeg-x86_64-unknown-linux-gnu.tar.xz"
|
|
42
|
+
url="https://github.com/cadmpeg/cadmpeg/releases/download/v$CADMPEG"
|
|
43
|
+
curl -fsSL -o "$tmp/$base" "$url/$base"; curl -fsSL -o "$tmp/$base.sha256" "$url/$base.sha256"
|
|
44
|
+
( cd "$tmp" && sha256sum -c "$base.sha256" )
|
|
45
|
+
tar -xJf "$tmp/$base" -C "$tmp"
|
|
46
|
+
find "$tmp" -name cadmpeg -type f -perm -u+x -exec install -m 755 {} "$bin/cadmpeg" \;
|
|
47
|
+
tarball="solidcraft-$SOLIDCRAFT-linux-x86_64.tar.gz"
|
|
48
|
+
url="https://github.com/tangency-labs/solidcraft/releases/download/v$SOLIDCRAFT"
|
|
49
|
+
curl -fsSL -o "$tmp/$tarball" "$url/$tarball"; curl -fsSL -o "$tmp/SHA256SUMS.txt" "$url/SHA256SUMS.txt"
|
|
50
|
+
( cd "$tmp" && grep " $tarball\$" SHA256SUMS.txt | sha256sum -c - )
|
|
51
|
+
tar -xzf "$tmp/$tarball" -C "$tmp" --strip-components=2 "solidcraft-$SOLIDCRAFT-linux-x86_64/bin/solidcraft-cli"
|
|
52
|
+
install -m 755 "$tmp/solidcraft-cli" "$bin/solidcraft-cli"
|
|
53
|
+
"$bin/cadmpeg" --version; "$bin/solidcraft-cli" --version
|
|
54
|
+
|
|
55
|
+
- name: Engines (macOS)
|
|
56
|
+
if: runner.os == 'macOS'
|
|
57
|
+
run: |
|
|
58
|
+
set -euo pipefail
|
|
59
|
+
bin="$RUNNER_TEMP/bin"; mkdir -p "$bin"; echo "$bin" >> "$GITHUB_PATH"; tmp=$(mktemp -d)
|
|
60
|
+
arch=$(uname -m); [ "$arch" = "arm64" ] && arch=aarch64
|
|
61
|
+
base="cadmpeg-$arch-apple-darwin.tar.xz"
|
|
62
|
+
url="https://github.com/cadmpeg/cadmpeg/releases/download/v$CADMPEG"
|
|
63
|
+
curl -fsSL -o "$tmp/$base" "$url/$base"; curl -fsSL -o "$tmp/$base.sha256" "$url/$base.sha256"
|
|
64
|
+
( cd "$tmp" && shasum -a 256 -c "$base.sha256" )
|
|
65
|
+
tar -xJf "$tmp/$base" -C "$tmp"
|
|
66
|
+
find "$tmp" -name cadmpeg -type f -perm -u+x -exec install -m 755 {} "$bin/cadmpeg" \;
|
|
67
|
+
zip="solidcraft-cli-$SOLIDCRAFT-macos-universal.zip"
|
|
68
|
+
url="https://github.com/tangency-labs/solidcraft/releases/download/v$SOLIDCRAFT"
|
|
69
|
+
curl -fsSL -o "$tmp/$zip" "$url/$zip"; curl -fsSL -o "$tmp/SHA256SUMS.txt" "$url/SHA256SUMS.txt"
|
|
70
|
+
( cd "$tmp" && grep " $zip\$" SHA256SUMS.txt | shasum -a 256 -c - )
|
|
71
|
+
unzip -q "$tmp/$zip" -d "$tmp"
|
|
72
|
+
install -m 755 "$tmp/solidcraft-cli-$SOLIDCRAFT-macos-universal/solidcraft-cli" "$bin/solidcraft-cli"
|
|
73
|
+
"$bin/cadmpeg" --version; "$bin/solidcraft-cli" --version
|
|
74
|
+
|
|
75
|
+
- name: Engines (Windows)
|
|
76
|
+
if: runner.os == 'Windows'
|
|
77
|
+
run: |
|
|
78
|
+
set -euo pipefail
|
|
79
|
+
bin="$RUNNER_TEMP/bin"; mkdir -p "$bin"; echo "$bin" >> "$GITHUB_PATH"; tmp=$(mktemp -d)
|
|
80
|
+
base="cadmpeg-x86_64-pc-windows-msvc.zip"
|
|
81
|
+
url="https://github.com/cadmpeg/cadmpeg/releases/download/v$CADMPEG"
|
|
82
|
+
curl -fsSL -o "$tmp/$base" "$url/$base"; curl -fsSL -o "$tmp/$base.sha256" "$url/$base.sha256"
|
|
83
|
+
( cd "$tmp" && sha256sum -c "$base.sha256" )
|
|
84
|
+
unzip -q "$tmp/$base" -d "$tmp/cadmpeg"
|
|
85
|
+
find "$tmp/cadmpeg" -name cadmpeg.exe -exec cp {} "$bin/cadmpeg.exe" \;
|
|
86
|
+
zip="solidcraft-$SOLIDCRAFT-windows-x64-portable.zip"
|
|
87
|
+
url="https://github.com/tangency-labs/solidcraft/releases/download/v$SOLIDCRAFT"
|
|
88
|
+
curl -fsSL -o "$tmp/$zip" "$url/$zip"; curl -fsSL -o "$tmp/SHA256SUMS.txt" "$url/SHA256SUMS.txt"
|
|
89
|
+
( cd "$tmp" && grep " $zip\$" SHA256SUMS.txt | sha256sum -c - )
|
|
90
|
+
unzip -q "$tmp/$zip" -d "$tmp"
|
|
91
|
+
cp "$tmp/solidcraft-$SOLIDCRAFT-windows-x64-portable/"*.exe "$bin/"
|
|
92
|
+
"$bin/cadmpeg.exe" --version; "$bin/solidcraft-cli.exe" --version
|
|
93
|
+
|
|
94
|
+
- name: Public sample
|
|
95
|
+
run: |
|
|
96
|
+
set -euo pipefail
|
|
97
|
+
dest="$HOME/.f3d2solidcraft/corpus/samples"; mkdir -p "$dest"; tmp=$(mktemp -d)
|
|
98
|
+
curl -fsSL -o "$tmp/sample.zip" "$SAMPLE_URL"
|
|
99
|
+
uv run --no-project python -m zipfile -e "$tmp/sample.zip" "$tmp/out"
|
|
100
|
+
cp "$tmp/out/test weird box.f3d" "$dest/test weird box.f3d"
|
|
101
|
+
|
|
102
|
+
# The author's own designs, public as attachments on cadmpeg/cadmpeg#448 and
|
|
103
|
+
# tangency-labs/solidcraft#13072, checked against the sha256 of the files the suite was measured
|
|
104
|
+
# on: an attachment that changed would make the tests measure something else in silence.
|
|
105
|
+
- name: Public designs
|
|
106
|
+
run: |
|
|
107
|
+
set -euo pipefail
|
|
108
|
+
dest="$HOME/.f3d2solidcraft/corpus/propios"
|
|
109
|
+
mkdir -p "$dest"
|
|
110
|
+
tmp=$(mktemp -d)
|
|
111
|
+
fetch() {
|
|
112
|
+
curl -fsSL -o "$tmp/a.zip" "$1"
|
|
113
|
+
rm -rf "$tmp/out" && uv run --no-project python -m zipfile -e "$tmp/a.zip" "$tmp/out"
|
|
114
|
+
( cd "$tmp/out" && if command -v sha256sum >/dev/null; then echo "$3 *$2" | sha256sum -c -; else echo "$3 *$2" | shasum -a 256 -c -; fi )
|
|
115
|
+
install -m 644 "$tmp/out/$2" "$dest/$2"
|
|
116
|
+
}
|
|
117
|
+
fetch https://github.com/user-attachments/files/34251442/mango.para.lima.f3d.zip \
|
|
118
|
+
"mango para lima.f3d" a90ad67beb03a377ace53baa88b24766fb022017f669eaed2a70405bd80d7284
|
|
119
|
+
fetch https://github.com/user-attachments/files/34251446/Caja.parametrica.v2.f3d.zip \
|
|
120
|
+
"Caja parametrica v2.f3d" 0b872bae7c16a963973a4adfd0ee32340c6789fe41fe864e40375b2bf2876246
|
|
121
|
+
fetch https://github.com/user-attachments/files/34605897/soporte.controles.f3d.zip \
|
|
122
|
+
"soporte controles.f3d" 06e64bd04f2a03f364475ef1910c5199bc9bb17ac183ed4d922b398c52378876
|
|
123
|
+
|
|
124
|
+
# The window's tests need Qt: libraries the runner may lack on Linux, and the `gui-dev` group on every
|
|
125
|
+
# system. Without them `tests/app/test_window.py` would skip itself green (`importorskip`), so every
|
|
126
|
+
# `uv` call here names the group (a plain `uv run` syncs it away) and a step proves Qt starts.
|
|
127
|
+
# Measured on bare ubuntu 22.04 and 24.04 images: with this list nothing PySide6 6.12's QtCore,
|
|
128
|
+
# QtGui, QtWidgets, QtDBus and the offscreen plugin link against is missing. libegl1, libgl1 (QtGui
|
|
129
|
+
# links both), libfontconfig1 (brings libfreetype6), libglib2.0-0 (QtCore), libdbus-1-3 (QtDBus,
|
|
130
|
+
# QtGui), libxkbcommon0; libxkbcommon-x11-0 is for the xcb plugin, which the app uses on a desktop.
|
|
131
|
+
- name: What Qt needs on a runner without a screen
|
|
132
|
+
if: runner.os == 'Linux'
|
|
133
|
+
run: |
|
|
134
|
+
sudo apt-get update
|
|
135
|
+
sudo apt-get install -y libegl1 libxkbcommon0 libxkbcommon-x11-0 libgl1 libfontconfig1 libglib2.0-0 libdbus-1-3
|
|
136
|
+
- run: uv sync --group gui-dev
|
|
137
|
+
- name: Qt starts offscreen
|
|
138
|
+
env:
|
|
139
|
+
QT_QPA_PLATFORM: offscreen
|
|
140
|
+
run: uv run --group gui-dev python -c "import pytestqt; from PySide6.QtWidgets import QApplication; print('Qt', QApplication([]).platformName())"
|
|
141
|
+
- run: uv run --group gui-dev ruff check
|
|
142
|
+
- run: uv run --group gui-dev ruff format --check
|
|
143
|
+
- name: Tests
|
|
144
|
+
env:
|
|
145
|
+
F3D2SC_REQUIRE_INTEGRATION: "1"
|
|
146
|
+
QT_QPA_PLATFORM: offscreen
|
|
147
|
+
run: uv run --group gui-dev pytest -v
|
|
148
|
+
|
|
149
|
+
probe-windows-msi:
|
|
150
|
+
runs-on: windows-latest
|
|
151
|
+
steps:
|
|
152
|
+
- name: Install SolidCraft from its .msi and show where solidcraft-cli.exe lands
|
|
153
|
+
shell: pwsh
|
|
154
|
+
run: |
|
|
155
|
+
$v = "0.43.0"
|
|
156
|
+
$msi = "solidcraft-$v-windows-x64.msi"
|
|
157
|
+
$url = "https://github.com/tangency-labs/solidcraft/releases/download/v$v"
|
|
158
|
+
Invoke-WebRequest "$url/$msi" -OutFile $msi
|
|
159
|
+
Invoke-WebRequest "$url/SHA256SUMS.txt" -OutFile SHA256SUMS.txt
|
|
160
|
+
$line = Get-Content SHA256SUMS.txt | Where-Object { $_ -match "\s\*?$([regex]::Escape($msi))$" } | Select-Object -First 1
|
|
161
|
+
if (-not $line) { throw "$msi is not listed in SHA256SUMS.txt" }
|
|
162
|
+
$expected = ($line -split '\s+')[0]
|
|
163
|
+
$actual = (Get-FileHash -Algorithm SHA256 $msi).Hash
|
|
164
|
+
if ($actual -ine $expected) { throw "sha256 mismatch for ${msi}: expected $expected, got $actual" }
|
|
165
|
+
Write-Host "sha256 OK: $actual"
|
|
166
|
+
$msiPath = (Resolve-Path $msi).Path
|
|
167
|
+
$p = Start-Process msiexec.exe -Wait -PassThru -ArgumentList "/i", "`"$msiPath`"", "/qn"
|
|
168
|
+
if ($p.ExitCode -ne 0) { throw "msiexec failed with exit code $($p.ExitCode)" }
|
|
169
|
+
$found = Get-ChildItem -Path $env:ProgramFiles, ${env:ProgramFiles(x86)}, $env:LOCALAPPDATA -Recurse -Filter solidcraft-cli.exe -ErrorAction SilentlyContinue
|
|
170
|
+
if (-not $found) { throw "solidcraft-cli.exe not found after installing $msi" }
|
|
171
|
+
$found | Select-Object FullName
|
|
@@ -0,0 +1,152 @@
|
|
|
1
|
+
name: release
|
|
2
|
+
# A tag `vX.Y.Z` publishes that version to PyPI and attaches the three desktop installers to its GitHub
|
|
3
|
+
# release.
|
|
4
|
+
#
|
|
5
|
+
# Run by hand (Actions -> release -> Run workflow), it is a rehearsal that publishes nothing: it builds
|
|
6
|
+
# and checks the package and builds the three desktop installers, kept only as downloadable workflow
|
|
7
|
+
# artifacts (dist, installer-windows, installer-macOS, installer-linux). It touches no GitHub release and
|
|
8
|
+
# no PyPI, even when started from a tag. Ticking the `testpypi` box on that run also uploads the package
|
|
9
|
+
# to TestPyPI; it is off unless ticked.
|
|
10
|
+
#
|
|
11
|
+
# Publishing uses PyPI's Trusted Publishing (OIDC): no token is stored anywhere. Each index has to be
|
|
12
|
+
# told once to trust this repository's `release.yml` and the environment named below.
|
|
13
|
+
on:
|
|
14
|
+
push:
|
|
15
|
+
tags: ["v*"]
|
|
16
|
+
workflow_dispatch:
|
|
17
|
+
inputs:
|
|
18
|
+
testpypi:
|
|
19
|
+
description: "Also upload the package to TestPyPI"
|
|
20
|
+
type: boolean
|
|
21
|
+
default: false
|
|
22
|
+
permissions:
|
|
23
|
+
contents: read
|
|
24
|
+
jobs:
|
|
25
|
+
build:
|
|
26
|
+
runs-on: ubuntu-latest
|
|
27
|
+
steps:
|
|
28
|
+
- uses: actions/checkout@v4
|
|
29
|
+
- uses: astral-sh/setup-uv@v6
|
|
30
|
+
with:
|
|
31
|
+
python-version: "3.13"
|
|
32
|
+
- name: The tag is the version
|
|
33
|
+
if: startsWith(github.ref, 'refs/tags/v')
|
|
34
|
+
run: |
|
|
35
|
+
set -euo pipefail
|
|
36
|
+
version=$(python3 -c "import re,sys; print(re.search(r'__version__ = \"([^\"]+)\"', open('src/f3d2solidcraft/__init__.py').read()).group(1))")
|
|
37
|
+
test "v$version" = "$GITHUB_REF_NAME" || { echo "tag $GITHUB_REF_NAME is not version $version"; exit 1; }
|
|
38
|
+
- run: uv build
|
|
39
|
+
- name: Metadata
|
|
40
|
+
run: uvx twine check --strict dist/*
|
|
41
|
+
- name: The wheel installs and runs on its own
|
|
42
|
+
run: |
|
|
43
|
+
set -euo pipefail
|
|
44
|
+
uv venv /tmp/smoke
|
|
45
|
+
uv pip install --python /tmp/smoke/bin/python dist/*.whl
|
|
46
|
+
/tmp/smoke/bin/f3d2solidcraft --help
|
|
47
|
+
/tmp/smoke/bin/python -c "import f3d2solidcraft; print(f3d2solidcraft.__version__)"
|
|
48
|
+
- uses: actions/upload-artifact@v4
|
|
49
|
+
with:
|
|
50
|
+
name: dist
|
|
51
|
+
path: dist/
|
|
52
|
+
|
|
53
|
+
testpypi:
|
|
54
|
+
if: github.event_name == 'workflow_dispatch' && inputs.testpypi # a manual run publishes nothing unless asked
|
|
55
|
+
needs: build
|
|
56
|
+
runs-on: ubuntu-latest
|
|
57
|
+
environment: testpypi
|
|
58
|
+
permissions:
|
|
59
|
+
id-token: write
|
|
60
|
+
steps:
|
|
61
|
+
- uses: actions/download-artifact@v4
|
|
62
|
+
with:
|
|
63
|
+
name: dist
|
|
64
|
+
path: dist/
|
|
65
|
+
- uses: pypa/gh-action-pypi-publish@release/v1
|
|
66
|
+
with:
|
|
67
|
+
repository-url: https://test.pypi.org/legacy/
|
|
68
|
+
|
|
69
|
+
pypi:
|
|
70
|
+
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v') # a dispatch, even from a tag, never publishes
|
|
71
|
+
needs: build
|
|
72
|
+
runs-on: ubuntu-latest
|
|
73
|
+
environment: pypi
|
|
74
|
+
permissions:
|
|
75
|
+
id-token: write
|
|
76
|
+
steps:
|
|
77
|
+
- uses: actions/download-artifact@v4
|
|
78
|
+
with:
|
|
79
|
+
name: dist
|
|
80
|
+
path: dist/
|
|
81
|
+
- uses: pypa/gh-action-pypi-publish@release/v1
|
|
82
|
+
|
|
83
|
+
# The desktop app, packaged by Briefcase on each system, attached to the tag's GitHub release. Briefcase
|
|
84
|
+
# is pinned to the version these steps were measured with. Each leg puts a cadmpeg checked against its
|
|
85
|
+
# pinned sha256 inside the app first (on macOS a universal one, joined with `lipo`).
|
|
86
|
+
#
|
|
87
|
+
# Linux, measured in an ubuntu:22.04 x86_64 container (the runner below): Briefcase 0.4.7's AppImage
|
|
88
|
+
# template (branch v0.4.7, also v0.4.5 and v0.4.6) renders `cookiecutter.host_arch` without declaring
|
|
89
|
+
# it in its cookiecutter.json, so cookiecutter drops the value Briefcase passes and `create` stops on
|
|
90
|
+
# "'collections.OrderedDict object' has no attribute 'host_arch'". The v0.4.4 template predates that
|
|
91
|
+
# line; with it the AppImage builds, and it opens, answers `--check` and runs `--worker` on ubuntu
|
|
92
|
+
# 22.04 and 24.04. `--no-docker` builds on the runner itself: PySide6 6.12 ships only manylinux_2_34
|
|
93
|
+
# wheels, which ubuntu 22.04 (glibc 2.35) installs, so a Docker manylinux image would not make the
|
|
94
|
+
# AppImage reach older systems anyway. The apt step gives linuxdeploy the libraries Qt links against,
|
|
95
|
+
# so it can copy into the AppImage the ones a desktop may lack: without libxcb-cursor0 (and the three
|
|
96
|
+
# xcb libraries linuxdeploy stops on before it, icccm, keysyms and shape) on the build machine, the
|
|
97
|
+
# AppImage measured under Xvfb on a fresh ubuntu 22.04 aborted with "From 6.5.0, xcb-cursor0 or
|
|
98
|
+
# libxcb-cursor0 is needed to load the Qt xcb platform plugin".
|
|
99
|
+
#
|
|
100
|
+
# Run by hand, this job is the installers' rehearsal: it builds them and uploads them as workflow
|
|
101
|
+
# artifacts, and the release step below is skipped. A tag does both.
|
|
102
|
+
installers:
|
|
103
|
+
if: startsWith(github.ref, 'refs/tags/v') || github.event_name == 'workflow_dispatch'
|
|
104
|
+
needs: build
|
|
105
|
+
runs-on: ${{ matrix.os }}
|
|
106
|
+
strategy:
|
|
107
|
+
fail-fast: false
|
|
108
|
+
matrix:
|
|
109
|
+
include:
|
|
110
|
+
- os: windows-latest
|
|
111
|
+
platform: windows
|
|
112
|
+
format: ""
|
|
113
|
+
flags: ""
|
|
114
|
+
- os: macos-latest
|
|
115
|
+
platform: macOS
|
|
116
|
+
format: ""
|
|
117
|
+
flags: ""
|
|
118
|
+
- os: ubuntu-22.04
|
|
119
|
+
platform: linux
|
|
120
|
+
format: appimage
|
|
121
|
+
flags: --no-docker -C 'template_branch="v0.4.4"'
|
|
122
|
+
# `write` is only used by the release step, which runs on tags alone. A job's permissions cannot depend
|
|
123
|
+
# on the event, so a hand run gets it too; it uploads artifacts and nothing else.
|
|
124
|
+
permissions:
|
|
125
|
+
contents: write
|
|
126
|
+
defaults:
|
|
127
|
+
run:
|
|
128
|
+
shell: bash
|
|
129
|
+
steps:
|
|
130
|
+
- uses: actions/checkout@v4
|
|
131
|
+
- uses: astral-sh/setup-uv@v6
|
|
132
|
+
with:
|
|
133
|
+
python-version: "3.13"
|
|
134
|
+
- name: What Qt links against, for linuxdeploy to find
|
|
135
|
+
if: runner.os == 'Linux'
|
|
136
|
+
run: |
|
|
137
|
+
sudo apt-get update
|
|
138
|
+
sudo apt-get install -y libegl1 libxkbcommon0 libxkbcommon-x11-0 libgl1 libfontconfig1 libglib2.0-0 libdbus-1-3 \
|
|
139
|
+
libxcb-cursor0 libxcb-icccm4 libxcb-keysyms1 libxcb-shape0
|
|
140
|
+
- run: uv run --no-project python scripts/fetch_cadmpeg.py
|
|
141
|
+
- run: uvx briefcase==0.4.7 create ${{ matrix.platform }} ${{ matrix.format }} ${{ matrix.flags }} --no-input
|
|
142
|
+
- run: uvx briefcase==0.4.7 build ${{ matrix.platform }} ${{ matrix.format }} ${{ matrix.flags }} --no-input
|
|
143
|
+
- run: uvx briefcase==0.4.7 package ${{ matrix.platform }} ${{ matrix.format }} ${{ matrix.flags }} ${{ matrix.platform == 'macOS' && '--adhoc-sign' || '' }} --no-input
|
|
144
|
+
- uses: actions/upload-artifact@v4
|
|
145
|
+
with:
|
|
146
|
+
name: installer-${{ matrix.platform }}
|
|
147
|
+
path: dist/*
|
|
148
|
+
if-no-files-found: error
|
|
149
|
+
- if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
|
|
150
|
+
uses: softprops/action-gh-release@v2
|
|
151
|
+
with:
|
|
152
|
+
files: dist/*
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
## 0.3.0 — first public release
|
|
4
|
+
|
|
5
|
+
- A desktop program for Windows, macOS and Linux (`f3d2solidcraft[gui]`, or the installers attached to each
|
|
6
|
+
release): a three-step wizard that converts one file at a time, verifies it and opens the result in SolidCraft.
|
|
7
|
+
It ships its own cadmpeg; only SolidCraft 0.43.0 or newer has to be installed.
|
|
8
|
+
- `convert --progress` prints one JSON event per feature and a final `done` event; `inspect --json` prints what a
|
|
9
|
+
file holds as JSON.
|
|
10
|
+
- A part placed more than once keeps every placement. If the saved design ever holds fewer placements than were
|
|
11
|
+
measured, the verification fails (`placements_lost`, exit code 2) instead of passing.
|
|
12
|
+
|
|
13
|
+
- Converts Fusion `.f3d` designs and `.f3z` packages into SolidCraft designs: parameters, sketches and a feature
|
|
14
|
+
timeline, with whatever cannot be rebuilt brought in as imported bodies.
|
|
15
|
+
- Every conversion is verified against the original (bodies, volume, bounding box, centre of mass, face count) and
|
|
16
|
+
reported feature by feature as `exact`, `inferred`, `fallback`, `failed` or `skipped`.
|
|
17
|
+
- Choices the Fusion file does not record (an extrude's profiles, a fillet's edges) are measured against the
|
|
18
|
+
original solid and reported as `inferred`.
|
|
19
|
+
- `inspect` to see what a file holds; `convert` to convert it; `mcp` to serve both over MCP.
|
|
20
|
+
- Requires SolidCraft 0.43.0 or newer and cadmpeg 0.6.11 or newer. Python 3.13 and 3.14.
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Cristián Carter (Mitocondria)
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -0,0 +1,189 @@
|
|
|
1
|
+
Metadata-Version: 2.5
|
|
2
|
+
Name: f3d2solidcraft
|
|
3
|
+
Version: 0.3.0
|
|
4
|
+
Summary: Convert Autodesk Fusion .f3d/.f3z designs into editable SolidCraft designs
|
|
5
|
+
Project-URL: Homepage, https://github.com/cristiancarterm/f3d2solidcraft
|
|
6
|
+
Project-URL: Issues, https://github.com/cristiancarterm/f3d2solidcraft/issues
|
|
7
|
+
Author-email: Cristián Carter <cristian@mitocondria.cl>
|
|
8
|
+
License-Expression: MIT
|
|
9
|
+
License-File: LICENSE
|
|
10
|
+
License-File: src/f3d2solidcraft/_vendor/ezf3d/LICENSE
|
|
11
|
+
Keywords: cad,converter,f3d,fusion,fusion360,solidcraft,step
|
|
12
|
+
Classifier: Development Status :: 3 - Alpha
|
|
13
|
+
Classifier: Environment :: Console
|
|
14
|
+
Classifier: Intended Audience :: Developers
|
|
15
|
+
Classifier: Intended Audience :: Manufacturing
|
|
16
|
+
Classifier: Operating System :: MacOS
|
|
17
|
+
Classifier: Operating System :: POSIX :: Linux
|
|
18
|
+
Classifier: Programming Language :: Python :: 3
|
|
19
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
20
|
+
Classifier: Programming Language :: Python :: 3.14
|
|
21
|
+
Classifier: Topic :: Multimedia :: Graphics :: 3D Modeling
|
|
22
|
+
Classifier: Topic :: Scientific/Engineering
|
|
23
|
+
Classifier: Topic :: Utilities
|
|
24
|
+
Requires-Python: >=3.13
|
|
25
|
+
Requires-Dist: zstandard>=0.22
|
|
26
|
+
Provides-Extra: gui
|
|
27
|
+
Requires-Dist: pyside6-essentials>=6.8; extra == 'gui'
|
|
28
|
+
Description-Content-Type: text/markdown
|
|
29
|
+
|
|
30
|
+
# f3d2solidcraft
|
|
31
|
+
|
|
32
|
+
Convert Autodesk Fusion designs (`.f3d` and `.f3z`) into editable [SolidCraft](https://github.com/tangency-labs/solidcraft)
|
|
33
|
+
designs. Parameters, sketches and features are rebuilt as a SolidCraft timeline you can keep editing; whatever cannot
|
|
34
|
+
be rebuilt yet comes in as an imported body, and a report says, feature by feature, which was which.
|
|
35
|
+
|
|
36
|
+
Every conversion is checked against the original before you get it: same bodies, same volume (within 0.1 %), same
|
|
37
|
+
bounding box and centre of mass (within 0.01 mm), same face count.
|
|
38
|
+
|
|
39
|
+
*Guía en español: [docs/guia.md](docs/guia.md).*
|
|
40
|
+
|
|
41
|
+
## Status
|
|
42
|
+
|
|
43
|
+
Early, and honest about it. On the corpus of 15 real designs it is developed against:
|
|
44
|
+
|
|
45
|
+
- **every conversion verifies** — the part you get is the part you had;
|
|
46
|
+
- **about half of the features are rebuilt as editable SolidCraft features** (139 rebuilt from what the file says,
|
|
47
|
+
15 rebuilt with a choice measured against the original); the rest come in as imported bodies;
|
|
48
|
+
- one design comes out entirely native, with nothing imported.
|
|
49
|
+
|
|
50
|
+
What is rebuilt today: parameters; sketches (lines, arcs, circles and splines, with the common constraints and
|
|
51
|
+
dimensions); extrudes (new body, join, cut, intersect; to a distance, through all, or to a face); revolves; lofts;
|
|
52
|
+
fillets and chamfers; shells; combines; mirrors and patterns where the file resolves them; split, remove and copy
|
|
53
|
+
body; sheet-metal base flanges; primitives; datum planes and axes; and the component tree with each component's
|
|
54
|
+
placement.
|
|
55
|
+
|
|
56
|
+
What is not, and why it falls back: features the file stores only as an opaque recipe (base features, some
|
|
57
|
+
`Assemble`, `Thread`, `Delete Face`), features whose faces the file does not record (`Offset Faces`), and a few the
|
|
58
|
+
SolidCraft kernel cannot build yet. Those come in as imported bodies, and the report names each one and its reason.
|
|
59
|
+
|
|
60
|
+
## Requirements
|
|
61
|
+
|
|
62
|
+
- Python 3.13 or newer.
|
|
63
|
+
- [SolidCraft](https://github.com/tangency-labs/solidcraft/releases) **0.43.0** or newer — the converter drives its
|
|
64
|
+
`solidcraft-cli`. On macOS it is inside the app (`/Applications/SolidCraft.app/Contents/MacOS/solidcraft-cli`); on
|
|
65
|
+
Linux it ships in the release tarball, under `bin/`.
|
|
66
|
+
- [cadmpeg](https://github.com/cadmpeg/cadmpeg/releases) **0.6.11** or newer — it reads the Fusion file. Prebuilt
|
|
67
|
+
binaries are on its releases page, or `cargo install cadmpeg --version 0.6.11 --locked`.
|
|
68
|
+
|
|
69
|
+
Both are found on your `PATH`, at `~/.local/bin/solidcraft-cli` and `~/.cargo/bin/cadmpeg`, or wherever
|
|
70
|
+
`F3D2SC_SOLIDCRAFT_CLI` and `F3D2SC_CADMPEG` point. If one is missing, the error says where it looked.
|
|
71
|
+
|
|
72
|
+
Tested on macOS and Linux. Windows is untested.
|
|
73
|
+
|
|
74
|
+
## Install
|
|
75
|
+
|
|
76
|
+
```bash
|
|
77
|
+
uv tool install f3d2solidcraft
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
or `pipx install f3d2solidcraft`, or `pip install f3d2solidcraft` into an environment of your own.
|
|
81
|
+
|
|
82
|
+
## Desktop app
|
|
83
|
+
|
|
84
|
+
If you would rather not use a terminal, there is a desktop program that walks you through a conversion. Download
|
|
85
|
+
its installer from the assets of a release on [the Releases page](https://github.com/cristiancarterm/f3d2solidcraft/releases):
|
|
86
|
+
|
|
87
|
+
- **macOS**: `.dmg`, universal (Apple silicon and Intel), macOS 14 or newer. It is about 220 MB.
|
|
88
|
+
- **Windows**: `.msi`. Not tested on Windows yet.
|
|
89
|
+
- **Linux**: `.AppImage`, x86_64, for systems with glibc 2.35 or newer (Ubuntu 22.04 and later). Tested on fresh
|
|
90
|
+
Ubuntu 22.04 and 24.04.
|
|
91
|
+
|
|
92
|
+
The program brings its own cadmpeg and does not need Python. You only need
|
|
93
|
+
[SolidCraft](https://github.com/tangency-labs/solidcraft/releases) **0.43.0** or newer installed. The program looks
|
|
94
|
+
for its `solidcraft-cli` on your `PATH`, at `~/.local/bin/solidcraft-cli`, and then:
|
|
95
|
+
|
|
96
|
+
- macOS: `/Applications/SolidCraft.app` and `~/Applications/SolidCraft.app`;
|
|
97
|
+
- Windows: the usual install folder of the SolidCraft installer;
|
|
98
|
+
- Linux: `/usr/bin/solidcraft-cli`, where the `.deb` puts it.
|
|
99
|
+
|
|
100
|
+
It uses the first copy it finds that is 0.43.0 or newer. If SolidCraft is somewhere else, click
|
|
101
|
+
**I have it: locate it…** and point to it. **Download SolidCraft** opens SolidCraft's releases page in your browser;
|
|
102
|
+
it is the only link the program opens, and it sends nothing over the internet. Advanced users can set
|
|
103
|
+
`F3D2SC_SOLIDCRAFT_CLI` and `F3D2SC_CADMPEG`; when set, they win over everything else, including a
|
|
104
|
+
location chosen with **I have it: locate it…** and the cadmpeg that comes with the program.
|
|
105
|
+
|
|
106
|
+
### Opening it the first time
|
|
107
|
+
|
|
108
|
+
The installers are not signed by Apple or Microsoft, so the system asks once before opening them:
|
|
109
|
+
|
|
110
|
+
- **macOS**: open the `.dmg` and drag the program to Applications. The first time, right-click it and choose
|
|
111
|
+
**Open**, or go to **System Settings → Privacy & Security** and click **Open Anyway**.
|
|
112
|
+
- **Windows**: when SmartScreen shows its warning, click **More info**, then **Run anyway**.
|
|
113
|
+
- **Linux**: make the file executable and open it:
|
|
114
|
+
|
|
115
|
+
```bash
|
|
116
|
+
chmod +x f3d2solidcraft-*.AppImage
|
|
117
|
+
./f3d2solidcraft-*.AppImage
|
|
118
|
+
```
|
|
119
|
+
|
|
120
|
+
### The three steps
|
|
121
|
+
|
|
122
|
+
1. **① File**: drop a `.f3d` or `.f3z` file, or click **Choose file…**; the program shows what the file holds and
|
|
123
|
+
where it will save the `.solidcraft`.
|
|
124
|
+
2. **② Convert**: a progress bar goes feature by feature; some features are measured against the original, so it
|
|
125
|
+
can take a couple of minutes, and **Cancel** goes back to step ①.
|
|
126
|
+
3. **③ Result**: **✓ Verified** when the part matches the original, an amber warning when it was saved but does
|
|
127
|
+
not fully match, or an error with **Copy details to report it**. In every case you can see the details per
|
|
128
|
+
feature and save the report; when a design was saved, **Open in SolidCraft** opens it.
|
|
129
|
+
|
|
130
|
+
## Use
|
|
131
|
+
|
|
132
|
+
See what a file holds and what would be rebuilt, without converting anything:
|
|
133
|
+
|
|
134
|
+
```bash
|
|
135
|
+
f3d2solidcraft inspect design.f3d
|
|
136
|
+
```
|
|
137
|
+
|
|
138
|
+
Convert it:
|
|
139
|
+
|
|
140
|
+
```bash
|
|
141
|
+
f3d2solidcraft convert design.f3d -o design.solidcraft --report design.report.json
|
|
142
|
+
```
|
|
143
|
+
|
|
144
|
+
```
|
|
145
|
+
design.f3d
|
|
146
|
+
features: 14 exact, 0 inferred, 12 fallback, 0 failed, 0 skipped
|
|
147
|
+
bodies: 3 matched, 0 missing, 0 extra
|
|
148
|
+
bodies: 2 native, 1 imported
|
|
149
|
+
verified: yes
|
|
150
|
+
rebuild: fusion_d11 ok
|
|
151
|
+
```
|
|
152
|
+
|
|
153
|
+
- `exact`: rebuilt from what the file says.
|
|
154
|
+
- `inferred`: rebuilt too, but with a choice the file does not record (which profiles an extrude used, which edges a
|
|
155
|
+
fillet rounded), measured against the original solid. Its warnings say what was chosen and how clearly.
|
|
156
|
+
- `fallback`: not rebuilt; its body comes in as an imported body.
|
|
157
|
+
- `failed`: not rebuilt, with no body to fall back to (a construction plane, for example).
|
|
158
|
+
- `skipped`: suppressed in Fusion.
|
|
159
|
+
- `bodies: N native, M imported`: where the final bodies come from.
|
|
160
|
+
- `rebuild`: the converter changes one parameter and checks that the design still rebuilds.
|
|
161
|
+
|
|
162
|
+
The exit code is `0` when the result matches the original, `2` when it saved a design that differs, and `1` on
|
|
163
|
+
errors. `--report` writes all of the above per feature, with the reason for every fallback, as JSON. `--force`
|
|
164
|
+
overwrites an existing output.
|
|
165
|
+
|
|
166
|
+
### From an AI assistant (MCP)
|
|
167
|
+
|
|
168
|
+
`f3d2solidcraft mcp` serves the converter over MCP on stdio, so an assistant can import a design by asking:
|
|
169
|
+
`import_f3d` converts a file and answers with the counts and whether it verified; `inspect_f3d` lists what a file
|
|
170
|
+
holds. Register it next to SolidCraft's own MCP server:
|
|
171
|
+
|
|
172
|
+
```json
|
|
173
|
+
{"mcpServers": {"f3d2solidcraft": {"command": "f3d2solidcraft", "args": ["mcp"]}}}
|
|
174
|
+
```
|
|
175
|
+
|
|
176
|
+
## How it works
|
|
177
|
+
|
|
178
|
+
cadmpeg decodes the Fusion file into a description of the design: parameters, sketches and each feature's recipe.
|
|
179
|
+
The converter replays that timeline in SolidCraft, one feature at a time. Fusion does not store everything a
|
|
180
|
+
rebuild needs — which sketch profiles an extrude used, which edges a fillet rounded are kept as opaque kernel
|
|
181
|
+
identities — so for those the converter loads the original solid (exported by cadmpeg) into the same SolidCraft
|
|
182
|
+
session as a reference, tries the candidates, measures each one against it, and removes the reference before saving.
|
|
183
|
+
Those features are reported `inferred`, never `exact`.
|
|
184
|
+
|
|
185
|
+
Whatever cannot be rebuilt is brought in from the original B-rep, so the converted design is always the whole part.
|
|
186
|
+
|
|
187
|
+
## License
|
|
188
|
+
|
|
189
|
+
MIT. It includes a vendored copy of [ezf3d](https://github.com/AlexSabaka/ezf3d), also MIT, whose license ships alongside.
|