Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
nomad-lab
nomad-FAIR
Commits
3ccd109f
Commit
3ccd109f
authored
Aug 08, 2019
by
Markus Scheidgen
Browse files
Fixed missing upload_time on reindexed calcs.
parent
fd7f69d2
Changes
1
Hide whitespace changes
Inline
Side-by-side
nomad/processing/data.py
View file @
3ccd109f
...
...
@@ -943,13 +943,18 @@ class Upload(Proc):
calc_metadata
=
dict
(
upload_metadata
)
calc_metadata
.
update
(
calc_metadatas
.
get
(
calc
.
mainfile
,
{}))
calc_with_metadata
.
apply_user_metadata
(
calc_metadata
)
if
calc_with_metadata
.
upload_time
is
None
:
calc_with_metadata
.
upload_time
=
self
.
upload_time
if
user_upload_time
is
None
else
user_upload_time
return
calc_with_metadata
else
:
user_upload_time
=
None
def
get_metadata
(
calc
:
Calc
):
return
datamodel
.
CalcWithMetadata
(
**
calc
.
metadata
)
calc_with_metadata
=
datamodel
.
CalcWithMetadata
(
**
calc
.
metadata
)
calc_with_metadata
.
upload_time
=
self
.
upload_time
return
calc_with_metadata
result
=
UploadWithMetadata
(
upload_id
=
self
.
upload_id
,
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment