{"action":"created","issue":{"url":"https://api.github.com/repos/jrburke/r.js/issues/746","labels_url":"https://api.github.com/repos/jrburke/r.js/issues/746/labels{/name}","comments_url":"https://api.github.com/repos/jrburke/r.js/issues/746/comments","events_url":"https://api.github.com/repos/jrburke/r.js/issues/746/events","html_url":"https://github.com/jrburke/r.js/pull/746","id":49142526,"number":746,"title":"Fix source maps when using wrap","user":{"login":"jonbretman","id":1671025,"avatar_url":"https://avatars.githubusercontent.com/u/1671025?v=3","gravatar_id":"","url":"https://api.github.com/users/jonbretman","html_url":"https://github.com/jonbretman","followers_url":"https://api.github.com/users/jonbretman/followers","following_url":"https://api.github.com/users/jonbretman/following{/other_user}","gists_url":"https://api.github.com/users/jonbretman/gists{/gist_id}","starred_url":"https://api.github.com/users/jonbretman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jonbretman/subscriptions","organizations_url":"https://api.github.com/users/jonbretman/orgs","repos_url":"https://api.github.com/users/jonbretman/repos","events_url":"https://api.github.com/users/jonbretman/events{/privacy}","received_events_url":"https://api.github.com/users/jonbretman/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/jrburke/r.js/milestones/33","labels_url":"https://api.github.com/repos/jrburke/r.js/milestones/33/labels","id":781463,"number":33,"title":"2.1.16","description":null,"creator":{"login":"jrburke","id":73359,"avatar_url":"https://avatars.githubusercontent.com/u/73359?v=3","gravatar_id":"","url":"https://api.github.com/users/jrburke","html_url":"https://github.com/jrburke","followers_url":"https://api.github.com/users/jrburke/followers","following_url":"https://api.github.com/users/jrburke/following{/other_user}","gists_url":"https://api.github.com/users/jrburke/gists{/gist_id}","starred_url":"https://api.github.com/users/jrburke/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jrburke/subscriptions","organizations_url":"https://api.github.com/users/jrburke/orgs","repos_url":"https://api.github.com/users/jrburke/repos","events_url":"https://api.github.com/users/jrburke/events{/privacy}","received_events_url":"https://api.github.com/users/jrburke/received_events","type":"User","site_admin":false},"open_issues":0,"closed_issues":7,"state":"open","created_at":"2014-09-07T23:40:36Z","updated_at":"2015-02-09T08:22:59Z","due_on":null,"closed_at":null},"comments":6,"created_at":"2014-11-17T20:41:16Z","updated_at":"2015-02-09T11:25:08Z","closed_at":"2015-02-07T19:35:21Z","pull_request":{"url":"https://api.github.com/repos/jrburke/r.js/pulls/746","html_url":"https://github.com/jrburke/r.js/pull/746","diff_url":"https://github.com/jrburke/r.js/pull/746.diff","patch_url":"https://github.com/jrburke/r.js/pull/746.patch"},"body":"This fixes the issue where if you use the `wrap` option to append stuff to the beginning of the outputted module the line numbers in the source map are wrong, making them completely useless.\r\n\r\nI would like to write a test for this, however I couldn't even get them to run on master. I ran `node dist.js` and then I get the following output when trying to run the tests.\r\n\r\n```sh\r\njonbretman@Jons-MBP:~/git/r.js/build/tests$ node ../../r.js all.js \r\n1 tests to run in 1 groups\r\n------------------------------------------------------------\r\nGROUP \"convert\" has 1 test to run\r\n------------------------------------------------------------\r\nGROUP \"parseConfig\" has 1 test to run\r\n------------------------------------------------------------\r\nGROUP \"parseRequire\" has 1 test to run\r\n------------------------------------------------------------\r\nGROUP \"parseDefineCall\" has 1 test to run\r\n------------------------------------------------------------\r\nGROUP \"parseFindNestedDependencies\" has 1 test to run\r\n------------------------------------------------------------\r\nGROUP \"parseHasRequire\" has 1 test to run\r\n------------------------------------------------------------\r\nGROUP \"parseUsesAmdOrRequireJs\" has 1 test to run\r\n------------------------------------------------------------\r\nGROUP \"parseUsesCommonJs\" has 1 test to run\r\n------------------------------------------------------------\r\nGROUP \"parseFindCjsDependencies\" has 1 test to run\r\n------------------------------------------------------------\r\nGROUP \"parseLicenseComments\" has 1 test to run\r\n------------------------------------------------------------\r\nGROUP \"pragmaNamespace\" has 1 test to run\r\n------------------------------------------------------------\r\nGROUP \"transformModifyConfig\" has 1 test to run\r\n------------------------------------------------------------\r\nGROUP \"toTransport\" has 1 test to run\r\nbad6 has more than one anonymous define. May be a built file from another build system like, Ender. Skipping normalization.\r\n------------------------------------------------------------\r\nGROUP \"makeRelativeFilePath\" has 1 test to run\r\n\r\nfs.js:438\r\n  return binding.open(pathModule._makeLong(path), stringToFlags(flags), mode);\r\n                 ^\r\nError: ENOENT, no such file or directory 'builds/text.js'\r\n    at Object.fs.openSync (fs.js:438:18)\r\n    at Object.fs.readFileSync (fs.js:289:15)\r\n    at Object.file.readFile (/Users/jonbretman/git/r.js/build/jslib/node/file.js:215:27)\r\n    at c (/Users/jonbretman/git/r.js/build/tests/builds.js:11:21)\r\n    at /Users/jonbretman/git/r.js/build/tests/builds.js:34:31\r\n    at Object.context.execCb (/Users/jonbretman/git/r.js/r.js:1897:33)\r\n    at Object.Module.check (/Users/jonbretman/git/r.js/r.js:1113:51)\r\n    at Object.<anonymous> (/Users/jonbretman/git/r.js/r.js:1360:34)\r\n    at /Users/jonbretman/git/r.js/r.js:371:23\r\n    at /Users/jonbretman/git/r.js/r.js:1403:21\r\n\r\n```"},"comment":{"url":"https://api.github.com/repos/jrburke/r.js/issues/comments/73493815","html_url":"https://github.com/jrburke/r.js/pull/746#issuecomment-73493815","issue_url":"https://api.github.com/repos/jrburke/r.js/issues/746","id":73493815,"user":{"login":"jonbretman","id":1671025,"avatar_url":"https://avatars.githubusercontent.com/u/1671025?v=3","gravatar_id":"","url":"https://api.github.com/users/jonbretman","html_url":"https://github.com/jonbretman","followers_url":"https://api.github.com/users/jonbretman/followers","following_url":"https://api.github.com/users/jonbretman/following{/other_user}","gists_url":"https://api.github.com/users/jonbretman/gists{/gist_id}","starred_url":"https://api.github.com/users/jonbretman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jonbretman/subscriptions","organizations_url":"https://api.github.com/users/jonbretman/orgs","repos_url":"https://api.github.com/users/jonbretman/repos","events_url":"https://api.github.com/users/jonbretman/events{/privacy}","received_events_url":"https://api.github.com/users/jonbretman/received_events","type":"User","site_admin":false},"created_at":"2015-02-09T11:25:08Z","updated_at":"2015-02-09T11:25:08Z","body":"No problem, thanks for accepting it."}}