Re: Model icons

2023-02-22 Thread Brice Parent
Hello! Really useful idea, I think! 2 points about it: 1. Syntax I would also remove the html from the models, but probably in this way: class Hammer(models.Model):     ...     Meta:         icon = ModelIcon("") There would be something like ModelIcon.as_html(self, model_name:str) ->

Re: Proposal to format Django using black

2019-04-17 Thread Brice Parent
Le 17/4/19 à 2:33, Dan Davis a écrit : +1 isort -1 black I think that codestyle checkers are better, because you teach yourself proper style for python. I'm in a team in which we've enforced Black a bit more than a year ago, and I can tell you that now, everyone code in a blackish style

Re: Feedback wanted for API to support for multi file upload

2018-08-27 Thread Brice Parent
Hi Joe, Just an idea: Why not just use another keyword argument, like "files_number", "count", "max_files" (along maybe with a "min_files"), or something like, with a default of 1 (to match current behaviour with a single file), and an allowed value of 0 for infinite? If you allow multiple

keepdb with flush option

2018-02-07 Thread Brice Parent
Hi everyone, Right now, when testing, we have the choice to either : * create a new empty database to launch the tests with * reuse an existing database with all its data (--keepdb) I think we're missing a third option, here : * reuse an existing database, but flush its contents before (or