Convert table column contents to string

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

@hiyouwhatsapp y travaille déjà.

Depuis le 18/10/2026.

  • #548 par @hiyouwhatsapp — ouverte

Évaluation

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

Piste de recherche

Start in cleo/helpers/table.py, specifically _build_table_rows() around the reported line, and reproduce the failure with None or an object such as pendulum or a money value. The work is done when table cells containing these values render through string conversion without the TypeError; the custom-formatter alternative remains an unresolved scope question.

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

Description

bug requires confirmation

When adding columns with None or more complex contents (pendulum, money objects), they should automatically be converted using str(…), as this currently breaks in weird ways:

~/.virtualenvs/buchhaltung/lib/python3.5/site-packages/cleo/helpers/table.py in _build_table_rows() at line 301
   if '\n' not in cell:
[TypeError]                                  
  argument of type 'NoneType' is not iterable

Another possibility might be to specify custom formatters (probably somewhere next to defining table headers)?

Langage dominant
Python
Étoiles
1.4k
Forks
108
Merge moyen
15 min
PR mergées (30 j)
1

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 python-poetry/cleo

Toutes les issues de python-poetry/cleo

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.