Skip to content

Conversation

@lucvin
Copy link
Contributor

@lucvin lucvin commented Apr 15, 2025

babel.cfg Outdated

[jinja2: **/templates/**.html]
encoding = utf-8
trimmed = true No newline at end of file
Copy link
Member

Choose a reason for hiding this comment

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

please configure your editor to end files with a linebreka

<td style="text-align: center; color: #aaa; font-size: 11px; padding-bottom: 10px;">
<p style="padding: 0 50px; margin-top: 10px;">
This email was sent by <a href="{{ url_for('index', _external=true) }}">newdle</a>.
{% trans %}This email was sent by{% endtrans %} <a href="{{ url_for('index', _external=true) }}">newdle</a>.
Copy link
Member

Choose a reason for hiding this comment

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

Don't have partial sentences in translatable strings. The link must be part of it. You can do something like this:

{% set newdle_link -%}
    <a href="{{ url_for('index', _external=true) }}">newdle</a>
{%- endset %}
{% trans %}This email was sent by {{ newdle_link }}.{% endtrans %}

{% block content %}
<p>
Hi {{ participant }}, you have a fresh newdle!
{% trans %}"Hi {{ participant }}, you have a fresh newdle!"{% endtrans %}
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
{% trans %}"Hi {{ participant }}, you have a fresh newdle!"{% endtrans %}
{% trans %}Hi {{ participant }}, you have a fresh newdle!{% endtrans %}

@lucvin
Copy link
Contributor Author

lucvin commented May 14, 2025

Hi, i've fixed the extension error and now i have this error on the git ci and cannot commit

newdle/core/app.py:81:9: LOG004 .exception() call outside exception handlers
|
79 | # message or the debugger while in development mode.
80 | raise # noqa: PLE0704
81 | app.logger.exception('Request failed')
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ LOG004
82 | return jsonify(error='internal_error'), 500
|
= help: Replace with .error()

this has always been there and i don't know why it's bothering him now but it might need to be changed https://docs.astral.sh/ruff/rules/log-exception-outside-except-handler/

@tomasr8
Copy link
Member

tomasr8 commented May 22, 2025

Maybe just add a noqa for now?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants