acidjunk / acidjunk/fortigate-config-parser
configparser issue in Python2 and Python3
- 主要言語
- Python
- スター
- 23
- フォーク
- 9
- PR マージ指標
- 30日以内にマージされた PR はありません
説明
Hi,
I am facing issues in using this parser in both python 2 & 3.
In python2, I am having issues in installing `configparser` module.
```sh
E:\anand\py> .\Miniconda2\python.exe .\Miniconda2\pkgs\configparser-3.5.0.tar\dist\configparser-3.5.0\setup.py install
error in configparser setup command: Distribution contains no modules or packages for namespace package 'backports'
```
In python3, I am having issues in using `configparser` module. This issue is common in both Windows and Linux.
```py
>>> from configparser import ConfigParser
>>> with open(r'E:\anand\fg_master\tests\unit_tests\fortigate_parser\config_examples\example.conf','r') as f:
... config = f.read()
...
>>> fortigate = ConfigParser(config)
Traceback (most recent call last):
File "", line 1, in
File "E:\anand\py\Miniconda3\lib\configparser.py", line 614, in __init__
for key, value in defaults.items():
AttributeError: 'str' object has no attribute 'items'
```
My skills are insufficient to find a fix for this. I tried to google a lot but couldn't find a solution that I could understand and implement.
Please help. Thank you.
コントリビューションガイド
このリポジトリのコントリビューションガイドは索引されていません
評価
この issue はまだ評価されていません。