Printed conditions drop parentheses: a and (b or c) is shown as a and b or c
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 3/5
- Tiempo estimado
- 1-2 días
- Aptitud para principiantes
- 65/100
Línea de trabajo
Start by locating the code that formats or prints constraint conditions in the Go implementation, then trace how the reproduced a and (b or c) expression is rendered in a verdict line. The issue provides a concrete reproduction and expected behavior: preserve parentheses when removing them changes the reading, or keep them as written. Done when the output no longer reads as a and b or c for this condition.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
What happened, and what you expected instead
Verdict lines print the condition without the parentheses it was written with. a and (b or c) is printed as a and b or c, which reads as (a and b) or c.
The verdict itself is correct, so the expression is parsed and evaluated as written. With a = true and b = c = false, the written condition is false, but the printed one would be true. Anyone reading the output, or any tool that consumes it, sees a different condition from the one that was checked.
Expected: parentheses kept wherever omitting them changes the reading, or always kept as written.
Reproduction
# sysml-mcp v0.12.1, MCP tool "validate_instance" (the documented equivalent of %validate) {#sysml-mcp-v0121-mcp-tool-validate\_instance-the-documented-equivalent-of-validate data-source-line="347"}
%validate Parens::q
constraint assert constraint d: violated (a and b or c) [run, witnessed]
summary: object Parens::q: violated [run, witnessed]
parens.sysml:
package Parens {
private import ScalarValues::*;
part q {
attribute a : Boolean = true;
attribute b : Boolean = false;
attribute c : Boolean = false;
assert constraint d { a and (b or c) }
}
}
Version
sysml-mcp v0.12.1 (commit b2f0e9b802a334369da94312c35cefbd8726d3bf), npm @openmbee/sysml-mcp-linux-x64
Surface
Other / not sure
Platform
Linux x86_64
- Lenguaje dominante
- Go
- Estrellas
- 56
- Forks
- 17
- Merge medio
- 12 h 31 min
- PR fusionados (30 d)
- 909
Preparar el entorno
- Incluye un Dockerfile o un archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de Open-MBEE/OpenSysML
-
dependencies
Dificultad 2/5 1-3 horas Aptitud para principiantes 65/100
Open-MBEE/OpenSysML#1951 · 3 comentarios · 1 reacción ·
Los mantenedores suelen responder en 1 día
-
Dificultad 5/5 Más de una semana Aptitud para principiantes 25/100
Los mantenedores suelen responder en 1 día
-
bug enhancement spec compliance
Dificultad 4/5 3-5 días Aptitud para principiantes 48/100
Open-MBEE/OpenSysML#2009 · 3 comentarios ·
Los mantenedores suelen responder en 1 día
-
bug spec compliance
Dificultad 4/5 3-5 días Aptitud para principiantes 52/100
Open-MBEE/OpenSysML#2008 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
bug
Dificultad 4/5 3-5 días Aptitud para principiantes 48/100
Open-MBEE/OpenSysML#2007 · 2 comentarios ·
Los mantenedores suelen responder en 1 día
Todos los issues de Open-MBEE/OpenSysML
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
microsoft/TypeScript#65370 ·
Los mantenedores suelen responder en 1 día
-
bug tech debt testing
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
aws/amazon-vpc-cni-k8s#3976 ·
Los mantenedores suelen responder en 1 día
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 83/100
txn2/mcp-data-platform#2522 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
open-telemetry/opentelemetry-go-contrib#10234 ·
Los mantenedores suelen responder en 1 día
-
discovery/backoff: default FindPeers limit yields no fresh peersPosiblemente ocupada @zakazaka95 la tomó hoy. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100