orf / simple

Simple is a clone of Obtvse written in Python running on Flask.
MIT License
505 stars 280 forks source link

Some small bugfixes you might want to incorporate #8

Closed hellerbarde closed 12 years ago

hellerbarde commented 12 years ago
  1. add a href attribute to the "preview post" anchor tag, so the cursor becomes the link cursor on all browsers.
  2. change the padding on ".edit_post", so the text can't disappear under the admin toolbar when editing.

(sorry for changing the whole compiled css, but i could not find out what setting you used for compiling the css-sass thing.)

orf commented 12 years ago

Thanks! I have merged this, but when I tested it with chrome it didn't work 100% (sometimes went under, sometimes didn't). I think I am just going to move the bottom admin bar to the side, or maybe get rid of the bar completely and have small white buttons.

hellerbarde commented 12 years ago

oh thats interesting. i didnt think it would misbehave in different browsers... it is one of the fundamental concepts in css, after all.

haha, btw pulling your latest changes into my customizations branch completely broke my simple. i didnt push it yet, but it just throws a 500 internal server error. i am very new to flask, how do i enable debugging mode? cherrypy just prints on the console, can i enable that in flask somehow?

cheers

phil

Sent from my Android phone with K-9 Mail. Please excuse my brevity.

orf reply@reply.github.com wrote:

Thanks! I have merged this, but when I tested it with chrome it didn't work 100% (sometimes went under, sometimes didn't). I think I am just going to move the bottom admin bar to the side, or maybe get rid of the bar completely and have small white buttons.


Reply to this email directly or view it on GitHub: https://github.com/orf/simple/pull/8#issuecomment-4949386

orf commented 12 years ago

Weird, mine seems to work fine after the pull. If you edit simple.py and add the following line after line 11 app.debug = True

then run it. it will give you a nice stack trace and a web shell to poke around objects. Don't forget to remove this after you are done! Let me know if the error is related to my code and I will get it fixed ASAP.

hellerbarde commented 12 years ago

i will try it some time today. i probably havent been clear enough: i pulled it into a branch called "customizations", and then it broke, so i think it was probably related to me fracking up a merge.

i will tell you in case it is related to your code of course.

Sent from my Android phone with K-9 Mail. Please excuse my brevity.

orf reply@reply.github.com wrote:

Weird, mine seems to work fine after the pull. If you edit simple.py and add the following line after line 11 (app = Flask(name)): app.debug = True

then run it. it will give you a nice stack trace and a web shell to poke around objects. Don't forget to remove this after you are done! Let me know if the error is related to my code and I will get it fixed ASAP.


Reply to this email directly or view it on GitHub: https://github.com/orf/simple/pull/8#issuecomment-4949793

hellerbarde commented 12 years ago

uh... It was the database. i didn't realize there was a datamodel change in the intermediate commits.

How do you propose to retain blog posts through data model changes (i have little to no experience in those matters.)

orf commented 12 years ago

Well I intend to use (this)[http://readthedocs.org/docs/sqlalchemy-migrate/en/v0.7.2/] library to handle migrations if needed in the future, but I don't intend to mess with the models much more now, so I am going to delay implementing it until I have to.

That library looks a bit hacky but it supports sqlite3 well, but I lothe to add another dependency to the project.

hellerbarde commented 12 years ago

yeah, i would agree with you on refraining from adding a dep unless you have to. maybe there could be a separate file just to migrate the db, so the core functionality does not have to depend on another library? It would be a bit less elegant though. maybe there could be a json-export/json-import kind of solution with defaults for new fields. just an idea that could be implemented with the python stdlib from version 2.6 forward.

hellerbarde commented 12 years ago

on another note, have you considered adding tag support? i see how it could be considered a bit bloaty for this simple blog. i will probably implement it in a branch soon. if you're interested, i will send you a pull request when it's done. the nice thing is that it wouldnt even necessarily screw up the posts table, since i would implement it with a 'tags' table and a 'has_tag' join table. thoughts?

Sent from my Android phone with K-9 Mail. Please excuse my brevity.

orf reply@reply.github.com wrote:

Well I intend to use (this)[http://readthedocs.org/docs/sqlalchemy-migrate/en/v0.7.2/] library to handle migrations if needed in the future, but I don't intend to mess with the models much more now, so I am going to delay implementing it until I have to.

That library looks a bit hacky but it supports sqlite3 well, but I lothe to add another dependency to the project.


Reply to this email directly or view it on GitHub: https://github.com/orf/simple/pull/8#issuecomment-4951275