在导入烧瓶模块(或任何依赖于烧瓶的模块)时,我收到以下错误:
Traceback (most recent call last):
File "main.py", line 2, in <module>
from flask import Flask, request, render_template, redirect, abort, make_response
File "/usr/lib/python3.7/site-packages/flask/__init__.py", line 21, in <module>
from .app import Flask, Request, Response
File "/usr/lib/python3.7/site-packages/flask/app.py", line 26, in <module>
from . import cli, json
File "/usr/lib/python3.7/site-packages/flask/json/__init__.py", line 26, in <module>
_slash_escape = '\\/' not in _json.dumps('/')
AttributeError: module 'simplejson' has no attribute 'dumps'
我的系统和软件包详细信息:
>> uname -r
5.2.3-arch1-1-ARCH
>> pacman -Q --info python-flask
Name : python-flask
Version : 1.0.3-1
Description : Micro webdevelopment framework for Python
Architecture : any
URL : http://flask.pocoo.org/
Licenses : custom:BSD
Groups : None
Provides : None
Depends On : python-werkzeug python-jinja python-itsdangerous python-click
Optional Deps : None
Required By : python-flask-wtf
Optional For : None
Conflicts With : None
Replaces : None
Installed Size : 789.00 KiB
Packager : Felix Yan <felixonmars@archlinux.org>
Build Date : Sat 25 May 2019 10:31:00 AM IST
Install Date : Sun 04 Aug 2019 01:11:45 AM IST
Install Reason : Installed as a dependency for another package
Install Script : No
Validated By : Signature