Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@motorina0
Copy link
Collaborator

@motorina0 motorina0 commented Feb 15, 2024

Related to:

When an extension is uninstalled/upgraded the background tasks have to be stopped.

Issue:

  • the background tasks were being stopped by calling a REST API endpoint on localhost
  • localhost is not always accessible (docker container for example)

Solution:

  • first try to call the stop logic using a normal python function call

@codecov
Copy link

codecov bot commented Feb 15, 2024

Codecov Report

Attention: 26 lines in your changes are missing coverage. Please review.

Comparison is base (5264677) 59.31% compared to head (280b791) 59.16%.

Files Patch % Lines
lnbits/core/helpers.py 8.69% 21 Missing ⚠️
lnbits/settings.py 40.00% 3 Missing ⚠️
lnbits/core/views/api.py 0.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##              dev    #2281      +/-   ##
==========================================
- Coverage   59.31%   59.16%   -0.16%     
==========================================
  Files          60       60              
  Lines        9041     9070      +29     
==========================================
+ Hits         5363     5366       +3     
- Misses       3678     3704      +26     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@motorina0 motorina0 marked this pull request as ready for review February 15, 2024 09:47
@motorina0 motorina0 changed the title Fix extension stop background work fix: extension stop background work Feb 15, 2024
@motorina0 motorina0 added this to the 0.12.2 milestone Feb 15, 2024
@motorina0 motorina0 added the bug Something isn't working label Feb 15, 2024
Copy link
Member

@dni dni left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@motorina0 motorina0 merged commit c51e735 into dev Feb 21, 2024
@motorina0 motorina0 deleted the fix_extension_stop_background_work branch February 21, 2024 10:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants