File Endpoint does not receive file with permitted file extension

I am sure this is issue is caused because some safety concern on the api side. however I am still raising this issue. im running into this problem when I try to upload a git commit diff log (with txt file extention) using file upload endpoint. It returns me error 400 with invalid format even the file is a standard txt file.

the file content may causing this upload fail. but I think I need an explaination.
I cannot provide the exact commit log since it’s a database commit log from my company. but it can be test with any commit diff log should causing the same issue.

tried on my application programmatically and both on playground. all failed.

To provide more detail the file contains something like, I have edited some part of the message to exclude information that are not suppose to be out.

The commit log is a lot longer than this.

commit 6970ff090962f005a3fe1bd9dxxxxxxxxxx
Author: abcdefg <blur email>
Date:   Thu May 16 21:18:21 2024 +1000

    Automated backup of database schema on 2024-05-16 21:18:20

diff --git a/taurus/Functions/blahblah_sPsvf.sql b/taurus/Functions/blahblah_sPsvf.sql
new file mode 100644
index 0000000..77deeec
--- /dev/null
+++ b/taurus
b/taurus/Functions/dbo_svf_blahblahblah.sql
@@ -0,0 +1,36 @@
+´╗┐SET ANSI_NULLS ON
+GO
+SET QUOTED_IDENTIFIER ON
+GO
+IF NOT EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID(N'[dbo].[svf_blahblahblah]') AND type in (N'FN', N'IF', N'TF', N'FS', N'FT'))
+BEGIN
+execute dbo.sp_executesql @statement = N'
+

The content inspection almost disregards your file name. You can see how much plain text preamble is required for the (likely off-the shelf) inspector to believe you sent a text file.

.zip is allowed, which prevents easy content inspection of code interpreter files, and you can automate a chat session after code interpreter expires in one hour with another prefix message telling the AI it must unzip again.

zip it and upload. it still failed. :confused:

...
Enter the filename to upload (leave empty to exit): list-thread.py
File uploaded successfully: list-thread.py [file-TUrIp9C3HJUXYmM8AYcJUnWh]
== OpenAI File Storage Utility ==
-- Main Menu --
[1] Change purpose (to access different type of API files)
[2] Change local directory (the upload source)
[3] Upload file
[4] List remote files
[5] List all remote and delete one of your choice
[6] Delete all files with current purpose (confirmation required)
[9] Exit
(current mode: purpose='assistants')
==========

Enter your choice: 3
== OpenAI File Storage Utility ==
-- Upload File --

(current mode: purpose='assistants')
==========

Enter the filename to upload (leave empty to exit): zipdemo.zip
File uploaded successfully: zipdemo.zip [file-RUNC0ahFAfmOowdIjFeEOHfC]

Success seen above.

Is it the uploading, or getting the AI to use it that is the problem?