Any help in make django filter + pagination + sorting works? My problem is only to sorting. I'm using webstack-django-sorting
djangorris has quit
rethil has quit
q--pr joined the channel
q--pr has quit
kaiza has quit
woltman joined the channel
woltman4 joined the channel
woltman has quit
chicocvenancio joined the channel
jonez
greetings
exaroth joined the channel
mekhami
what's the right way to concatenate a queryset
err, two querysets of the same object.
FunkyBob
wasn't support for Union just added?
or is that 2.0?
mekhami
1.11
i'm actually on 1.10
FunkyBob
itertools.chain ?
mekhami
for some reason | works
is that unusual?
FunkyBob
no
that ORs the two sets of conditions
it's not quite a union
mekhami
well it works for this case though, haha
fission6 has quit
in the template engine, things inside an {% if False %} block don't get calculated, right?
like if i have a bit of context in there that idoes stuff based on request.user, but the user isn't logged in, will it throw an error?
FunkyBob
no, it should be skipped
mekhami
hm
what if it's from a context processor
that context processor function will fail
cause i didn't check request.user.is_authenticated
that's the actual point of error i guess
Info-Screen has quit
mucco has quit
digia has quit
Info-Screen joined the channel
dtzitz joined the channel
Lobstaman3 has quit
lacrymology has quit
infinitesum joined the channel
jas02 joined the channel
trynottobeakek has quit
rajalokan joined the channel
schinckel
mekhami: You can (and should) make context processors "lazy", ie, they won't evaluate until they are referenced.
jas02 has quit
mekhami: You can also use | to join two querysets (as long as they are "compatible")
qs1 | qs2
kloudi-- joined the channel
kloudi- has quit
OtherAllan joined the channel
pastry has quit
adu joined the channel
dtzitz has quit
exaroth joined the channel
belmoussaoui joined the channel
lanartri joined the channel
belmoussaoui has quit
woltman4 has quit
belmoussaoui joined the channel
cyphase joined the channel
jonez
greetings
djangorris joined the channel
transit
jonez: You'll usually get a better response by just asking your question.
jonez
transit, agreed :) I'm doing some research on my own before Iask
transit has left the channel
I'm using the 'timeuntil' modifier. at the right times, I get a '0 minutes' output. I'd like to customize that to say "happening now" or "today" or whatnot.
adu joined the channel
perhaps 'naturalday'?
lb1c has quit
lb1c joined the channel
milardovich has quit
titodrew has quit
mcspud
can anyone recommend a good CRM with a beautiful API?
kurashu89 joined the channel
I'm going to burn our Dynamics one to the ground
kupi has quit
adwin_ has quit
adu joined the channel
bayman joined the channel
bayman
what's the best way to django rest framework?
infinitesum has quit
mcspud
reading the docs bayman ?
exaroth joined the channel
amcorreia has quit
infinitesum joined the channel
EyePulp joined the channel
mekhami
schinckel ▸ more information on lazy context processors?
schinckel
mekhami: Things that don't evaluate until they are referenced.
it doesn't seem to query the database for messages on every request
schinckel
IIRC, messages are not stored in the database.
But have a look at the source.
nt56u joined the channel
souravbadami joined the channel
tyriondwarf joined the channel
infinitesum has quit
rawl joined the channel
mekhami
schinckel ▸ in the post you linked, what's the 'cache' being used?
schinckel
I'm not sure. I just came across that (and it looked _okay_).
tyriondwarf has quit
Hang on, let me see how I'm doing one.
JSharpe has quit
Ah, my one I was thinking about is a bit different: it instantiates a class, that implements __getitem__ and __contains__ (and I use it in a template as "'foo' in packages", where packages is added to the context)
N0ATN has quit
felixx joined the channel
lvh joined the channel
olson86 joined the channel
djangorris has quit
mekhami
i see.
ycon_ joined the channel
Note to self, be extra extra careful about not committing your AWS keys to public repositories
it slipped into one of my repos that had only been up for a few hours
and immediately my accountw as compromised, someone launched a boatload of EC2 instances and I racked up $14k in charges.
luckily amazon was way on top of that.
entrop joined the channel
Disavowed
mekhami: Ouch! That could have been worse!
mekhami
Disavowed: i really appreciate amazon's custom support right now :)
Disavowed
That is absolutely terrifying. I guess they trawl github looking for keys. I think I'd be equally appreciative!
schinckel
Hmmph. I'm not sure CELERY_ALWAYS_EAGER=True applies to groups.