Skip to content

Commit 3cc1c8a

Browse files
authored
Merge branch 'main' into dependabot/pip/redis-4.4.4
2 parents a747828 + 5cb1b91 commit 3cc1c8a

File tree

17 files changed

+88
-45
lines changed

17 files changed

+88
-45
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,4 @@ jobs:
1616
host: pythoncanarias.es
1717
username: ${{ secrets.PRODUCTION_SSH_USERNAME }}
1818
key: ${{ secrets.PRODUCTION_SSH_KEY }}
19-
script: source ~/.virtualenvs/web/bin/activate && cd ~/web && ./deploy.sh
19+
script: source ~/.pyenv/versions/pycanweb/bin/activate && cd ~/web && ./deploy.sh

__init__.py

Whitespace-only changes.
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# Generated by Django 3.2.25 on 2025-02-17 08:43
2+
3+
from django.db import migrations
4+
5+
6+
class Migration(migrations.Migration):
7+
8+
dependencies = [
9+
('about', '0004_auto_20220510_2236'),
10+
]
11+
12+
operations = [
13+
migrations.AlterModelOptions(
14+
name='ally',
15+
options={'ordering': ['name'], 'verbose_name': 'Aliado', 'verbose_name_plural': 'Aliados'},
16+
),
17+
]

apps/about/models.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ def __str__(self):
1616

1717
class Meta:
1818
ordering = ['name']
19+
verbose_name = 'Aliado'
20+
verbose_name_plural = 'Aliados'
1921

2022

2123
class FAQItem(models.Model):

apps/certificates/management/commands/create_certificate.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22

33
from django.core.management.base import BaseCommand
44

5-
from certificates.utils import create_certificate
6-
from tickets.models import Ticket
5+
from apps.certificates.utils import create_certificate
6+
from apps.tickets.models import Ticket
77

88

99
class Command(BaseCommand):

apps/events/test_tasks.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
#!/usr/bin/env python
1+
#!/usr/bin/env python3
22
# coding=utf-8
33

4-
import datetime
4+
from datetime import datetime as DateTime
55
import os
66
from unittest.mock import Mock
77

@@ -30,7 +30,7 @@ def test_ticket():
3030
customer_name="Nombre del comprador",
3131
customer_surname='Apellidos comprador',
3232
customer_email='[email protected]',
33-
sold_at=datetime.datetime(2018, 10, 11, 22, 44, 00),
33+
sold_at=DateTime(2018, 10, 11, 22, 44, 00),
3434
keycode='18b0b618-7b9e-4857-9f01-39999424ee3f',
3535
)
3636
ticket.article = article

apps/homepage/templates/homepage/index.html

Lines changed: 23 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ <h2><a class="event-target" href="{% url 'events:detail_event' slug=event.slug %
7474
{% endif %}
7575

7676
<h4 class="content blog-message">Para más noticias, pásate por nuestro
77-
<a href="https://medium.com/pythoncanarias" target="_blank" class="blog-link">
77+
<a href="https://medium.com/pythoncanarias" class="blog-link">
7878
blog
7979
<span class="icon">
8080
<i class="fab fa-medium"></i>
@@ -83,36 +83,49 @@ <h4 class="content blog-message">Para más noticias, pásate por nuestro
8383
</h4>
8484

8585
<div class="social buttons is-centered">
86-
<a href="https://twitter.com/pythoncanarias" target="_blank" class="button is-medium">
86+
87+
<a href="https://github.com/pythoncanarias/" class="button is-medium">
8788
<span class="icon">
88-
<i class="fab fa-twitter"></i>
89+
<i class="fab fa-github"></i>
8990
</span>
9091
</a>
91-
<a href="https://www.instagram.com/pythoncanarias/" target="_blank" class="button is-medium">
92+
93+
<a href="https://t.me/joinchat/AJ7pmT-X0xZVPgWDIzGA-A" class="button is-medium">
9294
<span class="icon">
93-
<i class="fab fa-instagram"></i>
95+
<i class="fab fa-telegram"></i>
9496
</span>
9597
</a>
96-
<a href="https://t.me/joinchat/AJ7pmT-X0xZVPgWDIzGA-A" target="_blank" class="button is-medium">
98+
99+
<a href="https://www.instagram.com/pythoncanarias/" class="button is-medium">
97100
<span class="icon">
98-
<i class="fab fa-telegram"></i>
101+
<i class="fab fa-instagram"></i>
99102
</span>
100103
</a>
101-
<a href="https://www.youtube.com/channel/UCIH5U0UXk-NL1HdFSo__63A" target="_blank" class="button is-medium">
104+
105+
<a href="https://www.youtube.com/channel/UCIH5U0UXk-NL1HdFSo__63A" class="button is-medium">
102106
<span class="icon">
103107
<i class="fab fa-youtube"></i>
104108
</span>
105109
</a>
106-
<a href="https://www.facebook.com/pythoncanarias/" target="_blank" class="button is-medium">
110+
111+
<a href="https://www.facebook.com/pythoncanarias/" class="button is-medium">
107112
<span class="icon">
108113
<i class="fab fa-facebook"></i>
109114
</span>
110115
</a>
111-
<a href="mailto:{{ organization.email }}" target="_blank" class="button is-medium">
116+
117+
<a href="https://twitter.com/pythoncanarias" class="button is-medium">
118+
<span class="icon">
119+
<i class="fab fa-twitter"></i>
120+
</span>
121+
</a>
122+
123+
<a href="mailto:{{ organization.email }}" class="button is-medium">
112124
<span class="icon">
113125
<i class="fas fa-envelope-open"></i>
114126
</span>
115127
</a>
128+
116129
</div>
117130

118131
</div>

apps/jobs/models.py

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -38,16 +38,10 @@
3838
class ActiveJobOfferManager(models.Manager):
3939
def get_queryset(self):
4040
today = datetime.date.today()
41-
return (
42-
super()
43-
.get_queryset()
44-
.filter(approved=True)
45-
.filter(valid_until__gte=today)
46-
)
41+
return super().get_queryset().filter(approved=True).filter(valid_until__gte=today)
4742

4843

4944
class JobOffer(models.Model):
50-
5145
objects = models.Manager() # The default manager.
5246
actives = ActiveJobOfferManager() # Only the active jobs offer
5347

@@ -59,9 +53,7 @@ class Meta:
5953
employer = models.CharField("Ofertante", max_length=120)
6054
title = models.CharField("Nombre del puesto", max_length=220)
6155
description = models.TextField("Texto de la oferta", max_length=2000)
62-
salary = models.CharField(
63-
"Salario o rango salarial", max_length=80, blank=True
64-
)
56+
salary = models.CharField("Salario o rango salarial", max_length=80, blank=True)
6557
contract_type = models.CharField(
6658
"Tipo de contrato",
6759
max_length=3,
@@ -107,7 +99,8 @@ def get_full_url(self):
10799
def save(self, *args, **kwargs):
108100
already_exists = self.pk is not None
109101
super().save(*args, **kwargs)
102+
''' tweepy.error.TweepError: [{'message': 'You currently have access to a subset of Twitter API v2 endpoints and limited v1.1 endpoints (e.g. media post, oauth) only. If you need access to this endpoint, you may need a different access level. You can learn more here: https://developer.twitter.com/en/portal/product', 'code': 453}]
110103
if not already_exists and self.approved:
111104
t = Twitter()
112105
msg = f'💼 Oferta de empleo: {self} {self.get_full_url()}'
113-
t.post(msg)
106+
t.post(msg)'''

apps/learn/templates/learn/index.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@ <h1 class="title">Aprende Python</h1>
1212

1313
<p>En esta sección podrás encontrar <strong>recursos de aprendizaje Python</strong>. Están clasificados por etiquetas:</p>
1414

15-
<ul>
15+
<ul style="display: flex; flex-wrap: wrap">
1616
{% for label in labels %}
17-
<li>
17+
<li style="padding: 5px 5px 5px 0px">
1818
<a class="label"
1919
style="background-color: #{{ label.color }}; color: #{{ label.foreground_color }}"
2020
href="{% url "learn:resources_by_label" label=label %}">

deploy.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,5 @@ npm install --no-save
88
gulp
99
python manage.py migrate
1010
python manage.py collectstatic --noinput --clear
11-
supervisorctl restart web
1211
supervisorctl restart rq
12+
supervisorctl restart web

0 commit comments

Comments
 (0)