Skip to content

[TS][Angular1&2][Node] Extends obj using Object.assign #4562

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 17, 2017
Merged

[TS][Angular1&2][Node] Extends obj using Object.assign #4562

merged 1 commit into from
Jan 17, 2017

Conversation

damienpontifex
Copy link
Contributor

PR checklist

  • Read the contribution guildelines.
  • Ran the shell/batch script under ./bin/ to update Petstore sample so that CIs can verify the change. (For instance, only need to run ./bin/{LANG}-petstore.sh and ./bin/security/{LANG}-petstore.sh if updating the {LANG} (e.g. php, ruby, python, etc) code generator or {LANG} client's mustache templates)
  • Filed the PR against the correct branch: master for non-breaking changes and 2.3.0 branch for breaking (non-backward compatible) changes.

Description of the PR

Resolves #4407 (replacing PR #4409 with better backwards compatibility) by using Object.assign for object copying.

@wing328
Copy link
Contributor

wing328 commented Jan 16, 2017

@damienpontifex thanks for the PR. The CI (travis) failed due to

[INFO] TS Node npm Petstore Client ....................... FAILURE [11.932s]

with the following error messages:

[INFO] 
[INFO] --- exec-maven-plugin:1.2.1:exec (npm-run-build) @ TypeScriptNodeNPMPestoreClientTests ---

> @swagger/[email protected] build /home/travis/build/swagger-api/swagger-codegen/samples/client/petstore/typescript-node/npm
> tsc

client.ts(37,52): error TS2345: Argument of type 'ReadStream' is not assignable to parameter of type 'Buffer'.
  Property 'write' is missing in type 'ReadStream'.

npm ERR! Linux 4.4.0-51-generic
npm ERR! argv "/home/travis/.nvm/versions/node/v4.1.2/bin/node" "/home/travis/.nvm/versions/node/v4.1.2/bin/npm" "run" "build"
npm ERR! node v4.1.2
npm ERR! npm  v2.14.4
npm ERR! code ELIFECYCLE
npm ERR! @swagger/[email protected] build: `tsc`
npm ERR! Exit status 2
npm ERR! 
npm ERR! Failed at the @swagger/[email protected] build script 'tsc'.
npm ERR! This is most likely a problem with the @swagger/angular2-typescript-petstore package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     tsc
npm ERR! You can get their info via:
npm ERR!     npm owner ls @swagger/angular2-typescript-petstore
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!     /home/travis/build/swagger-api/swagger-codegen/samples/client/petstore/typescript-node/npm/npm-debug.log

Ref: https://s3.amazonaws.com/archive.travis-ci.org/jobs/192219854/log.txt

Please take a look when you've time.

@damienpontifex
Copy link
Contributor Author

Thanks @wing328 just a small node issue. Fixed up and ready for review. Also @todrules might be interested for review

@wing328
Copy link
Contributor

wing328 commented Jan 17, 2017

@damienpontifex thanks for the quick fix and this PR looks good to me. Thanks for the enhancement 👍

@wing328 wing328 merged commit 55443da into swagger-api:master Jan 17, 2017
@wing328 wing328 added this to the v2.2.2 milestone Jan 17, 2017
@damienpontifex damienpontifex deleted the tsc-extendobj branch January 17, 2017 02:54
@wing328 wing328 changed the title Extends obj using Object.assign [TS][Angular1&2][Node] Extends obj using Object.assign Feb 20, 2017
davidgri pushed a commit to davidgri/swagger-codegen that referenced this pull request May 11, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants