OCP 8.0.1: BRepCheck_Result.Status() and Bnd_Box.Get() return unbound types
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 48/100
Direzione di ricerca
Start by tracing how the generator binds OCCT return types, especially the collection instantiation gap referenced in #217 and nested structs such as Bnd_Box::Limits. Reproduce the failures with the supplied Python example on OCP 8.0.1, then check both methods after the binding changes. Done when Status() returns its status list and Get() returns the six bounds values.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Two OCCT return types have no binding in OCP 8.0.1, so the methods that return them raise instead of returning. Both worked on 7.9.3.1, where they came back as BRepCheck_ListOfStatus and a 6-tuple.
| Method | OCCT 8 return type | OCP 7.9.3.1 | OCP 8.0.1.1 |
|---|---|---|---|
BRepCheck_Result.Status() |
NCollection_List<BRepCheck_Status> |
BRepCheck_ListOfStatus |
TypeError |
Bnd_Box.Get() |
Bnd_Box::Limits |
(xmin, ymin, zmin, xmax, ymax, zmax) |
TypeError |
from OCP.BRepPrimAPI import BRepPrimAPI_MakeBox
from OCP.BRepCheck import BRepCheck_Analyzer
from OCP.Bnd import Bnd_Box
from OCP.BRepBndLib import BRepBndLib
from OCP.TopExp import TopExp_Explorer
from OCP.TopAbs import TopAbs_FACE
box = BRepPrimAPI_MakeBox(10, 20, 30).Shape()
face = TopExp_Explorer(box, TopAbs_FACE).Current()
BRepCheck_Analyzer(box).Result(face).Status()
bb = Bnd_Box()
BRepBndLib.Add_s(box, bb)
bb.Get()
On cadquery-ocp-novtk==8.0.1.1.0 (macOS arm64, Python 3.13):
TypeError: Unable to convert function return value to a Python type! The signature was
(self: OCP.OCP.BRepCheck.BRepCheck_Result) -> NCollection_List<BRepCheck_Status>
TypeError: Unable to convert function return value to a Python type! The signature was
(self: OCP.OCP.Bnd.Bnd_Box) -> Bnd_Box::Limits
OCP.collections has no list of BRepCheck_Status (the only *Status instantiation is DataMap_AIS_InteractiveObject_AIS_GlobalStatus), and OCP.Bnd has no Limits. These look like the same gap as #217 (an instantiation the generator didn't pick up) and a nested struct that isn't exposed.
The first one costs the most: Status() is the only way to read why BRepCheck_Analyzer rejects a sub-shape, so on 8.0 a checker can say "invalid" but not "self-intersecting wire" or "unclosed shell". The workaround we use in text-to-cad re-runs the per-kind checks (BRepCheck_Shell.Closed()/.Orientation(), BRepCheck_Face.IntersectWires()/.ClassifyWires(), BRepCheck_Wire.Closed()), which return a single BRepCheck_Status and still bind, but it misses whatever those don't cover. For Get(), CornerMin()/CornerMax() give the same numbers.
- Lingua principale
- C++
- Stelle
- 207
- Fork
- 51
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Preparare l'ambiente
Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di CadQuery/OCP
-
Generation steps fails when OPENGL_INCLUDE_DIRS is a listForse già presa @adam-urbanczyk l’ha presa 77 giorni fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 35/100
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 68/100
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 58/100
-
Python 3.14t buildAperta
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
Tutte le issue di CadQuery/OCP
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
qbittorrent/qBittorrent#25121 ·
I maintainer di solito rispondono entro 2 giorni
-
SVT-AV1: Unnecessary size paddingForse già presa @pszemus l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
strukturag/libheif#1945 ·
I maintainer di solito rispondono entro 1 giorno
-
v9.6.0: CMake incorrectly enforces presence of libevdevForse già presa Una pull request collegata a questa issue è aperta o già unita. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 67/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 65/100
mltframework/shotcut#1943 ·
I maintainer di solito rispondono entro 1 giorno
-
Rowan (2017) electron heating gives NaN for beta > beta_max; clip() then sets electrons to kel_minAperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
parthenon-hpc-lab/kharma#213 · 1 commento ·
I maintainer di solito rispondono entro 3 giorni