{"action":"created","issue":{"url":"https://api.github.com/repos/scottschiller/SoundManager2/issues/169","repository_url":"https://api.github.com/repos/scottschiller/SoundManager2","labels_url":"https://api.github.com/repos/scottschiller/SoundManager2/issues/169/labels{/name}","comments_url":"https://api.github.com/repos/scottschiller/SoundManager2/issues/169/comments","events_url":"https://api.github.com/repos/scottschiller/SoundManager2/issues/169/events","html_url":"https://github.com/scottschiller/SoundManager2/issues/169","id":249229415,"node_id":"MDU6SXNzdWUyNDkyMjk0MTU=","number":169,"title":"Cannot set position when serving on localhost","user":{"login":"brandonchinn178","id":6827922,"node_id":"MDQ6VXNlcjY4Mjc5MjI=","avatar_url":"https://avatars3.githubusercontent.com/u/6827922?v=4","gravatar_id":"","url":"https://api.github.com/users/brandonchinn178","html_url":"https://github.com/brandonchinn178","followers_url":"https://api.github.com/users/brandonchinn178/followers","following_url":"https://api.github.com/users/brandonchinn178/following{/other_user}","gists_url":"https://api.github.com/users/brandonchinn178/gists{/gist_id}","starred_url":"https://api.github.com/users/brandonchinn178/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brandonchinn178/subscriptions","organizations_url":"https://api.github.com/users/brandonchinn178/orgs","repos_url":"https://api.github.com/users/brandonchinn178/repos","events_url":"https://api.github.com/users/brandonchinn178/events{/privacy}","received_events_url":"https://api.github.com/users/brandonchinn178/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":11,"created_at":"2017-08-10T04:23:15Z","updated_at":"2018-11-16T02:37:54Z","closed_at":null,"author_association":"NONE","body":"I'm running a Django project at `http://localhost:5000`, and the following code segment in the console doesn't work:\r\n```js\r\nsound = soundManager.createSound({url: \"/media/audio/foo.ogg\"})\r\nsound.play({position: 1000})\r\n```\r\nwhere `/media` serves files from my local filesystem. It also doesn't work if I give the full path `http://localhost:5000/media/audio/foo.ogg`.\r\n\r\nHowever, it does work if I load from any external site or if I load the file and use the url from `URL.createObjectUrl`. The biggest difference I can find is that loading from localhost returns `200` responses, while loading externally or with a file blob returns `206` responses. I can't find any documentation about this, but if this is documented somewhere, please point me to it. For now, I could manually check the domain and load a file blob, but I'd like to know why this is happening before trying any workarounds."},"comment":{"url":"https://api.github.com/repos/scottschiller/SoundManager2/issues/comments/439262239","html_url":"https://github.com/scottschiller/SoundManager2/issues/169#issuecomment-439262239","issue_url":"https://api.github.com/repos/scottschiller/SoundManager2/issues/169","id":439262239,"node_id":"MDEyOklzc3VlQ29tbWVudDQzOTI2MjIzOQ==","user":{"login":"scottschiller","id":174437,"node_id":"MDQ6VXNlcjE3NDQzNw==","avatar_url":"https://avatars3.githubusercontent.com/u/174437?v=4","gravatar_id":"","url":"https://api.github.com/users/scottschiller","html_url":"https://github.com/scottschiller","followers_url":"https://api.github.com/users/scottschiller/followers","following_url":"https://api.github.com/users/scottschiller/following{/other_user}","gists_url":"https://api.github.com/users/scottschiller/gists{/gist_id}","starred_url":"https://api.github.com/users/scottschiller/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scottschiller/subscriptions","organizations_url":"https://api.github.com/users/scottschiller/orgs","repos_url":"https://api.github.com/users/scottschiller/repos","events_url":"https://api.github.com/users/scottschiller/events{/privacy}","received_events_url":"https://api.github.com/users/scottschiller/received_events","type":"User","site_admin":false},"created_at":"2018-11-16T02:37:54Z","updated_at":"2018-11-16T02:37:54Z","author_association":"OWNER","body":"`Accept-Ranges: Bytes` should help here. Range requests / partials are important to HTML5 clients as most expect they can ask for arbitrary slices of files. I wouldn't trust most browsers to work properly when they're told by a server that they can't. 😬 \r\n\r\nA few related notes on this, yonder -\r\nhttp://www.schillmania.com/projects/soundmanager2/doc/technotes/#byte-serving\r\n\r\n(Pardon super late follow-up on this.)"}}
{"actor":{"display_login":"scottschiller"}}