CycloneDX / CycloneDX/gh-python-generate-sbom

Using a non-default input path causes the action to fail

Ouverte
#4 4 commentaires 0 réactions 0 personnes assignées Voir sur GitHub
Langage dominant
JavaScript
Étoiles
14
Forks
4
Métriques de merge des PR
Aucune PR mergée en 30 j

Description

When using either v1.0.0 or v1.0.1 of the action it fails when attempting to run the command to actually generate the bom. When running the 1.0.0 version of the action I get the log output:

```
Options:
i: ./xxxxx/requirements.txt
o: ./bom.xml
Running: cyclonedx-py -i ./xxxxx/requirements.txt -o ./pythonsbom.xml
usage: cyclonedx-py [-h] (-c | -cj | -e | -p | -pip | -r) [-i FILE_PATH]
[--format {xml,json}]
[--schema-version {1.4,1.3,1.2,1.1,1.0}] [-o FILE_PATH]
[-F] [-pb] [-X]
cyclonedx-py: error: one of the arguments -c/--conda -cj/--conda-json -e/--e/--environment -p/--p/--poetry -pip/--pip -r/--r/--requirements is required
Error: Command failed: cyclonedx-py -i ./xxxxx/requirements.txt -o ./bom.xml
usage: cyclonedx-py [-h] (-c | -cj | -e | -p | -pip | -r) [-i FILE_PATH]
[--format {xml,json}]
[--schema-version {1.4,1.3,1.2,1.1,1.0}] [-o FILE_PATH]
[-F] [-pb] [-X]
cyclonedx-py: error: one of the arguments -c/--conda -cj/--conda-json -e/--e/--environment -p/--p/--poetry -pip/--pip -r/--r/--requirements is required
```

That lead me to believe that since the -r flag wasn't set it was causing the command to fail. The 1.0.1 version doesn't actually give any output when it fails.

I was able to successfully generate a bom when I instead just ran the command to generate the bom in the workflow and provided it the -r flag.

If there's anything else that I can provide that would help just let me know.

Guide de contribution

Ouvrir le guide de contribution

Piste de recherche

Commencez par reproduire la GitHub Action avec un chemin d’entrée non défini par défaut et comparez la commande cyclonedx-py consignée avec la commande réussie qui inclut -r. Suivez l’endroit où les options d’entrée sont assemblées ; c’est terminé lorsque l’Action génère correctement la BOM pour un chemin requirements non défini par défaut.

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

Évaluation

Stack technique
javascript, python
Domaine
ci-cd
Type d'issue
Bug
Difficulté
3/5
Temps estimé
1-2 jours
Activité
À l'abandon
Clarté
Plutôt claire
Accessibilité débutants
35/100

Recevez les nouvelles issues par e-mail

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