Skip to content

Commit 33bd0a4

Browse files
DF-20252 s3-csv-reader removing verbose error messages (#3340)
* DF-20252 s3-csv-reader removing verbose error messages * bucket & keyPrefix input sanitisation + tests * update dependencies * add changeset
1 parent 9f98cbf commit 33bd0a4

29 files changed

+533
-69
lines changed

.changeset/nine-dogs-flow.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
'@chainlink/s3-csv-reader-adapter': minor
3+
---
4+
5+
security mitigations

.pnp.cjs

+160-11
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

packages/sources/s3-csv-reader/README.md

+9-9
Original file line numberDiff line numberDiff line change
@@ -31,14 +31,14 @@ There are no rate limits for this adapter.
3131

3232
### Input Params
3333

34-
| Required? | Name | Aliases | Description | Type | Options | Default | Depends On | Not Valid With |
35-
| :-------: | :-----------: | :----------: | :---------------------------------------------------------------------------------------------------------------: | :----: | :-----: | :-----: | :--------: | :------------: |
36-
|| bucket | | The S3 bucket to query | string | | | | |
37-
|| keyPrefix | `pathPrefix` | The path prefix of the file stored in S3. <Date.csv> is appended to search for older files. | string | | | | |
38-
|| headerRow | | The 1-indexed row of the CSV file that contains the column headers | number | | | | |
39-
|| matcherColumn | | The column field to compare with the matcherValue | string | | | | |
40-
|| matcherValue | | The value to match with matcherField | string | | | | |
41-
|| resultColumn | | The column of the CSV file to return a result for, where the row value for matcherColumn is equal to matcherValue | string | | | | |
34+
| Required? | Name | Aliases | Description | Type | Options | Default | Depends On | Not Valid With |
35+
| :-------: | :-----------: | :----------: | :--------------------------------------------------------------------------------------------------------------------------------------: | :----: | :-----: | :-----: | :--------: | :------------: |
36+
|| bucket | | The S3 bucket to query | string | | | | |
37+
|| keyPrefix | `pathPrefix` | The path prefix of the file stored in S3. Will be prefixed onto <DATE>.csv to search for older files, e.g. 'path/prefix-01-02-2024.csv'. | string | | | | |
38+
|| headerRow | | The 1-indexed row of the CSV file that contains the column headers | number | | | | |
39+
|| matcherColumn | | The column field to compare with the matcherValue | string | | | | |
40+
|| matcherValue | | The value to match with matcherField | string | | | | |
41+
|| resultColumn | | The column of the CSV file to return a result for, where the row value for matcherColumn is equal to matcherValue | string | | | | |
4242

4343
### Example
4444

@@ -48,7 +48,7 @@ Request:
4848
{
4949
"data": {
5050
"endpoint": "csv",
51-
"bucket": "s3_bucket",
51+
"bucket": "s3-bucket",
5252
"keyPrefix": "path/to/file",
5353
"headerRow": 2,
5454
"matcherColumn": "matcherColumn",

packages/sources/s3-csv-reader/package.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -28,16 +28,16 @@
2828
"start": "yarn server:dist"
2929
},
3030
"devDependencies": {
31-
"@types/jest": "27.5.2",
32-
"@types/node": "16.11.68",
31+
"@types/jest": "29.5.12",
32+
"@types/node": "20.14.10",
3333
"nock": "13.5.4",
34-
"typescript": "5.0.4"
34+
"typescript": "5.5.3"
3535
},
3636
"dependencies": {
3737
"@aws-sdk/client-s3": "^3.600.0",
3838
"@chainlink/external-adapter-framework": "1.1.0",
3939
"csv-parse": "5.5.6",
4040
"date-fns": "3.6.0",
41-
"tslib": "2.4.1"
41+
"tslib": "2.6.3"
4242
}
4343
}

0 commit comments

Comments
 (0)