New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
change default encoding of API calls to 'utf-8' #663
Labels
enhancement
Requires Notice
Implementing this ticket requires user be notified
Time:Minor
Up to 4 hours
Milestone
Comments
+1 I'm fully in favor of moving everything to UTF-8. |
+1 |
grizz
added
Requires Notice
Implementing this ticket requires user be notified
Time:Minor
Up to 4 hours
labels
Apr 24, 2020
Can we have a Release Note pls? |
Release Note |
vegu
added a commit
that referenced
this issue
Jun 24, 2020
vegu
pushed a commit
that referenced
this issue
Jun 24, 2020
change default encoding of API calls to 'utf-8' #663 See merge request gh/peeringdb/peeringdb!81
Merged
vegu
added a commit
that referenced
this issue
Jun 24, 2020
grizz
added a commit
that referenced
this issue
Jun 24, 2020
* Add pointer from API docs to tutorial #650 * Sorting by clicking table headers should use local-compare #356 * Mark IXP peering LAN as bogon #352 * Add help text to "Add (Facility, Network, Exchange)" tab #669 * Add Looking Glass field to the IX object #672 * Add read-only Superuser #679 * Make spelling of traffic levels consistent #519 (#723) * Offer 2FA (#290) * Show "Last Updated" fields on fac, ix, org records (#526) * Enable sort and reverse sort of IP column in IX display (#72) * IRR validation not handling unexpected characters gracefully (#712) * Support alternative direction of writing, e.g. Arabic (#618) * Undeleting an ixlan with an emtpy IPv4 XOR IPv6 field throws a silly error (#644) * Changing org while adding net results in 500 #654 * missing delete button for organisations (#121) * When changing owner of an ix admin GUI borks because of "Ixlan for exchange already exists" #666 * Selection should only present undeleted objects (#664) * change default encoding of API calls to 'utf-8' #663 * Posting https://www.peeringdb.com onto social media doesn't select a good preview image #537 * Revert "Add Looking Glass field to the IX object #672" This reverts commit 4daf252. Conflicts: peeringdb_server/migrations/0037_ix_looking_glass.py peeringdb_server/views.py * 500 Internal Error when creating IX where prefix already exists elsewhere #718 * Fix graceful restore of soft-deleted objects with translation active (#580) * Don't return any POC data with status=deleted #569 Hard delete soft-deleted pocs after grace period #566 * django-peeringdb from github@2.0.0.2-beta Co-authored-by: Stefan Pratter <stefan@20c.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
enhancement
Requires Notice
Implementing this ticket requires user be notified
Time:Minor
Up to 4 hours
As I've struggled many hours now with the interaction between the
python2 (don't ask, but for this i couldn't switch to python3 ...)
requests library and peeringDB API, I'd like to make the following
suggestion for change.
If I query:
https://www.peeringdb.com/api/ix
The response headers say:
content-type: application/json; charset=iso-8859-1
I think it makes more sense to have the charset be 'utf-8' for the json
output.
The current charset (iso-8859-1) causes python programmers extra steps trying to convert this to unicode. For instance, in the much used python requests library you need
to know and understand this. The standard approach is this:
r_ixlan = requests.get("https://www.peeringdb.com/api/ixlan")
j_ixlan = r_ixlan.json()
to get the json output (but all kinds of hell happens when you try
manipulating for instance the ixp 'name' field that contains non-ascii
code).
What one needs to do to get this right:
In my case I have the solution now, but I think it will save hours of
pain on people trying to program against peeringDB if you make this change.
Happy to make a twitter poll or somesuch to see if i'm the only one who
had to deal with this.
hope this helps make peeringDB even better!
thanks for providing this service, it's awesome
best regards,
Emile Aben
RIPE NCC
The text was updated successfully, but these errors were encountered: