Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
H
hub
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Package registry
Model registry
Operate
Terraform modules
Analyze
Contributor analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
MyIgel
hub
Commits
f5e6c665
Commit
f5e6c665
authored
Dec 29, 2023
by
HeJ
Browse files
Options
Downloads
Patches
Plain Diff
schedule import bugfix: use str() on uuids before joining them
parent
b337e38e
Branches
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/core/models/schedules.py
+2
-1
2 additions, 1 deletion
src/core/models/schedules.py
with
2 additions
and
1 deletion
src/core/models/schedules.py
+
2
−
1
View file @
f5e6c665
...
@@ -162,7 +162,7 @@ class ScheduleSource(models.Model):
...
@@ -162,7 +162,7 @@ class ScheduleSource(models.Model):
# the very bad case: we found too many
# the very bad case: we found too many
if
len
(
candidates
)
>
1
:
if
len
(
candidates
)
>
1
:
raise
ValueError
(
'
Multiple candidate speakers found:
'
+
'
;
'
.
join
(
x
.
pk
for
x
in
candidates
))
raise
ValueError
(
'
Multiple candidate speakers found:
'
+
'
;
'
.
join
(
str
(
x
.
pk
)
for
x
in
candidates
))
# hail mary attempt: see if we have an imported speaker with the same name
# hail mary attempt: see if we have an imported speaker with the same name
candidates
=
self
.
conference
.
users
.
select_related
(
'
user
'
).
filter
(
user__user_type
=
PlatformUser
.
Type
.
SPEAKER
,
user__display_name
=
name
).
all
()
candidates
=
self
.
conference
.
users
.
select_related
(
'
user
'
).
filter
(
user__user_type
=
PlatformUser
.
Type
.
SPEAKER
,
user__display_name
=
name
).
all
()
...
@@ -787,6 +787,7 @@ class ScheduleSourceImport(models.Model):
...
@@ -787,6 +787,7 @@ class ScheduleSourceImport(models.Model):
return
False
return
False
self
.
start
=
timezone
.
now
()
self
.
start
=
timezone
.
now
()
self
.
end
=
None
self
.
state
=
self
.
State
.
STARTED
self
.
state
=
self
.
State
.
STARTED
self
.
save
(
update_fields
=
[
'
start
'
,
'
state
'
])
self
.
save
(
update_fields
=
[
'
start
'
,
'
state
'
])
logger
.
info
(
'
[job %s] starting import
'
,
self
.
pk
)
logger
.
info
(
'
[job %s] starting import
'
,
self
.
pk
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment