Project

General

Profile

Development #43488

Utiliser IPython.start_ipython et pas .embed()

Added by Benjamin Dauvergne about 1 month ago. Updated about 1 month ago.

Status:
Rejeté
Priority:
Normal
Target version:
-
Start date:
29 May 2020
Due date:
% Done:

0%

Patch proposed:
Yes
Planning:
No

Description

.embed() a un comportement bizarre avec les locales :

In [37]: for formdata in formdef.data_class().select():
    ...:     if not any(field.id in formdata.data and formdata.data[field.id].content_type.startswith('image/') for field in file_fields):
    ...:         continue
    ...:     print(formdata.id)
    ...:     
---------------------------------------------------------------------------
NameError                                 Traceback (most recent call last)
/usr/lib/python3/dist-packages/wcs/ctl/shell.py in <module>()
      1 for formdata in formdef.data_class().select():
----> 2     if not any(field.id in formdata.data and formdata.data[field.id].content_type.startswith('image/') for field in file_fields):
      3         continue
      4     print(formdata.id)
      5 

/usr/lib/python3/dist-packages/wcs/ctl/shell.py in <genexpr>(.0)
      1 for formdata in formdef.data_class().select():
----> 2     if not any(field.id in formdata.data and formdata.data[field.id].content_type.startswith('image/') for field in file_fields):
      3         continue
      4     print(formdata.id)
      5 

NameError: name 'formdata' is not defined

https://github.com/ipython/ipython/issues/62

0001-misc-use-IPython.start_ipython-43488.patch View (800 Bytes) Benjamin Dauvergne, 29 May 2020 09:17 PM

History

#1 Updated by Benjamin Dauvergne about 1 month ago

  • Subject changed from Utiliser IPython.start_python et pas .embed() to Utiliser IPython.start_ipython et pas .embed()

#2 Updated by Benjamin Dauvergne about 1 month ago

  • Assignee set to Benjamin Dauvergne

#3 Updated by Benjamin Dauvergne about 1 month ago

#4 Updated by Benjamin Dauvergne about 1 month ago

  • Status changed from Solution proposée to Rejeté

Inutile avec #42099.

Also available in: Atom PDF