showoci: error in "__load_functions_functions"

Ouverte
#919 5 commentaires 0 réactions 0 personnes assignées Voir sur GitHub

Personne n'a encore pris cette issue.

Évaluation

Difficulté
3/5
Temps estimé
Une demi-journée
Accessibilité débutants
42/100
Type d'issue
Bug
Clarté
Plutôt claire
Activité
Active
Stack technique
python
Domaine
cloud

Piste de recherche

The error comes from __load_functions_functions in the ShowOCIService class, which reads an image attribute from a FunctionSummary object that does not have it. Start by finding that method and the place it reads image and image_digest, then check the linked FunctionSourceDetails reference to see how source_type (CONTAINER_IMAGE, PRE_BUILT_FUNCTIONS, ARCHIVE) changes which fields exist. Done when functions with non-container sources load without the error and container-image functions still report their image.

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

Description

When I run showoci version "26.10.27", I get the error shown below.
Looks like it tries to get the image (and image_digest), but this is not part of the response body.

"type": "errors",
"data": [
{
"class": "ShowOCIService",
"function": "__load_functions_functions",
"compartment": "",
"region": "eu-frankfurt-1",
"error": "'FunctionSummary' object has no attribute 'image'",
"is_warning": "False"
},

To get the image and image_digest data, you need to look at the function SourceDetails.
Depending on the source_type (if it's CONTAINER_IMAGE ), the image and image_digest are known.
Other source types (PRE_BUILT_FUNCTIONS and ARCHIVE ) have different attributes.
See: FunctionSourceDetails Reference

Hope this can be fixed in a future release.
Thanks in advance.
Herman

Langage dominant
Python
Étoiles
474
Forks
326
Merge moyen
10 min
PR mergées (30 j)
6

Préparer son environnement

Par où commencer

  1. Lisez l'issue en entier, puis le guide de contribution du projet.
  2. Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
  3. Forkez le dépôt et travaillez sur une branche.
  4. Ouvrez une pull request qui référence le numéro de l'issue.

Autres issues de oracle/oci-python-sdk

Toutes les issues de oracle/oci-python-sdk

Issues similaires

Plus d'issues Python

Recevez les nouvelles issues par e-mail

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