Skip to content

Commit 3a366ed

Browse files
author
Céline Didier
committed
Resolve translation problems
2 parents 760f136 + 7188345 commit 3a366ed

File tree

12 files changed

+161
-151
lines changed

12 files changed

+161
-151
lines changed

.github/workflows/pod_dev.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,23 @@ jobs:
3030
runs-on: ubuntu-latest
3131

3232
steps:
33+
34+
- name: Free Disk Space (Ubuntu)
35+
uses: jlumbroso/free-disk-space@main
36+
with:
37+
# this might remove tools that are actually needed,
38+
# if set to "true" but frees about 6 GB
39+
tool-cache: false
40+
41+
# all of these default to true, but feel free to set to
42+
# "false" if necessary for your workflow
43+
android: true
44+
dotnet: true
45+
haskell: true
46+
large-packages: true
47+
docker-images: false
48+
swap-storage: true
49+
3350
- uses: actions/checkout@v4
3451

3552
- uses: actions/setup-node@v4

Makefile

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,10 @@ help:
1010
@echo "Syntax: [make target] where target is in this list:"
1111
@awk '/^#/{c=substr($$0,3);next}c&&/^[[:alpha:]][[:alnum:]_-]+:/{print substr($$1,1,index($$1,":")),c}1{c=0}' $(MAKEFILE_LIST) | column -s: -t
1212

13+
# Affiche la doc technique de Pod v4
14+
doc:
15+
open https://esupportail.github.io/Esup-Pod/4.x/index
16+
1317
# Démarre le serveur de test
1418
start:
1519
(sleep 15 ; open http://pod.localhost:8000) &
@@ -33,17 +37,17 @@ install:
3337

3438
# Mise à jour de Pod
3539
upgrade:
36-
git pull origin master
40+
git pull origin main
3741
python3 -m pip install -r requirements.txt
3842
make updatedb
3943
make migrate
4044
make statics
4145

4246
# Création des données initiales dans la BDD SQLite intégrée
4347
createDB:
44-
find . -path "*/migrations/*.py" -not -name "__init__.py" -delete
45-
find . -path "*/migrations/*.pyc" -delete
4648
python3 manage.py delete_flatpages_migrations
49+
find . -path "*/migrations/*.py" -not -name "__init__.py" -not -path "./.venv/*" -delete
50+
find . -path "*/migrations/*.pyc" -delete
4751
make updatedb
4852
make migrate
4953
python3 -Wd manage.py loaddata initial_data

pod/ai_enhancement/templates/choose_video_element.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,6 @@
122122
{{ form.media }}
123123
<script src="{% static 'ai_enhancement/js/enrich-form.js' %}?ver={{ VERSION }}"></script>
124124
<script>
125-
addEventListeners("{{ video.slug }}", "{{ video.title }}", "{{ video.description|safe }}", "{{ video.disciplines }}", "{% url 'ai_enhancement:enhance_video_json' video_slug=video.slug %}");
125+
addEventListeners("{{ video.slug }}", "{{ video.title|escapejs }}", "{{ video.description|escapejs }}", "{{ video.disciplines|escapejs }}", "{% url 'ai_enhancement:enhance_video_json' video_slug=video.slug %}");
126126
</script>
127127
{% endblock more_script %}

pod/ai_enhancement/utils.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -281,7 +281,7 @@ def send_notification_enhancement(video, success: bool = True):
281281
}
282282
if not success:
283283
message = _(
284-
"Something went wrong with IA improvement on “%(content_title)s”."
284+
"Something went wrong with AI improvement on “%(content_title)s”."
285285
+ " Suggestions for improvement can’t be available on %(site_title)s."
286286
) % {
287287
"content_title": video.title,
@@ -299,23 +299,23 @@ def send_notification_enhancement(video, success: bool = True):
299299
def send_email_enhancement(video, success: bool = True) -> None:
300300
"""Send email notification on video improvement completion."""
301301
if DEBUG:
302-
logger.info("SEND EMAIL ON IA IMPROVEMENT COMPLETION %s", success)
302+
logger.info("SEND EMAIL ON AI IMPROVEMENT COMPLETION %s", success)
303303
url_scheme = "https" if SECURE_SSL_REDIRECT else "http"
304304
content_url = "%s:%s" % (url_scheme, video.get_full_url())
305305
subject = "[%s] %s" % (
306306
__TITLE_SITE__,
307-
_("IA improvement #%(content_id)s completed") % {"content_id": video.id},
307+
_("AI improvement #%(content_id)s completed") % {"content_id": video.id},
308308
)
309309
main_text = _(
310-
"IA improvement “%(content_title)s” has been completed"
310+
"AI improvement “%(content_title)s” has been completed"
311311
+ ", and is now available on %(site_title)s."
312312
) % {
313313
"content_title": "<strong>%s</strong>" % video.title,
314314
"site_title": __TITLE_SITE__,
315315
}
316316
if not success:
317317
main_text = _(
318-
"Something went wrong with IA improvement on “%(content_title)s” "
318+
"Something went wrong with AI improvement on “%(content_title)s” "
319319
+ " on %(site_title)s."
320320
) % {
321321
"content_title": "<strong>%s</strong>" % video.title,
4.25 KB
Binary file not shown.

0 commit comments

Comments
 (0)