Mini Program file download error

problem description

want to achieve the file download preview function in Mini Program, but always make mistakes, report 400s, not very familiar with this aspect, but also ask friends who know to help.

related codes

/ / Please paste the code text below (do not replace the code with pictures)

 wx.downloadFile({
    url:path,   //
    success(res) {
     console.log(res);
      if (res.statusCode === 200) {
      const filePath = res.tempFilePath;
      wx.openDocument({
        filePath: filePath,
        success: function (res) {
          console.log("")
        }
      })
      }
    }, 
    fail: function (err) {
      console.log(err)
    }
    })

what result do you expect? What is the error message actually seen?

error message {statusCode: 400, errMsg: "downloadFile:ok"}

Oct.11,2021

same error. Very confused ~

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b40aa7-4f196.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b40aa7-4f196.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?