Feature Request: async preprocess
See original GitHub issueI’m trying to parse some minecraft NBT data with zod. However, in order to do this, one key of the object (item_bytes
) first needs to be converted from the binary NBT format to a JSON-like structure.
The best way to implement this in my opinion would be to use zod’s z.preprocess()
. Unfortunately, the library I’m using prismarine-nbt
only exposes parse
as an async
function.
As far as I can tell, async preprocessing is not supported right now. I think it would be great if it’s allowed as it would really simplify parsing with async
libraries.
I’d suggest either z.preprocess(async () => { /* ... */ }, z.any())
or z.preprocessAsync(async () => { /* ... */ }, z.any())
as I think either would be reasonable from an API standpoint.
Issue Analytics
- State:
- Created 2 years ago
- Comments:9 (5 by maintainers)
Top Results From Across the Web
Asynchronous inference - Amazon SageMaker
Amazon SageMaker Asynchronous Inference is a new capability in SageMaker that queues incoming requests and processes them asynchronously.
Read more >Feature preprocessing overview | BigQuery ML - Google Cloud
Feature preprocessing is one of the most important steps in developing a machine learning model. It consists of the creation of features as...
Read more >Support for creating asynchronous endpoints with my ... - GitHub
I would like to create an asynchronous inference endpoint with my own model, preprocessing and inference code with the SageMaker middle-level ...
Read more >Run Async Requests with the Batch Endpoint Guide - Mailchimp
Depending on your server language or architecture, you may not want a request to the Marketing API to block other threads. Batch requests...
Read more >4483 - Feature Request: Support async/await functions - v8
I actually think stepping for generators are fine, but for async funcions are not. Generators expose its resumable behavior via yield expression, which...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Yep, seems like an oversight, should be a quick addition. I’ll look into it.
@stale don’t