File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -35,12 +35,23 @@ def download_tool(url):
3535
3636 filename = wget .download (url )
3737 files_before = os .listdir ()
38- shutil .unpack_archive (filename )
39- files_after = os .listdir ()
40- new_file = str (next (iter ((set (files_after ) - set (files_before )))))
41- st = os .stat (new_file )
42- os .chmod (new_file , st .st_mode | stat .S_IEXEC )
43- return filename
38+ # shutil.unpack_archive(filename)
39+
40+ #This is just set for AWS to debug. This will have to be mapped to OS. They changed their file structure. This should be updated.
41+ shutil .unpack_archive ("gdc-client_2.3_Ubuntu_x64.zip" )
42+ if not os .path .exists ('gdc-client' ):
43+ raise FileNotFoundError ("gdc-client executable not found after extraction." )
44+ # Ensure 'gdc-client' is executable
45+ st = os .stat ('gdc-client' )
46+ os .chmod ('gdc-client' , st .st_mode | stat .S_IEXEC )
47+ # Return the path to the executable
48+ return './gdc-client'
49+
50+ # files_after = os.listdir()
51+ # new_file = str(next(iter((set(files_after) - set(files_before)))))
52+ # st = os.stat(new_file)
53+ # os.chmod(new_file, st.st_mode | stat.S_IEXEC)
54+ # return filename
4455
4556def is_tool (name ):
4657 """
You can’t perform that action at this time.
0 commit comments