Hope everyone is well.
When I upload a file greater than FILE_UPLOAD_MAX_MEMORY_SIZE I don't get any error it just gives me "This site can’t be reached".
I have post conditions to check if the file is above this size and return an error message if it is, works in local using S3 but does not work on EB.
Does anyone know why this is a problem on EB and not in local?
If you need any further information please let me know.
if 'document_file' in request.FILES:
megabytes = 2621440
file = request.FILES['document_file']
if file.size > megabytes:
raise Exception(f"{file.name}, cannot upload as the file is greater than 2.5mb")
Thanks in advance, Thomas