ansys / ansys/python-usd-viewer

Should the auto setup check for products ?

Ouverte
#6 0 commentaires 0 réactions 0 personnes assignées Voir sur GitHub
Langage dominant
Python
Étoiles
0
Forks
0
Merge moyen
1 j 16 h
PR mergées (30 j)
7

Description

This is mainly an open question and would probably be better as a discussion than an issue. Should the auto setup script check for installation using products that are expected to contain C++ compiler support ?

For example, I used `winget` to install visual studio and the auto setup script is not working. With a tiny modification:
```python

# Products that include C++ compiler support
vs_products = [
"Microsoft.VisualStudio.Product.BuildTools",
"Microsoft.VisualStudio.Product.Community",
"Microsoft.VisualStudio.Product.Professional",
"Microsoft.VisualStudio.Product.Enterprise",
]

vs_found = False
for vswhere_path in vswhere_paths:
if Path(vswhere_path).exists():
try:
# Search for any product that includes C++ build tools
result = subprocess.run(
[vswhere_path, "-latest", "-products"] + vs_products + ["-property", "installationPath"],
capture_output=True,
text=True,
check=True,
)
vs_path = result.stdout.strip()
if vs_path:
vs_found = True
break
except subprocess.CalledProcessError:
continue
```
The script no longer fails. I'm not sure that the `winget` installation is enough thugh. I'll follow the error message advices to install visual studio.

Guide de contribution

Ouvrir le guide de contribution

Piste de recherche

Commencez par localiser le script de configuration automatique et sa détection existante via vswhere, puis examinez comment les installations de Visual Studio et la prise en charge des compilateurs C++ sont actuellement vérifiées. Testez le comportement avec une instance de Visual Studio installée via winget. C’est terminé lorsque l’installation attendue est détectée de manière fiable ou que le problème est clarifié sous la forme d’une exigence concrète.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Évaluation

Stack technique
python
Domaine
build-system
Type d'issue
Fonctionnalité
Difficulté
3/5
Temps estimé
1-2 jours
Activité
À l'abandon
Clarté
À clarifier
Accessibilité débutants
35/100

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.