-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2957 from prefeiturasp/hotfix/9.6.1
Hotfix/9.6.1
- Loading branch information
Showing
4 changed files
with
53 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
__version__ = "9.6.0" | ||
__version__ = "9.6.1" | ||
|
||
__version_info__ = tuple( | ||
[ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
from .migrar_gastos_periodos_anteriores import migrar_gastos_periodos_anteriores_async |
20 changes: 20 additions & 0 deletions
20
sme_ptrf_apps/despesas/tasks/migrar_gastos_periodos_anteriores.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
import logging | ||
|
||
from celery import shared_task | ||
from sme_ptrf_apps.despesas.services.despesa_service import migra_despesas_periodos_anteriores | ||
|
||
logger = logging.getLogger(__name__) | ||
|
||
|
||
@shared_task( | ||
retry_backoff=2, | ||
retry_kwargs={'max_retries': 8}, | ||
time_limet=600, | ||
soft_time_limit=300 | ||
) | ||
def migrar_gastos_periodos_anteriores_async(): | ||
logger.info('Iniciando a task de migração de gastos de períodos anteriores.') | ||
|
||
migra_despesas_periodos_anteriores() | ||
|
||
logger.info('Finalizado a task de migração de gastos de períodos anteriores.') |