sphinxcontrib-argparser is well name. i keep muttering "arg" trying to figure this out
well, i got pdistreport to work with argparse, but i just cannot figure out how to get sphinxcontrib-autoprogram to render its help. anyone got a suggestion? https://github.com/Pylons/pyramid/pull/2842/
i just can't figure out how to get at the function's parser variable
goodwill
stevepiercy: have a function that creates the parser and return it
stevepiercy: and specify it in the directive
PCreateCommand.parser
stevepiercy
the parser is created in main() already. i tried returning parser in main(), and calling that
goodwill
seems wrong
stevepiercy
goodwill wrong file
i've moved onto pdistreport
goodwill
move the parser creation into it's own function
that main class
calls
stevepiercy
ah, ok
atombendr has quit
arg indeed
meh, sphinx still doesn't like it
so frustrating
rickmak joined the channel
gopar joined the channel
nilo joined the channel
finally
gopar
o/
nilo has quit
goodwill
\o
gopar
\o/
stevepiercy
\m/
goodwill
~o~
NotreDev joined the channel
Method__ has quit
moo-_-
good morning
nilo joined the channel
atomekk joined the channel
davisagli has quit
agitator joined the channel
NotreDev has quit
mr_jolly joined the channel
mr_jolly has quit
disko joined the channel
fxhp has quit
mathieu____ joined the channel
mathieu____ is now known as bochecha
bochecha has quit
bochecha joined the channel
mr_jolly joined the channel
Adniel joined the channel
Method__ joined the channel
nilo has quit
Charlie_X joined the channel
ronnix joined the channel
rickmak joined the channel
slav0nic joined the channel
yleclanche joined the channel
RchrdB has quit
dega joined the channel
domenkozar
gooooood morning
jhauser joined the channel
teix joined the channel
waveform joined the channel
nilo joined the channel
rodfersou joined the channel
bochecha has quit
mathieu____ joined the channel
nilo has quit
nilo joined the channel
Method___ joined the channel
Method__ has quit
ronnix_ joined the channel
rickmak has quit
ronnix joined the channel
stevepiercy has quit
stevepiercy joined the channel
nilo has quit
ronnix joined the channel
ronnix has quit
MrTango_ joined the channel
mage_
with Traversal what's the proper way to generate an url in a template when it's not for a resource ?
cdunklau
mage_: if it's not for a resource, what's it for?
mage_
found it :) request.relative_url does what I want
hvelarde joined the channel
nilo joined the channel
mr_jolly has quit
mr_jolly joined the channel
wiggy joined the channel
RchrdB joined the channel
if I have a view that should return either HTML or JSON regarding some header is it better to add the view twice with a different rendered or should I use custom_predicates?
Elmer
mage_: one function with two view_configs, and you'll probably need a custom predicate to make the decision based on the header contents
mage_
thanks
ronnix joined the channel
hvelarde has quit
blaflamme joined the channel
rickmak joined the channel
fxhp joined the channel
rodfersou is now known as rodfersou|lunch
Ergo joined the channel
mamalos joined the channel
mamalos
hey everybody!
I am back again to ask for ideas regarding serving multiple fqdn's within the same pyramid app
views can serve different content based on request.host (or request.domain for that matter)
mamalos: static views should be handled by your apache/nginx in the end ;-)
mamalos
ergo: my "solution" allows for any sort of static view handling (eg. passing different external uri's for each different fqdn)
Ergo
mamalos: look at x-send-file header as one of the approaches you can take if you need to make this more dynamic
mamalos
Ergo: did you read the pastebin? Because I'm using pyramid's static_view to serve my static assets, only I configure static_views member variables dynamically, based on my request
Ergo: but I was thinking if there was a "more elegant" solution than this (not that mine is not elegant, but it seems rather "hackee")
Ergo
mamalos: yes - but do you expect any "serious" traffic?
mamalos
Ergo: I'd certainly hope so! :)
Ergo
because you block python threads to serve static assets
i would offload the work as much as i can from python application if you expect serious numbers
mamalos
Ergo: you mean in order to generate the different urls that serve each request?
Ergo
with x-sendfiles you can "hint" webserver on file location based on your requirements
so you can do something like
domain a.com serves from /upload/a.com, domain b.com from /upload/b.com
bur you can make it "transparent" to user - and use any url scheme you want
or make restricted static assets etc.
mamalos
OK, and how does it work with x-sendfiles? upload/a.com etc are not generated via pyramid?
Ergo
thats an implementation detail
so it depends on your application
mamalos
I'm asking you because I'm not sure what is different -design wise- when using x-sendfiles and when using pyramid's routing
but let me first check what x-sendfile is about, because I'm asking you things that I have no clue about :)
Ah, so if I understood correctly, using sendfile the web server directly serves static files without giving control to pyramid?
Ergo
mamalos: yes
its like request -> pyramid -> header -> proxy -> file -> response