Server Error when importing devices with cyrillyc characters #434

Closed
opened 2025-12-29 16:22:10 +01:00 by adam · 1 comment
Owner

Originally created by @askbow on GitHub (Sep 16, 2016).

When importing devices in bulk, I encountered an error:
<type 'exceptions.UnicodeEncodeError'> 'ascii' codec can't encode characters in position 18-21: ordinal not in range(128)

The data that I was importing contains Cyrillic characters in UTF-8. It was correctly exported from Netbox device list in the first place, then opened in Notepad++, copied and pasted back into the browser window.

Steps to reproduce:
in http://netbox.example.com/dcim/devices/import/ in the CSV Data field paste
SW1,Access Switch,ТЕСТ,Cisco,WS-C2960-24PC-S,Cisco IOS,F000000000,,ТЕСТ,Стойка,24,Front
and hit Submit.

We're running netbox 1.6.0 release code, Python version 2.7.9, Django 1.10.

Adding devices / other objects with Cyrillic characters in names one-by-one via UI goes without problems.

Originally created by @askbow on GitHub (Sep 16, 2016). When importing devices in bulk, I encountered an error: `<type 'exceptions.UnicodeEncodeError'> 'ascii' codec can't encode characters in position 18-21: ordinal not in range(128)` The data that I was importing contains Cyrillic characters in UTF-8. It was correctly exported from Netbox device list in the first place, then opened in Notepad++, copied and pasted back into the browser window. Steps to reproduce: in http://netbox.example.com/dcim/devices/import/ in the CSV Data field paste `SW1,Access Switch,ТЕСТ,Cisco,WS-C2960-24PC-S,Cisco IOS,F000000000,,ТЕСТ,Стойка,24,Front` and hit Submit. We're running netbox 1.6.0 release code, Python version 2.7.9, Django 1.10. Adding devices / other objects with Cyrillic characters in names one-by-one via UI goes without problems.
adam closed this issue 2025-12-29 16:22:10 +01:00
Author
Owner

@jeremystretch commented on GitHub (Sep 16, 2016):

Should be fixed by #493

@jeremystretch commented on GitHub (Sep 16, 2016): Should be fixed by #493
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#434