Skip to content

Commit b20ddec

Browse files
fix: Gettransactionnodes showing irrelevant transactions (#2445)
* fix: rename keyParam to keyIdsParam for clarity in transaction queries Signed-off-by: John Bair <john.bair@swirldslabs.com> * fix: enhance transaction query filters for onlyUnsigned flag and improve clarity in test descriptions Signed-off-by: John Bair <john.bair@swirldslabs.com> * fix: update transaction query to include onlyUnsigned flag for improved filtering Signed-off-by: John Bair <john.bair@swirldslabs.com> * fix: add isReceiver flag to transaction-account links for accurate role assignment Signed-off-by: John Bair <john.bair@swirldslabs.com> * fix: remove deprecated linkTransactionToEntity method and associated tests Signed-off-by: John Bair <john.bair@swirldslabs.com> * fix: adjust indentation in transaction query for improved readability Signed-off-by: John Bair <john.bair@swirldslabs.com> * fix: added sql filter and test cases Signed-off-by: Dian Deskov <dian.deskov@limechain.tech> * tests added Signed-off-by: Dian Deskov <dian.deskov@limechain.tech> * fix: failing Unit Tests | API Signed-off-by: Dian Deskov <dian.deskov@limechain.tech> * fix: update transaction query to include receiverSignatureRequired condition for accurate filtering Signed-off-by: John Bair <john.bair@swirldslabs.com> * fix: update transaction linking logic to correctly handle receiver and signer roles Signed-off-by: John Bair <john.bair@swirldslabs.com> --------- Signed-off-by: John Bair <john.bair@swirldslabs.com> Signed-off-by: Dian Deskov <dian.deskov@limechain.tech> Co-authored-by: John Bair <john.bair@swirldslabs.com> Co-authored-by: John Bair <117694970+jbair06@users.noreply.github.com>
1 parent e539e37 commit b20ddec

16 files changed

+999
-446
lines changed

NOTICE

Lines changed: 23 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -370,7 +370,7 @@ The Initial Developer of @grpc/proto-loader@0.7.13,
370370
is Google Inc. (https://github.com/grpc/grpc-node).
371371
Copyright Google Inc.. All Rights Reserved.
372372

373-
The Initial Developer of @hashgraph/cryptography@1.8.0,
373+
The Initial Developer of @hashgraph/cryptography@1.16.0-beta.3,
374374
is Launchbadge (https://github.com/hiero-ledger/hiero-sdk-js).
375375
Copyright Launchbadge. All Rights Reserved.
376376

@@ -382,7 +382,11 @@ The Initial Developer of @hashgraph/proto@2.19.0,
382382
is Launchbadge (https://github.com/hiero-ledger/hiero-sdk-js).
383383
Copyright Launchbadge. All Rights Reserved.
384384

385-
The Initial Developer of @hashgraph/sdk@2.66.0,
385+
The Initial Developer of @hashgraph/proto@2.26.0-beta.3,
386+
is Launchbadge (https://github.com/hiero-ledger/hiero-sdk-js).
387+
Copyright Launchbadge. All Rights Reserved.
388+
389+
The Initial Developer of @hashgraph/sdk@2.80.0,
386390
is Launchbadge (https://github.com/hiero-ledger/hiero-sdk-js).
387391
Copyright Launchbadge. All Rights Reserved.
388392

@@ -556,11 +560,11 @@ The Initial Developer of @nestjs/websockets@10.4.15,
556560
is Kamil Mysliwiec (https://github.com/nestjs/nest).
557561
Copyright Kamil Mysliwiec. All Rights Reserved.
558562

559-
The Initial Developer of @noble/curves@1.9.1,
563+
The Initial Developer of @noble/curves@1.8.1,
560564
is Paul Miller (https://github.com/paulmillr/noble-curves).
561565
Copyright Paul Miller. All Rights Reserved.
562566

563-
The Initial Developer of @noble/hashes@1.8.0,
567+
The Initial Developer of @noble/hashes@1.7.1,
564568
is Paul Miller (https://github.com/paulmillr/noble-hashes).
565569
Copyright Paul Miller. All Rights Reserved.
566570

@@ -585,6 +589,10 @@ The Initial Developer of @phc/format@1.0.0,
585589
is Simone Primarosa (https://github.com/simonepri/phc-format).
586590
Copyright Simone Primarosa. All Rights Reserved.
587591

592+
The Initial Developer of @pinojs/redact@0.4.0,
593+
is Matteo Collina (https://github.com/pinojs/redact).
594+
Copyright Matteo Collina. All Rights Reserved.
595+
588596
This product includes software (@pkgjs/parseargs@0.11.0) developed at
589597
(https://github.com/pkgjs/parseargs).
590598

@@ -851,7 +859,7 @@ This product includes software (@types/node@22.10.5) developed at
851859
This product includes software (@types/node@22.12.0) developed at
852860
(https://github.com/DefinitelyTyped/DefinitelyTyped).
853861

854-
This product includes software (@types/node@25.3.0) developed at
862+
This product includes software (@types/node@25.2.3) developed at
855863
(https://github.com/DefinitelyTyped/DefinitelyTyped).
856864

857865
This product includes software (@types/nodemailer@6.4.17) developed at
@@ -1118,11 +1126,11 @@ The Initial Developer of anser@1.4.10,
11181126
is Ionică Bizău (https://github.com/IonicaBizau/anser).
11191127
Copyright Ionică Bizău. All Rights Reserved.
11201128

1121-
The Initial Developer of ansi-regex@5.0.1,
1129+
The Initial Developer of ansi-regex@6.2.2,
11221130
is Sindre Sorhus (https://github.com/chalk/ansi-regex).
11231131
Copyright Sindre Sorhus. All Rights Reserved.
11241132

1125-
The Initial Developer of ansi-styles@4.3.0,
1133+
The Initial Developer of ansi-styles@6.2.3,
11261134
is Sindre Sorhus (https://github.com/chalk/ansi-styles).
11271135
Copyright Sindre Sorhus. All Rights Reserved.
11281136

@@ -1917,10 +1925,6 @@ The Initial Developer of fast-levenshtein@2.0.6,
19171925
is Ramesh Nair (https://github.com/hiddentao/fast-levenshtein).
19181926
Copyright Ramesh Nair. All Rights Reserved.
19191927

1920-
The Initial Developer of fast-redact@3.5.0,
1921-
is David Mark Clements (https://github.com/davidmarkclements/fast-redact).
1922-
Copyright David Mark Clements. All Rights Reserved.
1923-
19241928
The Initial Developer of fast-safe-stringify@2.1.1,
19251929
is David Mark Clements (https://github.com/davidmarkclements/fast-safe-stringify).
19261930
Copyright David Mark Clements. All Rights Reserved.
@@ -2403,7 +2407,7 @@ The Initial Developer of joycon@3.1.1,
24032407
is egoist (https://github.com/egoist/joycon).
24042408
Copyright egoist. All Rights Reserved.
24052409

2406-
The Initial Developer of js-base64@3.7.7,
2410+
The Initial Developer of js-base64@3.7.4,
24072411
is Dan Kogai (https://github.com/dankogai/js-base64).
24082412
Copyright Dan Kogai. All Rights Reserved.
24092413

@@ -3024,7 +3028,7 @@ The Initial Developer of pino-std-serializers@7.0.0,
30243028
is James Sumners (https://github.com/pinojs/pino-std-serializers).
30253029
Copyright James Sumners. All Rights Reserved.
30263030

3027-
The Initial Developer of pino@9.6.0,
3031+
The Initial Developer of pino@10.1.0,
30283032
is Matteo Collina (https://github.com/pinojs/pino).
30293033
Copyright Matteo Collina. All Rights Reserved.
30303034

@@ -3081,7 +3085,7 @@ Copyright Tim Suchanek. All Rights Reserved.
30813085
This product includes software (process-nextick-args@2.0.1) developed at
30823086
(https://github.com/calvinmetcalf/process-nextick-args).
30833087

3084-
The Initial Developer of process-warning@4.0.1,
3088+
The Initial Developer of process-warning@5.0.0,
30853089
is Tomas Della Vedova (https://github.com/fastify/process-warning).
30863090
Copyright Tomas Della Vedova. All Rights Reserved.
30873091

@@ -3233,7 +3237,7 @@ The Initial Developer of reusify@1.0.4,
32333237
is Matteo Collina (https://github.com/mcollina/reusify).
32343238
Copyright Matteo Collina. All Rights Reserved.
32353239

3236-
The Initial Developer of rfc4648@1.5.4,
3240+
The Initial Developer of rfc4648@1.5.3,
32373241
is William Swanson (https://github.com/swansontec/rfc4648.js).
32383242
Copyright William Swanson. All Rights Reserved.
32393243

@@ -3466,6 +3470,10 @@ The Initial Developer of strip-ansi@6.0.1,
34663470
is Sindre Sorhus (https://github.com/chalk/strip-ansi).
34673471
Copyright Sindre Sorhus. All Rights Reserved.
34683472

3473+
The Initial Developer of strip-ansi@7.1.2,
3474+
is Sindre Sorhus (https://github.com/chalk/strip-ansi).
3475+
Copyright Sindre Sorhus. All Rights Reserved.
3476+
34693477
The Initial Developer of strip-final-newline@4.0.0,
34703478
is Sindre Sorhus (https://github.com/sindresorhus/strip-final-newline).
34713479
Copyright Sindre Sorhus. All Rights Reserved.

back-end/apps/api/src/transactions/nodes/transaction-nodes.service.spec.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -354,10 +354,9 @@ describe('TransactionNodesService', () => {
354354
{
355355
statuses: TRANSACTION_STATUS_COLLECTIONS.READY_TO_SIGN,
356356
mirrorNetwork: TEST_NETWORK,
357-
onlyUnsigned: true,
358357
},
359358
user,
360-
{ signer: true }
359+
{ signer: true, onlyUnsigned: true }
361360
);
362361

363362
// Verify entityManager.query was called with the query

back-end/apps/api/src/transactions/nodes/transaction-nodes.service.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,10 +54,9 @@ export class TransactionNodesService {
5454
{
5555
statuses: TRANSACTION_STATUS_COLLECTIONS.READY_TO_SIGN,
5656
mirrorNetwork: network,
57-
onlyUnsigned: true,
5857
},
5958
user,
60-
{ signer: true }
59+
{ signer: true, onlyUnsigned: true }
6160
);
6261

6362
rows = await this.entityManager.query(query.text, query.values);

back-end/libs/common/src/database/entities/caches/transaction-cached-account.entity.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,4 +25,7 @@ export class TransactionCachedAccount {
2525

2626
@Column()
2727
cachedAccountId: number;
28+
29+
@Column({ default: false })
30+
isReceiver: boolean;
2831
}

0 commit comments

Comments
 (0)