-
Notifications
You must be signed in to change notification settings - Fork 43
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
Fix broken debug
extension
#631
Conversation
🦋 Changeset detectedLatest commit: 87a378c The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
A user has added the prerelease/inngest label, so this PR will be published to npm with the tag You can install this prerelease version with: npm install inngest@pr-631 The last release was built and published from 87a378c. |
## Summary <!-- Succinctly describe your change, providing context, what you've changed, and why. --> [debug](https://www.npmjs.com/package/debug) is a really old library, and its browser detection is old, too. For newer pairings of framework and runtime such as Nitro + Cloudflare Pages, their code for detecting which code should be delivered doesn't catch the markers these leave behind. One silly symptom of this is that `Debug()` returns an anonymous function with no extra properties instead of a `Debugger` instance if the wrong code is consumed following a bad detection. This results in the following `.extend()` call failing. We fix that here by just not calling `.extend()`. ## Checklist <!-- Tick these items off as you progress. --> <!-- If an item isn't applicable, ideally please strikeout the item by wrapping it in "~~"" and suffix it with "N/A My reason for skipping this." --> <!-- e.g. "- [ ] ~~Added tests~~ N/A Only touches docs" --> - [ ] ~Added a [docs PR](https://github.com/inngest/website) that references this PR~ N/A Bug fix - [ ] ~Added unit/integration tests~ N/A Will add a Nitro example in another PR - [x] Added changesets if applicable
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated. # Releases ## inngest@3.19.19 ### Patch Changes - [#631](#631) [`ac6796c`](ac6796c) Thanks [@jpwilliams](https://github.com/jpwilliams)! - Fix exception being thrown from `debug` when used with Nitro running on Cloudflare Pages - [`191fe36`](191fe36) Thanks [@jpwilliams](https://github.com/jpwilliams)! - Fix failure handlers incorrectly inheriting config options such as `batchEvents` and `concurrency` from their parent function - [#630](#630) [`d4de6d7`](d4de6d7) Thanks [@stefanosala](https://github.com/stefanosala)! - Fix missing config fields such as `concurrency` when validating Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Summary
debug is a really old library, and its browser detection is old, too. For newer pairings of framework and runtime such as Nitro + Cloudflare Pages, their code for detecting which code should be delivered doesn't catch the markers these leave behind.
One silly symptom of this is that
Debug()
returns an anonymous function with no extra properties instead of aDebugger
instance if the wrong code is consumed following a bad detection. This results in the following.extend()
call failing.We fix that here by just not calling
.extend()
.Checklist
Added a docs PR that references this PRN/A Bug fixAdded unit/integration testsN/A Will add a Nitro example in another PR