joshcamas Posted March 31, 2015 Share Posted March 31, 2015 Hey guys! Another question from Josh! Now that my project is getting bigger, something is getting very annoying. This guy: GET localhost/unsinkable/assets/meshes/player/man3.babylon.manifest?1427843823831 404 (Not Found)babylon-alpha.js:3 BJS - [16:17:03]: Valid manifest file not found. Scene & textures will be loaded directly from the web server. Now, I know that this isn't bad. However, since I do not want to have any manifest files, and for most meshes I will never want it, is it possible to turn this warning off? Even better, to turn off the check, so the GET error isn't shown? Cause I have many many many meshes, and it's making the console worthless! Thanks!! Quote Link to comment Share on other sites More sharing options...
RaananW Posted April 1, 2015 Share Posted April 1, 2015 Hi Josh,The error comes from the browser itself and not from babylon. To check that the file exists you have to make a request and see if it was sent back or is 404. This cannot be turned off. More about it here - http://stackoverflow.com/questions/16372271/jquery-ajax-how-to-prevent-404-errors-spam-in-chrome-devtools/16379746#16379746But, you can simply log differently. The browser lets you filter the messages you are seeing, so just ignore those errors. Sadly no other suggestion is easily implemented. Another solution would be a new LoadWithoutManifest function, or a new flag in the current load or append function, but that's a bit more work :-) Quote Link to comment Share on other sites More sharing options...
spritefire Posted April 1, 2015 Share Posted April 1, 2015 Just make a blank file named man3.babylon.manifest Quote Link to comment Share on other sites More sharing options...
davrous Posted April 1, 2015 Share Posted April 1, 2015 Hi, I can add a boolean to the engine asking to avoid checking for manifest file in order to always work with the assets from the web server. Need to discuss that with the team. Bye, David Dad72 1 Quote Link to comment Share on other sites More sharing options...
Dad72 Posted April 1, 2015 Share Posted April 1, 2015 Hi, I can add a boolean to the engine asking to avoid checking for manifest file in order to always work with the assets from the web server. Need to discuss that with the team. Bye, David It would be a great idea this. I also wish I could avoided this error Quote Link to comment Share on other sites More sharing options...
joshcamas Posted April 1, 2015 Author Share Posted April 1, 2015 @davrous Sweet!! Thanks so much!!! If you don't have time I can quickly type it up, but idk how to use git Quote Link to comment Share on other sites More sharing options...
ozRocker Posted April 2, 2015 Share Posted April 2, 2015 What's the manifest file for? I created a blank manifest file to stop the warning but I'm not sure if that will have any negative side-effects Quote Link to comment Share on other sites More sharing options...
joshcamas Posted April 2, 2015 Author Share Posted April 2, 2015 I believe it basically contains a boolean whether the mesh will be saved to the browser in a fancy way. LOL so vague Quote Link to comment Share on other sites More sharing options...
Temechon Posted April 2, 2015 Share Posted April 2, 2015 Everything is explained here : http://doc.babylonjs.com/page.php?p=22231 Basically, the manifest is very useful is you want to cache your 3D models in the client browser cache. ozRocker, webdva and joshcamas 3 Quote Link to comment Share on other sites More sharing options...
phil1234 Posted October 6, 2015 Share Posted October 6, 2015 well if you get a 404 it's because it's trying to get a fileso if you know you dont provide one, one should be able to disable the file loading from the engine itself, it's not a http/server related issue something like engine.cacheEnable(false); Quote Link to comment Share on other sites More sharing options...
davrous Posted October 6, 2015 Share Posted October 6, 2015 Hi, To disable manifest check, simply set the boolean enableOfflineSupport to false on the BABYLON.Engine object. I think I'll set it by default to false in next versions as we have this question very often on the failing XHR. People will have to set it to true to use .manifest and indexeddb. What do you think? Bye, David Virax, Jaskar and Christopher Stock 2 1 Quote Link to comment Share on other sites More sharing options...
Convergence Posted October 6, 2015 Share Posted October 6, 2015 Everything is explained here : http://doc.babylonjs.com/page.php?p=22231 Basically, the manifest is very useful is you want to cache your 3D models in the client browser cache.Why would that tiny piece of information require a separate file and thus request? Couldn't it just be stored in the .babylon file itself or configurable in the ImportMesh() function? Quote Link to comment Share on other sites More sharing options...
davrous Posted October 6, 2015 Share Posted October 6, 2015 Well, because if you'd like to handle cache ressources, you don't want to download the whole file to discover you'd just like to update or use the cache. Imagine the following scenario using embedded info: 1 - you're download the .babylon file and it contains cache data indicating I should keep it offline (in IDB)2 - next time you're loading the scene, it comes from the IDB / cache3 - you'd like to update something in the scene (meshes or textures). How do you say that to Babylon? If I need to redownload everytime the complete .babylon to check for updates, there's no interest to keep the file offline. David Quote Link to comment Share on other sites More sharing options...
Convergence Posted October 6, 2015 Share Posted October 6, 2015 you'd like to update something in the scene (meshes or textures). How do you say that to Babylon?I always omit cache by versioning in the url like /file.babylon?123456 where 123456 is a random number, or disable cache during development and enable it on live.Also http status codes resolved this problem with http 304, I think? Convergence 1 Quote Link to comment Share on other sites More sharing options...
Pawel W Posted October 14, 2015 Share Posted October 14, 2015 To those who would like babylon to stop calling for manifest - modify Database.prototype.checkManifestFile function, so it starts like this: Database.prototype.checkManifestFile = function () { var _this = this; var that = this; function noManifestFile() { that.enableSceneOffline = false; that.enableTexturesOffline = false; that.callbackManifestChecked(false); } noManifestFile(); // those 2 lines disable calling for Manifest return; // those 2 lines disable calling for ManifestDidn't look what those functions inside noManifestFile() do, but they were called after failure of downloading manifest - so I put them before this call happens and do the return. I understand manifest file is somehow used for caching, but should't it be rather deifned by some param? I really don't get this external-file-approach Convergence 1 Quote Link to comment Share on other sites More sharing options...
reddozen Posted October 14, 2015 Share Posted October 14, 2015 I understand manifest file is somehow used for caching, but should't it be rather deifned by some param? I really don't get this external-file-approach The manifest tells the browser to cache or not. If it exists, then it caches the the scene. Also, it is a seprate file to control resyncing the cache with version number. Saves having to have the user manually flushing their cache or having to use URL tricks to force a flush and recache on load. You just change the vesion number in your manifest file and it handles it. Quote Link to comment Share on other sites More sharing options...
Convergence Posted October 14, 2015 Share Posted October 14, 2015 Saves having to have the user manually flushing their cache or having to use URL tricks to force a flush and recache on load. You just change the vesion number in your manifest file and it handles it.How is that any better than 'URL tricks'? Only causes more network overhead imo. Quote Link to comment Share on other sites More sharing options...
reddozen Posted October 14, 2015 Share Posted October 14, 2015 How is that any better than 'URL tricks'? Only causes more network overhead imo. some people dont like "mysite.com?ResetPlz=1243f234er". It makes it less exposed to the user. I don't personially like GET requests where they can be avoided. Quote Link to comment Share on other sites More sharing options...
Srisub Posted March 14, 2016 Share Posted March 14, 2016 Like the flexibility of caching that it offers, but as the number of model files increases, it seems like a pain to create empty manifest files, just to avoid the warning. If there's any way the browser warning can be avoided, but still honor the manifest caching directives when it does exist, that would be the best of both worlds. Quote Link to comment Share on other sites More sharing options...
Temechon Posted March 14, 2016 Share Posted March 14, 2016 On 6/10/2015 at 9:20 AM, davrous said: To disable manifest check, simply set the boolean enableOfflineSupport to false on the BABYLON.Engine object. The answer is just in the post above http://doc.babylonjs.com/classes/2.3/Engine#enableofflinesupport-boolean Nevermind, I didn't get hisfull post... Quote Link to comment Share on other sites More sharing options...
Malachy Posted August 29, 2016 Share Posted August 29, 2016 The link to the docs describing the file has been updated. It is http://doc.babylonjs.com/tutorials/Caching_Resources_in_IndexedDB It is a short description but in summary (at 29th August 2016) the manifest file should be called NameOfYourScene.babylon.manifest (well, you can get the name from your 404 error message) And the contents can be { "version" : 1, "enableSceneOffline" : true, "enableTexturesOffline" : true } Then the scene and texture* data will be saved in each user's browser storage. See the docs for details about storing textures offline. Quote Link to comment Share on other sites More sharing options...
MasterSplinter Posted August 30, 2016 Share Posted August 30, 2016 hehehe.. someone else got annoyed by this error on my team and fixed it. it appears the solution has been offered so I'm not going to dig as to how they fixed it. Quote Link to comment Share on other sites More sharing options...
focomoso Posted July 13, 2017 Share Posted July 13, 2017 Quote To disable manifest check, simply set the boolean enableOfflineSupport to false on the BABYLON.Engine object. I think I'll set it by default to false in next versions as we have this question very often on the failing XHR. People will have to set it to true to use .manifest and indexeddb. It looks as if this still defaults to true. I set it to false and babylon no longer checks for the manifest (and gets rid of the 404 error). But is there a way to do this case by case? Some assets I'd like to cache, others come out of a database hosted on cloudfront and so it's not practical to create a .manifest for each file. Quote Link to comment Share on other sites More sharing options...
davrous Posted July 14, 2017 Share Posted July 14, 2017 I'll need to add a flag to override that then on a per mesh load basis. Quote Link to comment Share on other sites More sharing options...
paleRider Posted November 23, 2017 Share Posted November 23, 2017 Dear all: Any plans in order to add an "enableSoundsOffline" functionality to cached resources? Best regards. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.