Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@empiricalrun/r2-uploader

Package Overview
Dependencies
Maintainers
0
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@empiricalrun/r2-uploader - npm Package Compare versions

Comparing version 0.3.4 to 0.3.5

6

CHANGELOG.md
# @empiricalrun/r2-uploader
## 0.3.5
### Patch Changes
- 5901db5: fix: add logs for uploader
## 0.3.4

@@ -4,0 +10,0 @@

1

dist/upload/index.js

@@ -58,2 +58,3 @@ "use strict";

}));
console.log("Got request to upload following files:", JSON.stringify(files, null, 2));
const config = {

@@ -60,0 +61,0 @@ accountId: accountId || process.env.R2_ACCOUNT_ID,

@@ -34,2 +34,3 @@ "use strict";

const createMultipartUploadCommand = new client_s3_1.CreateMultipartUploadCommand(createMultipartUploadParams);
console.log("sending a multipart upload command for file", file.fileName);
const { UploadId } = await S3.send(createMultipartUploadCommand);

@@ -40,2 +41,3 @@ const partSize = 5 * 1024 * 1024; // 5MB

});
console.log("file stream created successfully for file", file.fileName);
let partNumber = 1;

@@ -55,2 +57,3 @@ const parts = [];

const { ETag } = await S3.send(uploadPartCommand);
console.log("upload part command sent successfully for file", file.fileName);
parts.push({ ETag: ETag, PartNumber: partNumber });

@@ -82,3 +85,5 @@ partNumber++;

const completeMultipartUploadCommand = new client_s3_1.CompleteMultipartUploadCommand(completeMultipartUploadParams);
console.log("file uploaded successfully for file. sending complete multipart request", file.fileName);
await S3.send(completeMultipartUploadCommand);
console.log("multipart upload complete for file", file.fileName);
const getObjectCommand = new client_s3_1.GetObjectCommand({

@@ -88,3 +93,5 @@ Bucket: config.bucket,

});
console.log("getting a signed url for file", file.fileName);
const fileUrl = await (0, s3_request_presigner_1.getSignedUrl)(S3, getObjectCommand);
console.log("signed url successfully fetched for file", file.fileName);
urls[file.fileName] = fileUrl;

@@ -91,0 +98,0 @@ }));

2

package.json
{
"name": "@empiricalrun/r2-uploader",
"version": "0.3.4",
"version": "0.3.5",
"publishConfig": {

@@ -5,0 +5,0 @@ "registry": "https://registry.npmjs.org/",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc