ysde / grafana-backup-tool

A Python-based application to backup Grafana settings by using the Grafana API
MIT License
877 stars 277 forks source link

import StringIO and pass data through StringIO read #173

Closed Keimille closed 1 year ago

Keimille commented 2 years ago

This resolved the issue for me in production. Resolves #172

acjohnson commented 2 years ago

Has this been tested with both python 2 and python 3?

Keimille commented 2 years ago

Yes, I've tested on both python2 and 3

spyder007 commented 1 year ago

FWIW, when I grabbed the latest code from this repository, I got an error using python 3.11.2

Traceback (most recent call last): File "/home/matt/anaconda3/envs/py_3/bin/grafana-backup", line 5, in <module> from grafana_backup.cli import main File "/home/matt/anaconda3/envs/py_3/lib/python3.11/site-packages/grafana_backup/cli.py", line 3, in <module> from grafana_backup.restore import main as restore File "/home/matt/anaconda3/envs/py_3/lib/python3.11/site-packages/grafana_backup/restore.py", line 15, in <module> from grafana_backup.s3_download import main as s3_download File "/home/matt/anaconda3/envs/py_3/lib/python3.11/site-packages/grafana_backup/s3_download.py", line 3, in <module> import StringIO ModuleNotFoundError: No module named 'StringIO'

I reverted to tag 1.3.0 and the error went away.