[Snyk] Upgrade axios from 0.25.0 to 1.12.2#1
Conversation
Snyk has created this PR to upgrade axios from 0.25.0 to 1.12.2. See this package in npm: axios See this project in Snyk: https://app.snyk.io/org/dustin4444/project/41dd6cc3-3164-418b-8f1d-f911ea47ab64?utm_source=github&utm_medium=referral&page=upgrade-pr
|
Important Review skippedIgnore keyword(s) in the title. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the ✨ Finishing touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary of ChangesHello @Dustin4444, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request, automatically generated by Snyk, updates the Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request upgrades axios from version 0.25.0 to 1.12.2. This is a significant major version upgrade that addresses multiple security vulnerabilities, including high-severity Cross-site Request Forgery (CSRF) and Improper Handling of Extra Parameters. While this upgrade is crucial for security, the large version jump introduces potential breaking changes. It is highly recommended to perform thorough testing to ensure that the application's functionality, especially parts relying on axios for HTTP requests, remains intact. Pay special attention to error handling, as the structure of error objects has changed in axios v1.0.
| "dependencies": { | ||
| "@alch/alchemy-web3": "^1.1.12", | ||
| "axios": "^0.25.0", | ||
| "axios": "^1.12.2", |
There was a problem hiding this comment.
This is a major version upgrade for axios which introduces breaking changes. One of the most notable changes is in error handling. With axios v1.x, it's best practice to check if an error is an Axios-specific error and handle it accordingly for more robust error logging. For example, the existing console.log(error) in axios-script.js could be improved to provide more details on failures:
.catch(function (error) {
if (axios.isAxiosError(error)) {
// The request was made and the server responded with a status code
// that falls out of the range of 2xx
console.error('Axios error:', error.message);
if (error.response) {
console.error('Data:', error.response.data);
console.error('Status:', error.response.status);
}
} else if (error.request) {
// The request was made but no response was received
console.error('Request error:', error.request);
} else {
// Something happened in setting up the request that triggered an Error
console.error('Error', error.message);
}
});Updating the error handling logic where axios is used is recommended to align with the new version's capabilities and avoid potential runtime issues.
Snyk has created this PR to upgrade axios from 0.25.0 to 1.12.2.
ℹ️ Keep your dependencies up-to-date. This makes it easier to fix existing vulnerabilities and to more quickly identify and fix newly disclosed vulnerabilities when they affect your project.
The recommended version is 68 versions ahead of your current version.
The recommended version was released 21 days ago.
Issues fixed by the recommended upgrade:
SNYK-JS-AXIOS-6032459
SNYK-JS-FOLLOWREDIRECTS-6141137
SNYK-JS-AXIOS-12613773
SNYK-JS-AXIOS-6124857
SNYK-JS-AXIOS-9292519
SNYK-JS-AXIOS-9403194
SNYK-JS-FOLLOWREDIRECTS-6444610
SNYK-JS-FOLLOWREDIRECTS-2396346
Release notes
Package name: axios
-
1.12.2 - 2025-09-14
- fetch: use current global fetch instead of cached one when env fetch is not specified to keep MSW support; (#7030) (cf78825)
Dmitriy Mozgovoy
Noritaka Kobayashi
-
1.12.1 - 2025-09-12
- types: fixed env config types; (#7020) (b5f26b7)
Dmitriy Mozgovoy
-
1.12.0 - 2025-09-11
- adding build artifacts (9ec86de)
- dont add dist on release (a2edc36)
- fetch-adapter: set correct Content-Type for Node FormData (#6998) (a9f47af)
- node: enforce maxContentLength for data: URLs (#7011) (945435f)
- package exports (#5627) (aa78ac2)
- params: removing '[' and ']' from URL encode exclude characters (#3316) (#5715) (6d84189)
- release pr run (fd7f404)
- types: change the type guard on isCancel (#5595) (0dbb7fd)
- adapter: surface low‑level network error details; attach original error via cause (#6982) (78b290c)
- fetch: add fetch, Request, Response env config variables for the adapter; (#7003) (c959ff2)
- support reviver on JSON.parse (#5926) (2a97634), closes #5924
- types: extend AxiosResponse interface to include custom headers type (#6782) (7960d34)
Willian Agostini
Dmitriy Mozgovoy
khani
Ameer Assadi
Emiedonmokumo Dick-Boro
Zeroday BYTE
Jason Saayman
최예찬
Gligor Kotushevski
Aleksandar Dimitrov
-
1.11.0 - 2025-07-23
- form-data npm pakcage (#6970) (e72c193)
- prevent RangeError when using large Buffers (#6961) (a2214ca)
- types: resolve type discrepancies between ESM and CJS TypeScript declaration files (#6956) (8517aa1)
izzy goldman
Manish Sahani
Noritaka Kobayashi
James Nail
Tejaswi1305
-
1.10.0 - 2025-06-14
- adapter: pass fetchOptions to fetch function (#6883) (0f50af8)
- form-data: convert boolean values to strings in FormData serialization (#6917) (5064b10)
- package: add module entry point for React Native; (#6933) (3d343b8)
- types: improved fetchOptions interface (#6867) (63f1fce)
Dmitriy Mozgovoy
Noritaka Kobayashi
Dimitrios Lazanas
Adrian Knapp
Howie Zhao
Uhyeon Park
Sampo Silvennoinen
-
1.9.0 - 2025-04-24
- core: fix the Axios constructor implementation to treat the config argument as optional; (#6881) (6c5d4cd)
- fetch: fixed ERR_NETWORK mapping for Safari browsers; (#6767) (dfe8411)
- headers: allow iterable objects to be a data source for the set method; (#6873) (1b1f9cc)
- headers: fix
- headers: fixed support for setting multiple header values from an iterated source; (#6885) (f7a3b5e)
- http: send minimal end multipart boundary (#6661) (987d2e2)
- types: fix autocomplete for adapter config (#6855) (e61a893)
- AxiosHeaders: add getSetCookie method to retrieve set-cookie headers values (#5707) (80ea756)
Dmitriy Mozgovoy
Jay
Willian Agostini
George Cheng
FatahChan
Ionuț G. Stan
-
1.8.4 - 2025-03-19
- buildFullPath: handle
Marc Hassan
-
1.8.3 - 2025-03-12
- add missing type for allowAbsoluteUrls (#6818) (10fa70e)
- xhr/fetch: pass
Ashcon Partovi
StefanBRas
Marc Hassan
-
1.8.2 - 2025-03-07
-
1.8.1 - 2025-02-26
-
1.8.0 - 2025-02-26
-
1.7.9 - 2024-12-04
-
1.7.8 - 2024-11-25
-
1.7.7 - 2024-08-31
-
1.7.6 - 2024-08-30
-
1.7.5 - 2024-08-23
-
1.7.4 - 2024-08-13
-
1.7.3 - 2024-08-01
-
1.7.2 - 2024-05-21
-
1.7.1 - 2024-05-20
-
1.7.0 - 2024-05-19
-
1.7.0-beta.2 - 2024-05-19
-
1.7.0-beta.1 - 2024-05-07
-
1.7.0-beta.0 - 2024-04-28
-
1.6.8 - 2024-03-15
-
1.6.7 - 2024-01-25
-
1.6.6 - 2024-01-24
-
1.6.5 - 2024-01-05
-
1.6.4 - 2024-01-03
-
1.6.3 - 2023-12-26
-
1.6.2 - 2023-11-14
-
1.6.1 - 2023-11-08
-
1.6.0 - 2023-10-26
-
1.5.1 - 2023-09-26
-
1.5.0 - 2023-08-26
-
1.4.0 - 2023-04-27
-
1.3.6 - 2023-04-19
-
1.3.5 - 2023-04-05
-
1.3.4 - 2023-02-22
-
1.3.3 - 2023-02-13
-
1.3.2 - 2023-02-03
-
1.3.1 - 2023-02-01
-
1.3.0 - 2023-01-31
-
1.2.6 - 2023-01-28
-
1.2.5 - 2023-01-26
-
1.2.4 - 2023-01-24
-
1.2.3 - 2023-01-17
-
1.2.2 - 2022-12-29
-
1.2.1 - 2022-12-05
-
1.2.0 - 2022-11-22
-
1.2.0-alpha.1 - 2022-11-10
-
1.1.3 - 2022-10-15
-
1.1.2 - 2022-10-07
-
1.1.1 - 2022-10-07
-
1.1.0 - 2022-10-06
-
1.0.0 - 2022-10-04
-
1.0.0-alpha.1 - 2022-05-31
-
0.30.2 - 2025-09-27
-
0.30.1 - 2025-08-04
- chore(deps): bump form-data from 4.0.0 to 4.0.4 for v0.x by @ wolandec in #6978
- @ wolandec made their first contribution in #6978
-
0.30.0 - 2025-03-26
- fix: modify log while request is aborted by @ mori5321 in #4917
- fix: update CHANGELOG.md for v0.x by @ TehZarathustra in #6271
- fix: modify upgrade guide for 0.28.1's breaking change by @ nafeger in #6787
- fix: backport allowAbsoluteUrls vulnerability fix to v0.x by @ thatguyinabeanie in #6829
- fix: add allowAbsoluteUrls type by @ thatguyinabeanie in #6849
- @ mori5321 made their first contribution in #4917
- @ TehZarathustra made their first contribution in #6271
- @ nafeger made their first contribution in #6787
- @ thatguyinabeanie made their first contribution in #6829
-
0.29.0 - 2024-11-21
-
0.28.1 - 2024-03-28
-
0.28.0 - 2024-02-12
-
0.27.2 - 2022-04-27
-
0.27.1 - 2022-04-26
-
0.27.0 - 2022-04-25
-
0.26.1 - 2022-03-09
-
0.26.0 - 2022-02-13
-
0.25.0 - 2022-01-18
from axios GitHub release notesRelease notes:
Bug Fixes
Contributors to this release
Release notes:
Bug Fixes
Contributors to this release
Release notes:
Bug Fixes
Features
Contributors to this release
Release notes:
Bug Fixes
Contributors to this release
Release notes:
Bug Fixes
Features
Contributors to this release
Release notes:
Bug Fixes
getSetCookieby using 'get' method for caseless access; (#6874) (d4f7df4)Features
Contributors to this release
Release notes:
Bug Fixes
allowAbsoluteUrls: falsewithoutbaseURL(#6833) (f10c2e0)Contributors to this release
Release notes:
Bug Fixes
allowAbsoluteUrlstobuildFullPathinxhrandfetchadapters (#6814) (ec159e5)Contributors to this release
Release notes:
Bug Fixes
Contributors to this release
Full Changelog: v0.30.0...v0.30.1
Release notes:
Bug Fixes
Contributors to this release
Full Changelog: v0.29.0...v0.30.0
Important
Note: You are seeing this because you or someone else with access to this repository has authorized Snyk to open upgrade PRs.
For more information: