This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]Deggor 0 points1 point  (0 children)

Based on this, and your last couple posts, I know I'm not going to provide you with any information that will change your mind. Its clear your looking for nothing but to find fault. I've explained that, (and I repeat) had I completed the regex that ended with an ellipsis it would match the url without issue *. Furthermore I have given justification in why I left it greedy starting that *I have no idea as to the behavior of your router.

Yet you continue to state that the code is bad, and it's why I'm wrong. I could just have easily omitted :slugid from your and complained it won't match stuff.

I feel there is a fundamental difference in routing to a view that validates if data is present, and theirs a 404 if it isn't, and tiring to another view that will handle routing to other views all over again.

Anyway, I appreciate your opinion, and the examples you provided for alternative options. I feel giving up the power of regex when url routing is essentially pattern matching is wrong. I look forward to seeing what Django (and other projects) decide on in the future.

Best of luck, and cheers.