Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow Insecure mysql #13

Open
347read opened this issue Apr 9, 2017 · 0 comments
Open

Allow Insecure mysql #13

347read opened this issue Apr 9, 2017 · 0 comments

Comments

@347read
Copy link

347read commented Apr 9, 2017

I realize that using insecure mysql isn't best practice, but thought it would make sense to allow for a db.ini file that doesn't have a password:

    def __init__(self, **args):
        parser = ConfigParser()
        parser.read('%s/db.ini' % sys.path[0])
        user = parser.get('db', 'user')
        db = parser.get('db', 'db')
        args = {'user': user, 'db': db, 'charset': 'utf8'}
        if parser.has_option('db', 'host'):
            args['host'] = parser.get('db', 'host')
        if parser.has_option('db', 'password'):
            args['passwd'] = parser.get('db', 'password')

Easy to solve, the same way you solved the db-host option.

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

No branches or pull requests

1 participant