Giter Site home page Giter Site logo

sqlite3.OperationalError about bgmi HOT 8 CLOSED

ricterz avatar ricterz commented on September 26, 2024
sqlite3.OperationalError

from bgmi.

Comments (8)

RicterZ avatar RicterZ commented on September 26, 2024

看起来好像是初始化database失败了…默认是在~/.bgmi 目录,你看一下是不是没有读写权限?
Alice Nychto [email protected]于2016年9月11日 周日上午5:52写道:

alice at nychto in ~ [23:48:18]
$ bgmi cal all
Traceback (most recent call last):
File "/usr/local/bin/bgmi", line 9, in
load_entry_point('bgmi==0.4.6', 'console_scripts', 'bgmi')()
File "/usr/local/lib/python3.5/site-packages/bgmi-0.4.6-py3.5.egg/bgmi/main.py", line 408, in setup
init_db(DB_PATH)
File "/usr/local/lib/python3.5/site-packages/bgmi-0.4.6-py3.5.egg/bgmi/main.py", line 395, in init_db
conn = sqlite3.connect(db_path)
sqlite3.OperationalError: unable to open database file

用pip和pip3安装的结果都是无法运行……


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
#4, or mute the thread
https://github.com/notifications/unsubscribe-auth/AFCbx7nQ9y7D_ZAEnk8Mjs-TwWDrsfk_ks5qoya1gaJpZM4J51pq
.

from bgmi.

auzeonfung avatar auzeonfung commented on September 26, 2024

我也遇到了这个问题,一开始是提示 sqlite3.OperationalError: attempt to write a readonly database ,尝试进入 ~/.bgmi 更改权限,然后就变 sqlite3.OperationalError: unable to open database file
用root权限就解决了……
不知道是哪里姿势不对

from bgmi.

RicterZ avatar RicterZ commented on September 26, 2024

感觉很不科学...什么情况下的呢..
是不是sudo pip install bgmi的。。

from bgmi.

auzeonfung avatar auzeonfung commented on September 26, 2024

@RicterZ 嗯……我的是用root权限装的……

from bgmi.

RicterZ avatar RicterZ commented on September 26, 2024

@auzeonfung 我大概知道问题了..
sudo pip install bgmi 的话,HOME 还是你当前普通用户的路径,但是创建路径的时候就是 root 权限创建在你当前用户的 HOME 下的,所以你当前用户没权限写...

from bgmi.

RicterZ avatar RicterZ commented on September 26, 2024

这个 bug 待会儿修(x

from bgmi.

alicenychto avatar alicenychto commented on September 26, 2024

还真是…chmod 777 之后就可以用了(后知后觉

from bgmi.

RicterZ avatar RicterZ commented on September 26, 2024

6b97e44
fix 了这个问题

from bgmi.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.