Switch from `request` to `axios` is a breaking change?

Aperta
#678 11 commenti 8 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
15/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Ferma
Stack tecnologico
nodejs, typescript
Ambito
api

Direzione di ricerca

The issue compares the return type of SDK API methods before and after the request to axios switch, using the linked request and Axios type definitions. Start by checking what the public methods return in version 5.0.0 and what its release notes say about the change. Done means a maintainer decision on whether the response shape is restored or the change is documented as breaking, with the decision reflected in the changelog or docs.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

SDK you're using (please complete the following information):

  • Version >=5.0.0

Describe the bug
Release notes for version 5.0.0 list a bug fix:

https://github.com/XeroAPI/xero-node/issues/579 | Get rid of deprecated "request" dependency

Switching out the request package for axios changes the response shape for the SDK API methods. Previously they returned a request response whereas now they return an AxiosResponse.

As you can see these responses have a different shape. IMHO changing the response shape of the SDK should be explicitly called out as a breaking change. We didn't pick this up until we noticed runtime errors in production.

Lingua principale
TypeScript
Stelle
264
Fork
177
Merge medio
10h 5m
PR unite (30g)
5

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di XeroAPI/xero-node

Tutte le issue di XeroAPI/xero-node

Issue simili

Altre issue su TypeScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.