Django rest not returning reponse after large file uploads

When I upload a small file <25mb everything works as expected, when I upload a larger file >50mb the conditions and everything else works but my view doesn’t return the the response.
if request.method=="POST":
        if serializer.is_valid():
            #the method is just checking some conditions it doesn't affect anything
            if result is None:
                return Response(,status=status.HTTP_200_OK)
                return Response(result,status=status.HTTP_403_FORBIDDEN)
            return Response(serializer.errors,status=status.HTTP_400_BAD_REQUEST)
#client side
async def upload(cmd_dict):
        f=await aiofile.async_open(cmd_dict['upath'],'rb')
        await printScreen("client_error","Invalid path, make sure to surround the path with double quotes \"\"")
        await printScreen("client_info",f"Uploading {os.path.basename(}")
            async with httpx.AsyncClient() as client:
                        "dname":cmd_dict['dname'] if cmd_dict['dname'] is not None else '',
                        'caption':cmd_dict['caption'] if cmd_dict['caption'] is not None else '',
                await f.close()
        except Exception as e:
            if res.is_success:
                await printScreen("client_ok","File uploaded!")
                    "text":f"{res_json['file']} | {res_json['dname']}\n{res_json['caption']}"
                await printScreen("client_error",res.text)
#Most things don't matter here, cmd_dict is just a dictionary for checking the command the user inputted, printScreen is a custom method, and I have to use async due to the way my client works.

Below of this line is the output of the server from (top to bottom, uploading a small file, uploading a big file) (both intentionally will fail with error 400), one returns the response, the other doesn’t, I have checked with the print statement that the part below else does run, it’s just not returning the response.
small file:
Bad Request: /uploads/
HTTP POST /uploads/ 400 [0.02,]
big file:
Bad Request: /uploads/

Edit : Incase you were wondering, it’s the same with the post request as well, and if I type a print statement above it run, but again, no response if it’s a big file.
And no it doesn’t have anything to do with the response’s content, I changed it from serializer.errors to a simple static text but the behavior is still the same.

For anybody in the far future who was as dumb as me and ran to a similar problem.
The httpx module has a timeout of 5, which was longer than the time it took for the server to respond which means the client no longer received responses, which means that django didn’t log that the response was returned, which led to me thinking there was something wrong in the server.