Created
November 21, 2013 15:35
-
-
Save kkc/7583766 to your computer and use it in GitHub Desktop.
test
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # -*- coding:utf-8 -*- | |
| import json | |
| import csv | |
| csv_data = [] | |
| for line in open('items.trans.jl'): | |
| try: | |
| data = json.loads(line) | |
| except: | |
| print line | |
| continue | |
| number = data['number'] | |
| desc = "".join(data['desc']).strip() | |
| try: | |
| print "%s, %s" % (number, unicode(desc).encode('utf-8')) | |
| except: | |
| #print number | |
| pass |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment