{"action":"opened","issue":{"url":"https://api.github.com/repos/ReactiveX/rxjs/issues/2092","repository_url":"https://api.github.com/repos/ReactiveX/rxjs","labels_url":"https://api.github.com/repos/ReactiveX/rxjs/issues/2092/labels{/name}","comments_url":"https://api.github.com/repos/ReactiveX/rxjs/issues/2092/comments","events_url":"https://api.github.com/repos/ReactiveX/rxjs/issues/2092/events","html_url":"https://github.com/ReactiveX/rxjs/issues/2092","id":185908104,"number":2092,"title":"Private properties defined in an external npm package interrupt variable assignment","user":{"login":"jeffwhelpley","id":1870060,"avatar_url":"https://avatars.githubusercontent.com/u/1870060?v=3","gravatar_id":"","url":"https://api.github.com/users/jeffwhelpley","html_url":"https://github.com/jeffwhelpley","followers_url":"https://api.github.com/users/jeffwhelpley/followers","following_url":"https://api.github.com/users/jeffwhelpley/following{/other_user}","gists_url":"https://api.github.com/users/jeffwhelpley/gists{/gist_id}","starred_url":"https://api.github.com/users/jeffwhelpley/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jeffwhelpley/subscriptions","organizations_url":"https://api.github.com/users/jeffwhelpley/orgs","repos_url":"https://api.github.com/users/jeffwhelpley/repos","events_url":"https://api.github.com/users/jeffwhelpley/events{/privacy}","received_events_url":"https://api.github.com/users/jeffwhelpley/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-10-28T12:12:18Z","updated_at":"2016-10-28T12:12:18Z","closed_at":null,"body":"<!--\r\nThank you for raising your concerns, we appreciate your feedback and contributions to this repository.\r\n\r\nBefore you continue, consider the following:\r\n\r\nIf you have a \"How do I do ...?\" question, it is better for you and for us that this question is placed in [StackOverflow](http://stackoverflow.com/questions/tagged/rxjs5) or some chat channel. This way, you are making it easier for others to learn from your experiences too.\r\n\r\nThese \"Issues\" are meant only for technical problems, bugs, and proposals related to the library.\r\n\r\nIf your issue is a bug, please follow the format below:\r\n-->\r\n\r\n**RxJS version:** 5.0.0-beta.12\r\n\r\n**Code to reproduce:**\r\n\r\n```\r\n// in one npm module A\r\nexport class HttpAdapter {\r\n    request(url: string, options?: HttpRequestOptionsArgs): Observable<HttpResponse> {\r\n        return Observable.of({});\r\n    }\r\n}\r\n\r\n// in completely separate npm module B that references module A\r\n// issue occurs when you do npm link from module B to A \r\nexport class HttpRequestAdapter implements HttpAdapter {\r\n    request(url: string, options?: HttpRequestOptionsArgs): Observable<HttpResponse> {\r\n        return Observable.of({});\r\n    }\r\n}\r\n```\r\n\r\n**Expected behavior:** No Errors\r\n\r\n**Actual behavior:**\r\n\r\n```\r\nError:(10, 14) TS2420:Class 'HttpRequestAdapter' incorrectly implements interface 'HttpAdapter'.\r\n  Types of property 'request' are incompatible.\r\n    Type '(url: string, options?: HttpRequestOptionsArgs) => Observable<HttpResponse>' is not assignable to type '(url: string, options?: HttpRequestOptionsArgs) => Observable<HttpResponse>'.\r\n      Type 'Observable<HttpResponse>' is not assignable to type 'Observable<HttpResponse>'.\r\n        Property 'source' is protected but type 'Observable<T>' is not a class derived from 'Observable<T>'.\r\n```\r\n\r\n**Additional information:**\r\n\r\nAccording to [this open TypeScript issue](https://github.com/Microsoft/TypeScript/issues/6496#issuecomment-256828753) this problem appears because of private variables within the Observable type. Technically this should be a bug that is fixed within TypeScript, but it would be extremely helpful if in the meantime we could make the Observable properties public so that npm linking works as expected. It seems like this is something that may not be resolved in the TypeScript lib for some time.\r\n"}}
{"actor":{"display_login":"jeffwhelpley"}}