# Unable to load from file:file20200315.glb: Unexpected magic: 67324752

**URL:** <https://forum.babylonjs.com/t/unable-to-load-from-file-file20200315-glb-unexpected-magic-67324752/11994>\
**Category:** Questions\
**Created:** [June 25, 2020, 2:17pm UTC](https://forum.babylonjs.com/t/unable-to-load-from-file-file20200315-glb-unexpected-magic-67324752/11994 "2020-06-25T14:17:07Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![kmitov](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/kmitov/32/4969_2.png) [@kmitov](https://forum.babylonjs.com/u/kmitov)\
**Post date:** [June 25, 2020, 2:17pm UTC](https://forum.babylonjs.com/t/unable-to-load-from-file-file20200315-glb-unexpected-magic-67324752/11994/1 "2020-06-25T14:17:07Z")

</div>

Hi,

This just happened.

```auto
Unable to load from file:file20200315.glb: Unexpected magic: 67324752

```

I am not sure where to even begin with to understand how this final got broken. It got exported by Babylon and now it can not be loaded.

Trying to load it also with sandbox and I got

```auto
Error in parsing value for ‘transform-origin’. Declaration dropped. sandbox.babylonjs.com:1:46603
Error in parsing value for ‘transform-origin’. Declaration dropped. sandbox.babylonjs.com:1:8696
Unknown pseudo-class or pseudo-element ‘-ms-track’. Ruleset ignored due to bad selector. sandbox.babylonjs.com:1:1587
Unknown pseudo-class or pseudo-element ‘-ms-fill-lower’. Ruleset ignored due to bad selector. sandbox.babylonjs.com:1:1717
Unknown pseudo-class or pseudo-element ‘-ms-fill-upper’. Ruleset ignored due to bad selector. sandbox.babylonjs.com:1:1790
Unknown pseudo-class or pseudo-element ‘-ms-thumb’. Ruleset ignored due to bad selector. sandbox.babylonjs.com:1:1863
Unknown property ‘-moz-opacity’. Declaration dropped. sandbox.babylonjs.com:1:2724
Expected ‘none’, URL, or filter function but found ‘alpha(’. Error in parsing value for ‘filter’. Declaration dropped.

```

but nothing about the error.

Could you please advice me what could I begin with?

---

<div class="post-metadata">

**Author:** ![sebavan](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/sebavan/32/57_2.png) [@sebavan](https://forum.babylonjs.com/u/sebavan)\
**Post date:** [June 25, 2020, 2:21pm UTC](https://forum.babylonjs.com/t/unable-to-load-from-file-file20200315-glb-unexpected-magic-67324752/11994/2 "2020-06-25T14:21:15Z")

</div>

Could you share your file ???

---

<div class="post-metadata">

**Author:** ![kmitov](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/kmitov/32/4969_2.png) [@kmitov](https://forum.babylonjs.com/u/kmitov)\
**Post date:** [June 25, 2020, 2:42pm UTC](https://forum.babylonjs.com/t/unable-to-load-from-file-file20200315-glb-unexpected-magic-67324752/11994/3 "2020-06-25T14:42:59Z")

</div>

@sebavan  
This is the file. Thanks  
[https://www.axlessoft.com/babylon/file20200315.glb](https://www.axlessoft.com/babylon/file20200315.glb)

---

<div class="post-metadata">

**Author:** ![sebavan](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/sebavan/32/57_2.png) [@sebavan](https://forum.babylonjs.com/u/sebavan)\
**Post date:** [June 25, 2020, 2:50pm UTC](https://forum.babylonjs.com/t/unable-to-load-from-file-file20200315-glb-unexpected-magic-67324752/11994/4 "2020-06-25T14:50:00Z")

</div>

The file sounds corrupted as it does not work in any gltf viewers [https://gltf-viewer.donmccurdy.com/](https://gltf-viewer.donmccurdy.com/)

---

<div class="post-metadata">

**Author:** ![kmitov](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/kmitov/32/4969_2.png) [@kmitov](https://forum.babylonjs.com/u/kmitov)\
**Post date:** [June 25, 2020, 2:53pm UTC](https://forum.babylonjs.com/t/unable-to-load-from-file-file20200315-glb-unexpected-magic-67324752/11994/5 "2020-06-25T14:53:39Z")

</div>

This is how it was save

```auto
let options = {
        shouldExportNode: function(/** @type {BABYLON.Node} */ transformNode) {
          const namesToTest = ["light1", "light2", "hdrSkyBox", "topHemiLight", "bottomHemiLight", "_boundingBox"];
          const regexToTest = namesToTest.map(name => new RegExp(name));

          if (regexToTest.some(regex => regex.test(transformNode.name))) return false;

          return true;
        }
      };
      BABYLON.GLTF2Export.GLBAsync(this._babylonScene, "scene.glb", options).then(response => {
        response.downloadFiles();
      });

```

I am not sure where and what to begin with. This is the second file from the client that gets corrupted like this. Any ideas what could I look for?

---

<div class="post-metadata">

**Author:** ![sebavan](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/sebavan/32/57_2.png) [@sebavan](https://forum.babylonjs.com/u/sebavan)\
**Post date:** [June 25, 2020, 2:56pm UTC](https://forum.babylonjs.com/t/unable-to-load-from-file-file20200315-glb-unexpected-magic-67324752/11994/6 "2020-06-25T14:56:04Z")

</div>

would be amazing to have the scene they are exporting in the playground as it is really hard to find without repro and just the output file ☹

---

<div class="post-metadata">

**Author:** ![Gijs](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/gijs/32/44_2.png) [@Gijs](https://forum.babylonjs.com/u/Gijs)\
**Post date:** [June 25, 2020, 4:13pm UTC](https://forum.babylonjs.com/t/unable-to-load-from-file-file20200315-glb-unexpected-magic-67324752/11994/7 "2020-06-25T16:13:08Z")

</div>

The problem here is that the exported `glb` file is actually a `zip` file containing the `glb` file

---

<div class="post-metadata">

**Author:** ![kmitov](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/kmitov/32/4969_2.png) [@kmitov](https://forum.babylonjs.com/u/kmitov)\
**Post date:** [June 25, 2020, 4:14pm UTC](https://forum.babylonjs.com/t/unable-to-load-from-file-file20200315-glb-unexpected-magic-67324752/11994/8 "2020-06-25T16:14:54Z")

</div>

Seriously… @Gijs thank you :D. Why and how I will now ask.

---

<div class="post-metadata">

**Author:** ![Gijs](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/gijs/32/44_2.png) [@Gijs](https://forum.babylonjs.com/u/Gijs)\
**Post date:** [June 25, 2020, 4:35pm UTC](https://forum.babylonjs.com/t/unable-to-load-from-file-file20200315-glb-unexpected-magic-67324752/11994/9 "2020-06-25T16:35:48Z")

</div>

> [@kmitov](#):
>
> `shouldExportNode`

I don’t know why; when I use your code snippet (I also tried it with options `true`/`false`, and in multiple browsers), it produces a `glb` file as expected:

> **[Babylon.js Playground](https://playground.babylonjs.com/#DNL788)**
>
> Babylon.js playground is a live editor for Babylon.js WebGL 3D scenes

I couldn’t find an answer in these files either:

> <https://github.com/BabylonJS/Babylon.js/blob/f3b4098c0f3f00f7f3993494bf833af266160b1b/serializers/src/glTF/2.0/glTFData.ts#L22>

> <https://github.com/BabylonJS/Babylon.js/blob/6e809f98cd8f0e8d8e1179bf863de1827f4bc7d7/serializers/src/glTF/2.0/glTFExporter.ts#L891>

---

<div class="post-metadata">

**Author:** ![sebavan](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/sebavan/32/57_2.png) [@sebavan](https://forum.babylonjs.com/u/sebavan)\
**Post date:** [June 25, 2020, 5:00pm UTC](https://forum.babylonjs.com/t/unable-to-load-from-file-file20200315-glb-unexpected-magic-67324752/11994/10 "2020-06-25T17:00:41Z")

</div>

Love it @Gijs 🙂

---

<div class="post-metadata">

**Author:** ![Evgeni\_Popov](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/evgeni_popov/32/4432_2.png) [@Evgeni\_Popov](https://forum.babylonjs.com/u/Evgeni_Popov)\
**Post date:** [June 25, 2020, 5:24pm UTC](https://forum.babylonjs.com/t/unable-to-load-from-file-file20200315-glb-unexpected-magic-67324752/11994/11 "2020-06-25T17:24:33Z")

</div>

Maybe the web server auto-zip the files and you get the zipped file from the download?

---

<div class="post-metadata">

**Author:** ![kmitov](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/kmitov/32/4969_2.png) [@kmitov](https://forum.babylonjs.com/u/kmitov)\
**Post date:** [June 25, 2020, 5:40pm UTC](https://forum.babylonjs.com/t/unable-to-load-from-file-file20200315-glb-unexpected-magic-67324752/11994/12 "2020-06-25T17:40:18Z")

</div>

> [@Gijs](#):
>
> The problem here is that the exported `glb` file is actually a `zip` file containing the `glb` file

Seems to be something on the client infrastructure. I get a glb link, but it is zipped. I will be prepared next time for this 🙂
