#python - Thu 5 Apr 2007 between 02:46 and 02:52

NY Lost Funds



sproingieeval
or for multiple statements, exec
chrisjw>>> eval('print "lol"')
syntax error ..
hmm exec will be ok
sproingieexec
print is a statement
chrisjwty
i'm writing a web server
and i want to have inline scripting
i'll have to be careful though
sproingieis this for learning?
chrisjwany bug could comprimise the entire system
yes
sproingieany bug in an exec could hose the webserver too
chrisjwlol
sproingiethere's nothing "sandboxed" about exec
chrisjwlol
oh dear
im using lol again
sorry
:)
:(
gpoloinline scripting using exec..
of course you want to have troubles
sproingiegpolo: he said it was for learning
i say let people experiment
gpolowell, it is ok to learn whatever you want
but sometimes people dont know what they want to learn
sproingiechrisjw: when you're done with that though, you should look at the existing python web stuff
chrisjwwell I'm writing my own little web server, it's not accessible to external hosts
my NAT ensures that only users on my small network can access my computer
unless there's any bugs in it
which there probably are!
gpolothat is not my point, but ok
chrisjwi'd just like to have a web page and be able to do something like
sproingieyou should look at genshi and mako for a couple different approaches to embedding python in pages
mako is a bit more directly embedded, genshi actually parses python expressions itself
chrisjwhello, your IP is <# print currentUser.IP #>.
something like that would be just what i'm working towards

Page: 2 9 16 23 30 37 44 51 58 65 72 79 86 93 

IrcArchive

NY Lost Funds