Skip to content
This repository has been archived by the owner on Dec 24, 2020. It is now read-only.

安装过程中报错 #88

Open
wuxie2015 opened this issue Jun 21, 2020 · 3 comments
Open

安装过程中报错 #88

wuxie2015 opened this issue Jun 21, 2020 · 3 comments

Comments

@wuxie2015
Copy link

image
在an zhuang guo ch安装过程中,报错
Traceback (most recent call last):
File "/Users/zhanglin/Documents/tools/Curve_bak/Curve/venv/bin/swagger_py_codegen", line 5, in
from swagger_py_codegen import generate
File "/Users/zhanglin/Documents/tools/Curve_bak/Curve/venv/lib/python2.7/site-packages/swagger_py_codegen/init.py", line 4, in
from .command import generate
File "/Users/zhanglin/Documents/tools/Curve_bak/Curve/venv/lib/python2.7/site-packages/swagger_py_codegen/command.py", line 15, in
from .flask import FlaskGenerator
File "/Users/zhanglin/Documents/tools/Curve_bak/Curve/venv/lib/python2.7/site-packages/swagger_py_codegen/flask.py", line 6, in
from .jsonschema import Schema, SchemaGenerator, build_default
File "/Users/zhanglin/Documents/tools/Curve_bak/Curve/venv/lib/python2.7/site-packages/swagger_py_codegen/jsonschema.py", line 6, in
from .parser import schema_var_name
File "/Users/zhanglin/Documents/tools/Curve_bak/Curve/venv/lib/python2.7/site-packages/swagger_py_codegen/parser.py", line 5, in
import dpath.util
File "/Users/zhanglin/Documents/tools/Curve_bak/Curve/venv/lib/python2.7/site-packages/dpath/util.py", line 1, in
from collections.abc import MutableMapping
ImportError: No module named abc
但是colleciton.abc不是python3才支持的吗?

@minorcong
Copy link
Collaborator

也许应该调整下 swagger_py_codegen 的版本?

@brianhill11
Copy link

I had same issue... as a hacky fix I changed the import statement in Curve/venv/lib/python2.7/site-packages/dpath/util.py
from

from collections.abc import MutableMapping
from collections.abc import MutableSequence

to

try:
    from collections.abc import MutableMapping
    from collections.abc import MutableSequence
except ImportError:
    from collections import MutableMapping
    from collections import MutableSequence

and it seems to work.

alumik added a commit to alumik/curve that referenced this issue Dec 4, 2020
@alumik
Copy link

alumik commented Dec 4, 2020

也许应该调整下 swagger_py_codegen 的版本?

I've submitted a pull request, adding dpath==1.5.0 as an explicit requirement.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants