Skip to content

Commit

Permalink
Update GitHub Actions workflow to trigger on version tags, modify ser…
Browse files Browse the repository at this point in the history
…vice file for root user/group, and enhance error logging in RabbitMQ consumer
  • Loading branch information
alevilar committed Dec 13, 2024
1 parent c3c110e commit 20e4817
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 5 deletions.
7 changes: 5 additions & 2 deletions .github/workflows/desktop.build.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
name: Build Desktop Ejecutables - on Release
name: Build Desktop Ejecutables - on New Version

on: push
on:
push:
tags:
- 'v*.*.*'

jobs:
build-raspberry-pi:
Expand Down
4 changes: 3 additions & 1 deletion fiscalberry.service
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,13 @@ Wants=network-online.target
After=network.target network-online.target

[Service]
User=root
Group=root
Restart=always
RestartSec=5
Type=simple
ExecStart=/usr/bin/fiscalberry
StandardOutput=syslog
StandardOutput=syslogsudo systemctl restart fiscalberry.service
StandardError=syslog
SyslogIdentifier=fiscalberry

Expand Down
2 changes: 0 additions & 2 deletions src/common/EscPComandos.py
Original file line number Diff line number Diff line change
Expand Up @@ -366,8 +366,6 @@ def printFacturaElectronica(self, escpos: EscposIO, **kwargs):
escpos.writelines(f'{dsTotal}{self.signo}{importeTotal}', bold=True, align='left', height=2, width=2)
printer.ln();

printer.text(f'{dsSinIva}{self.signo}{importeSinIva}\n')

dsSinIva = pad("Neto sin IVA:", self.desc_cols_ext - 1, " ", "l")
importeSinIva = pad(f"{round(totalNeto, 2):,.2f}",self.price_cols, " ", "r")
printer.set(font='a', height=1, align='left', normal_textsize=True)
Expand Down
3 changes: 3 additions & 0 deletions src/common/rabbit_mq_consumer.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,11 @@ def callback(ch, method, properties, body):
except TraductorException as e:
self.logger.error(f"TraductorException Error al procesar mensaje: {e}")
ch.basic_nack(delivery_tag=method.delivery_tag, requeue=True)
self.logger.error(traceback.format_exc())

except Exception as e:
self.logger.error(f"Error al procesar mensaje: {e}")
self.logger.error(traceback.format_exc())
ch.basic_nack(delivery_tag=method.delivery_tag, requeue=True)


Expand Down

0 comments on commit 20e4817

Please sign in to comment.