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

2018-08-27 Thread Johannes Hoppe
Hi Brice, Interesting thought. I never looked at it from this perspective. I did some research. There is no way to reflect a file limit a HTML form (without Javascript). Furthermore there is no way to prevent people to send a request with more files, you could only limit the request body size (

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

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

2018-08-26 Thread Johannes Hoppe
Hi Adam! On Sunday, August 26, 2018 at 4:33:31 PM UTC+2, Adam Johnson wrote: > > My suggestion would be to add the new keyword argument which enable the >> new behavior and keep the attr-thing as is. >> I could add a warning if someone uses the "old" style. It is a bit >> suggestive though. > >

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

2018-08-26 Thread Adam Johnson
> > My suggestion would be to add the new keyword argument which enable the > new behavior and keep the attr-thing as is. > I could add a warning if someone uses the "old" style. It is a bit > suggestive though. Whilst it's not the normal way of deprecating things in Django, I'm not against it. W

Feedback wanted for API to support for multi file upload

2018-08-25 Thread Johannes Hoppe
Hi there! I do need some feedback on the best public API to implement multi file support to Django forms. Context: Up until now Django forms do not support multi file upload. You will need to write your own view to handle the files as described here: https://docs.djangoproject.com/en/2.1/topic