Coder Social home page Coder Social logo

mindfulness's People

Contributors

kirwanelmsly avatar tomwdrake avatar w-martin avatar

Stargazers

 avatar

Watchers

 avatar

mindfulness's Issues

Single quotes in title field cause an error in postgres query

[2017-12-04 15:56:18,526] ERROR in app: Exception on /add-entry/ [POST] Traceback (most recent call last): File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1982, in wsgi_app response = self.full_dispatch_request() File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1614, in full_dispatch_request rv = self.handle_user_exception(e) File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1517, in handle_user_exception reraise(exc_type, exc_value, tb) File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1612, in full_dispatch_request rv = self.dispatch_request() File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1598, in dispatch_request return self.view_functions[rule.endpoint](**req.view_args) File "/opt/mindfulness/src/web.py", line 67, in add_entry database.add_song(db, link, song, user_id, month=12 if festive else None) File "/home/datascience/PyCharm/mindfulness/src/database.py", line 115, in add_song db.execute(query_str) ProgrammingError: syntax error at or near "Christmas" LINE 1: ...ngs (title,url,user_id) select 'Do they Know it's Christmas ...

Holiday mode

Allow users to mark themselves as 'on holiday' so that their songs won't play

Hyphens missing from discord notifications

Songs are typically specified as " - <Title>". However, in the discord mindfulness notification, they appear without this hyphen separating artist and title, making the text harder to parse.

default to low volume level?

because it's also used for our morning standups, verv's office speaker is usually set to max volume. this is too high for most downloaded songs; they usually come out noisy and sound a bit distorted

unicode error song name

[2018-03-12 15:14:49,826] ERROR in app: Exception on /add-entry/ [POST]
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1982, in wsgi_app
response = self.full_dispatch_request()
File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1614, in full_dispatch_request
rv = self.handle_user_exception(e)
File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1517, in handle_user_exception
reraise(exc_type, exc_value, tb)
File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1612, in full_dispatch_request
rv = self.dispatch_request()
File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1598, in dispatch_request
return self.view_functionsrule.endpoint
File "/opt/mindfulness/src/web.py", line 61, in add_entry
song = util.remove_commas_from_string(request.form["songName"])
File "/opt/mindfulness/src/util.py", line 27, in remove_commas_from_string
return str(input_string).translate(None, ',')
UnicodeEncodeError: 'ascii' codec can't encode character u'\xe9' in position 1: ordinal not in range(128)

Auto-fill description form acts as a shell

Since YT link is being inserted as a string, input sanitation (or lack thereof) does not filter the nasty symbols out, allowing shell commands to be executed.

E.g. ; cat /etc/fstab >> /home/datascience/fstab -- will do cat /etc/fstab >> /home/datascience/fstab: semi-colon ends the youtube-dl part and -- escapes the --no-warnings suffix.

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.