You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to upload a package, but the method ComputePackage() only accepts an os.File. This means it requires a physical file to upload anything. Instead it should be possible to upload bytes straight from memory, e.g to upload something from an S3 bucket for example. Or to upload something from an embedded file (embed.FS).
For the latter to work the *os.File argument can just be turned into a fs.File (it covers both). For the first it probably requires a new method that just accepts bytes.
If ReadAt() is required, then the method should specify io.ReaderAt as the argument type. In that case the library user can determine how to implement this.
The text was updated successfully, but these errors were encountered:
I'll create an internal ticket to track this work but I won't be able to provide an ETA for when this will be done.
This API client is generated from OpenAPI schemas (see blog post). We'll need to dig into the existing templates (that are from the open-source project OpenAPI Generator) and see what modifications we can make.
Version
v1.0.0-beta.22
What happened
I'm trying to upload a package, but the method
ComputePackage()
only accepts an os.File. This means it requires a physical file to upload anything. Instead it should be possible to upload bytes straight from memory, e.g to upload something from an S3 bucket for example. Or to upload something from an embedded file (embed.FS).For the latter to work the *os.File argument can just be turned into a fs.File (it covers both). For the first it probably requires a new method that just accepts bytes.
If ReadAt() is required, then the method should specify io.ReaderAt as the argument type. In that case the library user can determine how to implement this.
The text was updated successfully, but these errors were encountered: