推荐学习书目
› Learn Python the Hard Way
Python Sites
› PyPI - Python Package Index
› http://diveintopython.org/toc/index.html
› Pocoo
值得关注的项目
› PyPy
› Celery
› Jinja2
› Read the Docs
› gevent
› pyenv
› virtualenv
› Stackless Python
› Beautiful Soup
› 结巴中文分词
› Green Unicorn
› Sentry
› Shovel
› Pyflakes
› pytest
Python 编程
› pep8 Checker
Styles
› PEP 8
› Google Python Style Guide
› Code Style from The Hitchhiker's Guide
zungmou
V2EX  ›  Python

Python 之 json 库,如何解码非标准的 json 字符串

  •  
  •   zungmou · Jun 30, 2016 · 5075 views
    This topic created in 3767 days ago, the information mentioned may be changed or developed.

    如下所示,某服务器返回的 json 字段没有用引号包括,导致 json 库的 loads 方法无法正常加载,请问 python 高手,如果不去处理这段文本,能解决吗?

    [ { name: "join", age: "16" } ]

    2 replies  •  2016-06-30 13:45:14 +08:00
    zungmou
        2
    zungmou  
    OP
       Jun 30, 2016
    @cloverstd Thank you very much!
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   2371 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 26ms · UTC 01:09 · PVG 09:09 · LAX 18:09 · JFK 21:09
    ♥ Do have faith in what you're doing.