Skip to content
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

feat(jmespath): add JMESPath utility #2135

Closed
wants to merge 104 commits into from
Closed
Changes from 1 commit
Commits
Show all changes
104 commits
Select commit Hold shift + click to select a range
5687ca0
feat(logger): Support for external observability providers (#1511)
erikayao93 Jun 30, 2023
e4ab44a
feat(logger): Support for external observability providers (#1511)
erikayao93 Jun 30, 2023
9d98c86
chore(logger): PowertoolsLogFormatter docstring and variable naming u…
erikayao93 Jul 7, 2023
6d1bfba
chore(maintenance): bump dependencies & drop nodejs14x (#1687)
dreamorosi Sep 16, 2023
e6279bb
chore: update release script to mark all utilities as alpha
dreamorosi Sep 18, 2023
dc44030
chore: release version change
dreamorosi Sep 27, 2023
dc3f642
chore: release version change
dreamorosi Sep 27, 2023
67e5e94
chore(maintenance): remove `createLogger` and `createTracer` helpers …
dreamorosi Oct 2, 2023
9e3a811
feat(logger): add esmodule support (#1734)
antstanley Oct 11, 2023
74842c8
feat(commons): add esmodule support (#1735)
dreamorosi Oct 11, 2023
54b3f27
feat(internal): add esmodule support (#1738)
dreamorosi Oct 12, 2023
1f41355
chore(ci): v2 release line
dreamorosi Oct 14, 2023
0f52ad1
chore(ci): fix alpha versioning pre-release
dreamorosi Oct 15, 2023
0d82499
docs(maintenance): add processes tab (#1747)
dreamorosi Oct 18, 2023
b4853de
chore: remove extra comma
dreamorosi Oct 18, 2023
9f50daa
chore(logger): refactor types and interfaces (#1758)
dreamorosi Oct 20, 2023
b08e589
chore(maintenance): bump Middy v4 & run tests (#1760)
dreamorosi Oct 20, 2023
cf8750f
chore(layers) widen version check in e2e
dreamorosi Oct 21, 2023
60c816f
chore(maintenance): enable `isolatedModules` and isolate cache (#1765)
dreamorosi Oct 23, 2023
0f29fea
fix: idempotency types
dreamorosi Oct 30, 2023
6275601
build(maintenance): bump aws sdk dev dependencies
dreamorosi Oct 31, 2023
2931c5a
fix(metrics): deduplicate dimensions when serialising (#1780)
am29d Nov 2, 2023
e32f74a
chore(release): v1.14.2 [skip ci]
github-actions[bot] Nov 3, 2023
8cef57d
chore(release): v1.15.0 [skip ci]
github-actions[bot] Nov 14, 2023
12bd0e0
chore(release): v1.16.0 [skip ci]
github-actions[bot] Nov 16, 2023
ec76a4f
chore(maintenance): drop support for Node.js 14 (#1802)
dreamorosi Nov 24, 2023
0fe1db1
chore: package lock
dreamorosi Nov 24, 2023
7240afa
chore(maintenance): add --require-hashes flag to pip installs (#1827)
dreamorosi Dec 20, 2023
e5d271d
bump version to 9.5.2, rerun pip-compile with correct deps (#1830)
am29d Dec 21, 2023
32f5835
chore(ci): Dependabot fine tuning (#1862)
am29d Jan 9, 2024
6ed197b
chore(deps-dev): bump @aws-sdk/client-cloudwatch from 3.438.0 to 3.48…
dependabot[bot] Jan 9, 2024
d9efd4a
chore(deps): fix dependencies and dependabot config (#1917)
dreamorosi Jan 16, 2024
abc7c3f
chore(deps-dev): bump @typescript-eslint/parser from 6.19.0 to 6.19.1…
dependabot[bot] Jan 25, 2024
330d9f9
chore(deps-dev): bump @typescript-eslint/eslint-plugin (#1948)
dependabot[bot] Jan 25, 2024
330a65c
chore(ci): refactor workflows to scope permissions (#1978)
dreamorosi Jan 26, 2024
96888ec
chore(maintenance): rebase conflicts
dreamorosi Jan 27, 2024
013e230
chore(maintenance): rebase conflicts
dreamorosi Jan 27, 2024
0f6191d
chore: remove v2 specific release
dreamorosi Feb 20, 2024
309fc4d
chore: release patch script
dreamorosi Feb 20, 2024
a31bc25
chore: address SonarCloud findings
dreamorosi Feb 20, 2024
bf0f57c
chore: remove unused dependency
dreamorosi Feb 22, 2024
038b926
wip: jmespath util
dreamorosi Jun 3, 2023
3679907
tests: spec compliance tests
dreamorosi Jun 4, 2023
e3c669d
wip: jmespath util
dreamorosi Jun 4, 2023
2691dcd
wip: jmespath util
dreamorosi Jun 5, 2023
6eaff37
chore: remove visitor class
dreamorosi Jun 5, 2023
31acfab
wip: jmespath functions
dreamorosi Jun 5, 2023
5d9154d
wip: jmespath functions
dreamorosi Jun 5, 2023
da42d54
wip: jmespath treeinterpreter
dreamorosi Jun 5, 2023
30c9eca
chore: exports
dreamorosi Jun 5, 2023
f53ac17
tests: added group header
dreamorosi Jun 6, 2023
46a0656
tests: 68% compliance with spec
dreamorosi Jun 6, 2023
c79d900
feat: error handling
dreamorosi Jun 7, 2023
4debde4
chore: lock
dreamorosi Jun 25, 2023
b84e543
chore: package.json
dreamorosi Jun 25, 2023
c38ecc0
feat: handle negative indexes
dreamorosi Jun 25, 2023
0f99c29
feat: filters and literal compliance
dreamorosi Aug 3, 2023
a5e31ab
chore: bumped
dreamorosi Aug 3, 2023
f37686f
feat: slice compliance
dreamorosi Aug 3, 2023
5a7a4b7
chore: isMax
dreamorosi Sep 27, 2023
9143b30
feat: min max and others
dreamorosi Feb 5, 2024
0fb7108
feat: map function
dreamorosi Feb 6, 2024
323e057
feat: toString, toArray, & toNumber functions
dreamorosi Feb 6, 2024
12175e6
feat: sum function
dreamorosi Feb 6, 2024
fec4af9
feat: notNull function
dreamorosi Feb 6, 2024
9156752
feat: merge function
dreamorosi Feb 6, 2024
14a42a9
feat: keys, values, sort functions
dreamorosi Feb 6, 2024
5cc4775
feat: join function
dreamorosi Feb 6, 2024
4672bf5
feat: reverse function
dreamorosi Feb 7, 2024
ecb5f8b
feat: sort_by function
dreamorosi Feb 7, 2024
dad71c3
feat: max_by and min_by function
dreamorosi Feb 10, 2024
9f4d4fd
chore: test setup
dreamorosi Feb 23, 2024
76b5c67
tests: coverage tests
dreamorosi Feb 24, 2024
1c2032c
chore: update types to include object
dreamorosi Mar 1, 2024
f4103f3
docs(jmespath): documentation & tests
dreamorosi Mar 4, 2024
1a7f567
chore: undo rebase changes
dreamorosi Mar 6, 2024
2dcc515
chore: undo rebase changes
dreamorosi Mar 6, 2024
2629606
chore: version
dreamorosi Mar 6, 2024
8d008c4
chore: undo rebase changes
dreamorosi Mar 6, 2024
d7aebfb
test(commons): unit tests for new commons utils
dreamorosi Mar 6, 2024
3b6eedf
chore: remove unused test
dreamorosi Mar 6, 2024
8fdcdfe
docs(jmespath): docs for utility
dreamorosi Mar 7, 2024
7c96062
chore: remove unused lines
dreamorosi Mar 7, 2024
b5c8a0d
docs: api docs
dreamorosi Mar 7, 2024
68c4812
refactor: reduce function cognitive complexity
dreamorosi Mar 8, 2024
b230b00
refactor: reduce class methods cognitive complexity
dreamorosi Mar 8, 2024
eb235c6
refactor: reduce class methods cognitive complexity
dreamorosi Mar 8, 2024
48e01f1
refactor: reduce class methods cognitive complexity
dreamorosi Mar 8, 2024
52eb0e3
refactor: reduce code complexity
dreamorosi Mar 8, 2024
2d4d0c6
Merge branch 'main' into feat/jmespath
dreamorosi Mar 12, 2024
04c3e06
chore: consume eq sign
dreamorosi Mar 12, 2024
db19a63
chore: consume negative number
dreamorosi Mar 12, 2024
c0c93f2
chore: consume sq bracket
dreamorosi Mar 12, 2024
4975d10
chore: consume identifier
dreamorosi Mar 12, 2024
3439f3b
chore: reduce complexity
dreamorosi Mar 12, 2024
79bd5f6
chore: reduce complexity
dreamorosi Mar 12, 2024
d5060d6
chore: reduce complexity
dreamorosi Mar 12, 2024
b108e28
chore: reduce complexity
dreamorosi Mar 12, 2024
3d83aef
chore: reduce complexity
dreamorosi Mar 12, 2024
7760b00
reduce complexity
dreamorosi Mar 12, 2024
86a36a4
reduce complexity
dreamorosi Mar 12, 2024
f52ebd0
reduce complexity
dreamorosi Mar 12, 2024
9678d6e
docs: add missing jsdoc
dreamorosi Mar 12, 2024
300938e
chore: stabilize sort
dreamorosi Mar 12, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
chore: reduce complexity
dreamorosi committed Mar 12, 2024

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
commit 3d83aefaabc7a99853bb5a0d2cd38253328824cd
5 changes: 2 additions & 3 deletions packages/jmespath/src/utils.ts
Original file line number Diff line number Diff line change
@@ -195,9 +195,7 @@ const typeCheckArgument = (arg: unknown, argumentSpec: Array<string>): void => {
actualType: getType(arg),
});
}
if (type.includes('-')) {
checkComplexArrayType(arg, type, hasMoreTypesToCheck);
}
checkComplexArrayType(arg, type, hasMoreTypesToCheck);
break;
}
if (type === 'expression') {
@@ -235,6 +233,7 @@ const checkComplexArrayType = (
type: string,
hasMoreTypesToCheck: boolean
): void => {
if (!type.includes('-')) return;
const arrayItemsType = type.slice(6);
let actualType: string | undefined;
for (const element of arg) {