pagopa / io-app

IO, l'app dei servizi pubblici
https://io.italia.it
European Union Public License 1.2
567 stars 97 forks source link

chore(IT Wallet): [SIW-1056] Add wallet placeholders timeout #5713

Closed mastro993 closed 2 weeks ago

mastro993 commented 3 weeks ago

[!WARNING] This PR depends on https://github.com/pagopa/io-app/pull/5707

Short description

This PR adds a timeout for wallet card placeholder which are taking too long to load or will never be added again to the wallet. This allows to remove pending placeholders animation from the wallet section

List of changes proposed in this pull request

How to test

You can test this PR easily with the io-dev-api-server, just add a new CGN card then restart the dev server. The app will wait for a CGN card to come but the server will never return any.

Previews

Before After
pagopa-github-bot commented 3 weeks ago

Affected stories

Generated by :no_entry_sign: dangerJS against cb0172c2eedfd1ab8495d965bb0a376abbc8a4f2

dpulls[bot] commented 2 weeks ago

:tada: All dependencies have been resolved !

mastro993 commented 2 weeks ago

Could be useful to add some test for the saga handler? What do you think about?

Yes, absolutely! Added in https://github.com/pagopa/io-app/pull/5713/commits/0946e8390e75cbaaed9d52942705c64b6c523041

codecov[bot] commented 2 weeks ago

Codecov Report

Attention: Patch coverage is 72.72727% with 3 lines in your changes are missing coverage. Please review.

Project coverage is 48.81%. Comparing base (4f204b4) to head (cb0172c). Report is 29 commits behind head on master.

Additional details and impacted files [![Impacted file tree graph](https://app.codecov.io/gh/pagopa/io-app/pull/5713/graphs/tree.svg?width=650&height=150&src=pr&token=zsurlZdPFW&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pagopa)](https://app.codecov.io/gh/pagopa/io-app/pull/5713?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pagopa) ```diff @@ Coverage Diff @@ ## master #5713 +/- ## ========================================== + Coverage 48.42% 48.81% +0.39% ========================================== Files 1488 1579 +91 Lines 31617 31808 +191 Branches 7669 7658 -11 ========================================== + Hits 15311 15528 +217 + Misses 16238 16222 -16 + Partials 68 58 -10 ``` | [Files](https://app.codecov.io/gh/pagopa/io-app/pull/5713?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pagopa) | Coverage Δ | | |---|---|---| | [...let/saga/handleWalletLoadingPlaceholdersTimeout.ts](https://app.codecov.io/gh/pagopa/io-app/pull/5713?src=pr&el=tree&filepath=ts%2Ffeatures%2FnewWallet%2Fsaga%2FhandleWalletLoadingPlaceholdersTimeout.ts&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pagopa#diff-dHMvZmVhdHVyZXMvbmV3V2FsbGV0L3NhZ2EvaGFuZGxlV2FsbGV0TG9hZGluZ1BsYWNlaG9sZGVyc1RpbWVvdXQudHM=) | `100.00% <100.00%> (ø)` | | | [...res/newWallet/saga/handleWalletLoadingStateSaga.ts](https://app.codecov.io/gh/pagopa/io-app/pull/5713?src=pr&el=tree&filepath=ts%2Ffeatures%2FnewWallet%2Fsaga%2FhandleWalletLoadingStateSaga.ts&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pagopa#diff-dHMvZmVhdHVyZXMvbmV3V2FsbGV0L3NhZ2EvaGFuZGxlV2FsbGV0TG9hZGluZ1N0YXRlU2FnYS50cw==) | `100.00% <ø> (ø)` | | | [...s/features/newWallet/store/actions/placeholders.ts](https://app.codecov.io/gh/pagopa/io-app/pull/5713?src=pr&el=tree&filepath=ts%2Ffeatures%2FnewWallet%2Fstore%2Factions%2Fplaceholders.ts&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pagopa#diff-dHMvZmVhdHVyZXMvbmV3V2FsbGV0L3N0b3JlL2FjdGlvbnMvcGxhY2Vob2xkZXJzLnRz) | `100.00% <100.00%> (ø)` | | | [ts/features/newWallet/saga/index.ts](https://app.codecov.io/gh/pagopa/io-app/pull/5713?src=pr&el=tree&filepath=ts%2Ffeatures%2FnewWallet%2Fsaga%2Findex.ts&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pagopa#diff-dHMvZmVhdHVyZXMvbmV3V2FsbGV0L3NhZ2EvaW5kZXgudHM=) | `25.00% <50.00%> (ø)` | | | [.../features/newWallet/store/reducers/placeholders.ts](https://app.codecov.io/gh/pagopa/io-app/pull/5713?src=pr&el=tree&filepath=ts%2Ffeatures%2FnewWallet%2Fstore%2Freducers%2Fplaceholders.ts&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pagopa#diff-dHMvZmVhdHVyZXMvbmV3V2FsbGV0L3N0b3JlL3JlZHVjZXJzL3BsYWNlaG9sZGVycy50cw==) | `80.95% <50.00%> (-19.05%)` | :arrow_down: | ... and [119 files with indirect coverage changes](https://app.codecov.io/gh/pagopa/io-app/pull/5713/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pagopa) ------ [Continue to review full report in Codecov by Sentry](https://app.codecov.io/gh/pagopa/io-app/pull/5713?dropdown=coverage&src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pagopa). > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pagopa) > `Δ = absolute (impact)`, `ø = not affected`, `? = missing data` > Powered by [Codecov](https://app.codecov.io/gh/pagopa/io-app/pull/5713?dropdown=coverage&src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pagopa). Last update [f8e00fe...cb0172c](https://app.codecov.io/gh/pagopa/io-app/pull/5713?dropdown=coverage&src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pagopa). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=pagopa).