Skip to content
Snippets Groups Projects
Commit 08b55f41 authored by François  LAURENT's avatar François LAURENT
Browse files

fix log messages for backend paths with trailing slash

parent d5aa4e6f
No related branches found
No related tags found
No related merge requests found
Pipeline #96644 passed
......@@ -74,6 +74,7 @@ in the relative paths.
"""
function push(tagger::Tagger, inputdata::String)
destination = nothing
backend_name = basename(realpath(tagger.backend_dir))
raw_data_dir = datadir(tagger, "raw")
if isdir(inputdata)
inputdata = realpath(inputdata) # strip the end slashes
......@@ -89,7 +90,7 @@ function push(tagger::Tagger, inputdata::String)
for (dir, files) in pairs(files_by_dir)
files = filter(files)
for file in files
@debug "Pushing file to backend" backend=basename(tagger.backend_dir) instance=tagger.model_instance file=file
@debug "Pushing file to backend" backend=backend_name instance=tagger.model_instance file=file
dest_dir = normpath(joinpath(raw_data_dir, dir))
mkpath(dest_dir)
dest_file = joinpath(dest_dir, basename(file))
......@@ -107,7 +108,7 @@ function push(tagger::Tagger, inputdata::String)
file = abspath(inputdata)
files = filter([file])
for file in files
@info "Pushing file to backend" backend=basename(tagger.backend_dir) instance=tagger.model_instance file=file
@info "Pushing file to backend" backend=backend_name instance=tagger.model_instance file=file
dest_file = normpath(joinpath(raw_data_dir, basename(file)))
isnothing(destination) && (destination = dest_file)
src_file = normpath(file)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment