-
-
Notifications
You must be signed in to change notification settings - Fork 15
Comparing changes
Open a pull request
base repository: MetaMask/utils
base: v8.1.0
head repository: MetaMask/utils
compare: v8.2.0
- 13 commits
- 23 files changed
- 8 contributors
Commits on Sep 15, 2023
-
Configuration menu - View commit details
-
Copy full SHA for 4589c75 - Browse repository at this point
Copy the full SHA 4589c75View commit details
Commits on Oct 8, 2023
-
Bump postcss from 8.4.23 to 8.4.31 (#143)
Bumps [postcss](https://github.com/postcss/postcss) from 8.4.23 to 8.4.31. - [Release notes](https://github.com/postcss/postcss/releases) - [Changelog](https://github.com/postcss/postcss/blob/main/CHANGELOG.md) - [Commits](postcss/postcss@8.4.23...8.4.31) --- updated-dependencies: - dependency-name: postcss dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Configuration menu - View commit details
-
Copy full SHA for d550df6 - Browse repository at this point
Copy the full SHA d550df6View commit details
Commits on Oct 10, 2023
-
Bump @metamask/auto-changelog from 3.2.0 to 3.3.0 (#142)
* Bump @metamask/auto-changelog from 3.2.0 to 3.3.0 Bumps [@metamask/auto-changelog](https://github.com/MetaMask/auto-changelog) from 3.2.0 to 3.3.0. - [Release notes](https://github.com/MetaMask/auto-changelog/releases) - [Changelog](https://github.com/MetaMask/auto-changelog/blob/main/CHANGELOG.md) - [Commits](MetaMask/auto-changelog@v3.2.0...v3.3.0) --- updated-dependencies: - dependency-name: "@metamask/auto-changelog" dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> * yarn dedupe --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: legobt <6wbvkn0j@anonaddy.me>
Configuration menu - View commit details
-
Copy full SHA for b8cf222 - Browse repository at this point
Copy the full SHA b8cf222View commit details
Commits on Oct 16, 2023
-
Configuration menu - View commit details
-
Copy full SHA for 8732f00 - Browse repository at this point
Copy the full SHA 8732f00View commit details -
* Use tsup for bundling * Simplify CI workflows * Remove unused dependency * Remove unnecessary config option * Use `tsc` for generating declarations * Fix formatting of package.json * Enable code splitting * Revert some changes
Configuration menu - View commit details
-
Copy full SHA for 184d425 - Browse repository at this point
Copy the full SHA 184d425View commit details
Commits on Oct 17, 2023
-
Bump @babel/traverse from 7.21.4 to 7.23.2 (#147)
* Bump @babel/traverse from 7.21.4 to 7.23.2 Bumps [@babel/traverse](https://github.com/babel/babel/tree/HEAD/packages/babel-traverse) from 7.21.4 to 7.23.2. - [Release notes](https://github.com/babel/babel/releases) - [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md) - [Commits](https://github.com/babel/babel/commits/v7.23.2/packages/babel-traverse) --- updated-dependencies: - dependency-name: "@babel/traverse" dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com> * yarn dedupe --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: legobt <6wbvkn0j@anonaddy.me>
Configuration menu - View commit details
-
Copy full SHA for 739cece - Browse repository at this point
Copy the full SHA 739ceceView commit details -
Configuration menu - View commit details
-
Copy full SHA for f5b86cc - Browse repository at this point
Copy the full SHA f5b86ccView commit details -
This commit satisfies a few needs that we have in various projects: - When catching a throwable from some kind of operation, we want to be able to test whether the throwable is an error. - Furthermore, since the Error interface in TypeScript is pretty simple, we want to be able to test for different properties on an error (`code`, `stack`, etc.). - We want to wrap an error produced by a lower level part of the system with a different message, but preserve the original error using the `cause` property (note: this property was added in Node 18, so for older Nodes, we use the `pony-cause` library to set this). - We want to be able to take a throwable and produce an error that has a stacktrace. This is particularly useful for working with the `fs.promises` module, which (as of Node 22) [does not produce proper stacktraces][1]. - We want to be able to get a message from a throwable. [1]: nodejs/node#30944 --------- Co-authored-by: Jongsun Suh <34228073+MajorLift@users.noreply.github.com> Co-authored-by: legobeat <109787230+legobeat@users.noreply.github.com>
Configuration menu - View commit details
-
Copy full SHA for 2263f9b - Browse repository at this point
Copy the full SHA 2263f9bView commit details -
devDeps: depcheck@^1.4.3->^1.4.7 (#149)
* devDeps: depcheck@^1.4.3->^1.4.7 * update depcheckrc
Configuration menu - View commit details
-
Copy full SHA for d0db51f - Browse repository at this point
Copy the full SHA d0db51fView commit details -
This commit adds several utility functions that are related to the filesystem in some way. - Most of the functions here are wrappers around basic filesystem operations with better error handling. Node's `fs.promises` module is somewhat difficult to work with because [the errors it produces lack proper stacktraces][1]. The functions that directly use `fs.promises` wrap caught errors in order to supply the missing stacktraces. - Two functions make it easier to read and write JSON files (with support for JSON-compatible interfaces, such as [JSON5][2]). - One function, `createSandbox`, is designed to wrap tests that need a temporary directory to work within, such as those for a command-line tool that makes changes to the filesystem. Here are places where we currently use these utilities (or something like them): - https://github.com/MetaMask/action-utils/blob/54ddd730746668cb4c1c88b4edfa720cbecf5e32/src/file-utils.ts - https://github.com/MetaMask/create-release-branch/blob/3556dee47163c921186051be7a1f3c98e2049db9/src/fs.ts - https://github.com/MetaMask/create-release-branch/blob/3556dee47163c921186051be7a1f3c98e2049db9/tests/helpers.ts One note about these utilities is that they require Node to use and will not work in the browser. Because we already create two kinds of bundles, one for CommonJS and another ESM, it would be difficult to create a second level of bundles, one for Node and another for the browser. Instead of requiring more complexity around the bundle configuration, this commit instead introduces another way to import the package. By default, you'll get all exports that are guaranteed to be cross-platform. That means that the file utilities won't show up: ``` typescript // ❌ import { readFile } from "@metamask/utils"; ``` If you want all of the cross-platform exports plus the Node-specific ones, you will have to import "@metamask/utils/node". For instance: ``` typescript // ✅ import { readFile } from "@metamask/utils/node"; ``` Note that you will need to use a `moduleResolution` of `nodenext` (and not `node`) in your TypeScript project in order to take advantage of this. [1]: nodejs/node#30944 [2]: https://www.npmjs.com/package/json5 --- Co-authored-by: Maarten Zuidhoorn <maarten@zuidhoorn.com> Co-authored-by: legobeat <109787230+legobeat@users.noreply.github.com>
Configuration menu - View commit details
-
Copy full SHA for 12b5003 - Browse repository at this point
Copy the full SHA 12b5003View commit details
Commits on Oct 19, 2023
-
Add struct utils for validating JSON objects with optional values (#136)
* Add struct utils for validating JSON objects with optional values * Add type tests * Update existing structs to use jsonObject struct * Add test for coverage * Fix type of InferWithParams * Rename to object and exactOptional * Fix type test * Remove unused imports * Rename test names * Address review comments * Update src/json.test.ts Co-authored-by: Elliot Winkler <elliot.winkler@gmail.com> * Update src/json.ts Co-authored-by: Elliot Winkler <elliot.winkler@gmail.com> * Update snapshots * Move some tests --------- Co-authored-by: Elliot Winkler <elliot.winkler@gmail.com>
Configuration menu - View commit details
-
Copy full SHA for 0d68084 - Browse repository at this point
Copy the full SHA 0d68084View commit details -
Add missing exports for error utilities (#151)
These exports should have been included in a previous commit but were left out.
Configuration menu - View commit details
-
Copy full SHA for 2f0005a - Browse repository at this point
Copy the full SHA 2f0005aView commit details
Commits on Oct 20, 2023
-
* 8.2.0 * Update CHANGELOG.md * Add extra PR for error utils --------- Co-authored-by: github-actions <github-actions@github.com> Co-authored-by: Maarten Zuidhoorn <maarten@zuidhoorn.com> Co-authored-by: Elliot Winkler <elliot.winkler@gmail.com> Co-authored-by: legobeat <109787230+legobeat@users.noreply.github.com>
Configuration menu - View commit details
-
Copy full SHA for 9452f88 - Browse repository at this point
Copy the full SHA 9452f88View commit details
This comparison is taking too long to generate.
Unfortunately it looks like we can’t render this comparison for you right now. It might be too big, or there might be something weird with your repository.
You can try running this command locally to see the comparison on your machine:
git diff v8.1.0...v8.2.0