jira-node / node-jira-client

A Node.js wrapper for the Jira REST API
https://jira-node.github.io/
MIT License
450 stars 169 forks source link

Consider moving from Request to Got #300

Open HallvardMM opened 4 years ago

HallvardMM commented 4 years ago

request has been deprecated, see https://github.com/request/request/issues/3142 consider moving to https://github.com/sindresorhus/got

pioug commented 4 years ago

If request being deprecated is an issue, I would argue that switching to a fork like https://www.npmjs.com/package/postman-request would be more than enough 😅

If we want to reduce the size of the package, got would be nice indeed. If anyone wants to work it, they are welcome 👍 I can grant people access to the organization. I don't think it would be simple drop-in replacement. I am afraid it requires properly documenting all the breaking changes and probably handling the related issues on the repo, etc. I am not ready myself to invest time into a migration 😓

romanbalayan commented 4 years ago

Do you think it is worth-while to do the migration to got (or other alternatives) given the deprecation of request. I started trying to do this - already working with basic authentication using got, but all the tests are currently breaking.

Can give this a shot, although I'm not sure if this is a direction the project is looking to move forward with?

pioug commented 4 years ago

@romanbalayan Technically, I think the migration is worthwhile. If I were paid to maintain this project, I would have done it a long time ago 😅

If you make it work, I am okay to go with this migration. I'll add one more condition though: In the case the package takes your changes, I would also appreciate if you assume ownership and join the project to help actively with support and maintenance in relation to the migration.

Regarding the tests, they are maybe quick to adjust. The code is designed in a way that "request" is called in one place only. Can you share a link to you changes? I am also curious if there is any feature that request supports but can't be backported to got.

romanbalayan commented 3 years ago

I'll tidy up and create a fork of this. Currently I'm not sure about the oauth support. I think it could be done, but im not too familiar with it yet.

romanbalayan commented 3 years ago

@pioug,

This is the current work in progress version using got: https://github.com/romanbalayan/node-jira-client/tree/feat-got-migration,

Currently working on a local project, tested to work with Basic Auth for log in, searchIssues, and downloadAttachment methods.