progress and fixes

This commit is contained in:
Cryptoval Trading Technologies
2026-01-07 22:16:00 +00:00
parent ee4d264ad2
commit a821e8f7a8
5 changed files with 18 additions and 15 deletions
+3 -2
View File
@@ -21,11 +21,12 @@ run_retrofit() {
mkdir -p ${LogDir}
Cmd="nohup ${RunDir}/${Script} ${Source} ${Params} > ${LogDir}/$(date '+%Y%m%d_%H%M%S').${Script}.${Source}.log 2>&1 &"
print_and_run ${Cmd}
echo ${Cmd}
eval ${Cmd}
}
for src in cloud28 cloud29; do
run_retrofit retrofit_crypto.sh $src
done
run_retrofit sim_crypto_retrofit.sh
#run_retrofit sim_crypto_retrofit.sh
+1 -1
View File
@@ -12,7 +12,7 @@ FileGlob=${FILE_GLOB:-${DEFAULT_FGLOB}}
BackDaysCount=${BACKDAYS_COUNT:-50}
echo "======================= Alpaca MD"
Cmd="get_equity_retrofit_dates ${Source} /works/cvtt/md_archive/equity/alpaca_md/2025/N/NVDA ${FileGlob} ${BackDaysCount}"
Cmd="get_equity_retrofit_dates ${Source} /works/cvtt/md_archive/equity/alpaca_md/*/N/NVDA/${FileGlob} ${BackDaysCount}"
echo $Cmd
DATES=$($Cmd)
+7 -6
View File
@@ -86,12 +86,12 @@ is_equity_business_date() {
}
get_equity_retrofit_dates() {
# get_equity_retrofit_dates cvtt@cloud21.cvtt.vpn /works/cvtt/md_archive/equity/alpaca_md/*/N/NVDA/*.alpaca_1m_bars.db.gz 50
local host=${1:-}
local root_dir=${2:-}
local filename_glob=${3:-}
local day_count=${4:-}
local filename_glob=${2:-}
local day_count=${3:-}
if [[ -z "$host" || -z "$root_dir" || -z "$filename_glob" || -z "$day_count" ]]; then
if [[ -z "$host" || -z "$filename_glob" || -z "$day_count" ]]; then
echo "usage: get_equity_retrofit_dates <host> <root_dir> <filename_glob> <day_count>" >&2
return 1
fi
@@ -118,13 +118,14 @@ get_equity_retrofit_dates() {
declare -A existing_dates=()
local remote_cmd remote_output entry
printf -v remote_cmd "cd %q 2>/dev/null && LC_ALL=C ls -1 %s" "$root_dir" "$filename_glob"
remote_cmd="ls ${filename_glob}"
remote_output=$(ssh "$host" "$remote_cmd" 2>/dev/null || true)
if [[ -n "$remote_output" ]]; then
while IFS= read -r entry; do
[[ -z "$entry" ]] && continue
if [[ "$entry" =~ ^([0-9]{8}) ]]; then
fname=$(basename $entry)
if [[ "$fname" =~ ^([0-9]{8}) ]]; then
existing_dates["${BASH_REMATCH[1]}"]=1
fi
done <<<"$remote_output"