Hello everyone.

The Mixed Reality Forums here are no longer being used or maintained.

There are a few other places we would like to direct you to for support, both from Microsoft and from the community.

The first way we want to connect with you is our mixed reality developer program, which you can sign up for at https://aka.ms/IWantMR.

For technical questions, please use Stack Overflow, and tag your questions using either hololens or windows-mixed-reality.

If you want to join in discussions, please do so in the HoloDevelopers Slack, which you can join by going to https://aka.ms/holodevelopers, or in our Microsoft Tech Communities forums at https://techcommunity.microsoft.com/t5/mixed-reality/ct-p/MicrosoftMixedReality.

And always feel free to hit us up on Twitter @MxdRealityDev.
Options

Trying to upload 1 files returns 429, too many requests.

I have a piece of code: to upload a file to the HoloLens (attached):

        public async static void UploadFile(ConnectInfo connectInfo, string knownfolderid, string packagefullname, string path, string filePath)
        {
            try
            {
                // Query
                string query = string.Format(API_FileQuery, connectInfo.IP);
                query += "?knownfolderid=" + Uri.EscapeUriString(knownfolderid);
                query += "&packagefullname=" + Uri.EscapeUriString(packagefullname);
                query += "&path=" + Uri.EscapeUriString(path);

                //  Create http request
                var httpRequest = new HttpClient();

                httpRequest.DefaultRequestHeaders.Clear();
                httpRequest.DefaultRequestHeaders.Authorization = new System.Net.Http.Headers.AuthenticationHeaderValue("Basic",
                                                                                            EncodeTo64(connectInfo.User + ":" + connectInfo.Password));
                byte[] data = File.ReadAllBytes(filePath);
                ByteArrayContent byteContent = new ByteArrayContent(data);

                HttpResponseMessage resp = await httpRequest.PostAsync(query, byteContent);

                //var responseMessage = await resp.Content.ReadAsStringAsync();
                var responseMessage = resp.Content.ReadAsStringAsync().Result;

                Console.WriteLine(resp.IsSuccessStatusCode);
                var x = resp;
            }
            catch (Exception ex)
            {
                Console.WriteLine(ex.Message);
            }

        }

But from just attempting to upload a file once, I get a response back from the HoloLens File Explorer API saying Too many requests (code 429)

I haven't found a valid solution online yet.
ANY HELP would be awesome.

Answers

  • Options

    Having the same problem! I also see this when I am trying to upload this through Device Portal in Edge

  • Options

    I can confirm this behaviour in the device portal on the hololens, this sucks very hard.

    14393.1770.x86fre.rs1_release.170917-1700

Sign In or Register to comment.