From 0f2bdae15f809be0c7f8534224f81b19c1fa2039 Mon Sep 17 00:00:00 2001 From: Luis Fernando Molina Date: Sat, 17 Feb 2018 11:45:20 +0100 Subject: [PATCH] Fixing to run without month or year --- .vs/AAOlivia/v15/.suo | Bin 33792 -> 33792 bytes AAOlivia.njsproj | 9 ++------- Multi-Period-Market/Interval.js | 30 +----------------------------- this.bot.config.json | 12 ++++++------ 4 files changed, 9 insertions(+), 42 deletions(-) diff --git a/.vs/AAOlivia/v15/.suo b/.vs/AAOlivia/v15/.suo index 45232f6e92c50965fecc80d2a5958c5cff10de1f..b27bc341ed11922adc40fedfa2a22b145c98774c 100644 GIT binary patch delta 2123 zcmd6oT}+#06vz9#yoCa#yrV6ju5>Wyi?mP}Wo4PAT?@i60j4zzVB(z2I!ncsF0z;a zk|n#qWxU4=ja(?s>_(TcH*wzCMJ^UGnTy_N{8+LJKN2H;EE$@B|5HHOB)fC*Nq&9a z=bXdyob!J^m^>p*o{`S&7dZ)#9t9W(U4@ zf(O7V{3`l7;07GetqGA!~zi;Jy*XZvDvg&96BjC$j0_Ila$M^4pF8Mbm@2W5blWoXzHu?SrxkC*hPVqS@$@86XbNOGT);+G-3(v(ug8$ zUdZ#9yhR$iZC~O#bf-@hbk*Y4$69B^CGVohh{#uzr!_|L@wUFwxU{|9mm_Hn5njO9 zgvfVjyx~vbqEzFfbhX%Rtc6X|SFDICRdgk=EariF-P!=+NUP5yp)g z!aCO?0X=;vm?>q^a*tAIrL1@T#AS{pa-R=KD2cq1iPGV0uEMBATl0sJN768CcnOk( zqL;;GiVvPPbtlG#PnTJ-|81%-$lnZTIG*gMp;$A0J!ms;XWSY|!KYmFos!Yp z)Y{TY_L1tmqmYGfbmUzu`vRSf+33?~uAY8!QqULCO6rWgHGfn{&nNJw^<*2_ZR7W+ z81Mz)cYqs(1}gZ*8MKfD>;cNUn!7&xvrT=ieMA8y!nUFHJzkfJ{FS3OC{)GKt>rQ$W<|FY*d#tJP@nT-6NjM6U?-Q-A?(>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QM7R)4JR}|#R+^Wcs9>ZWfiARnf!1M8a_}M~43)lVy3*k?S diff --git a/AAOlivia.njsproj b/AAOlivia.njsproj index e497b5ee8..8ab422a6c 100644 --- a/AAOlivia.njsproj +++ b/AAOlivia.njsproj @@ -6,7 +6,8 @@ {aa2901bc-8f81-40f0-a402-5ca79a3f22ad} ShowAllFiles - Multi-Period-Market\run.js + + c:\users\luis\source\repos\AAOlivia\Multi-Period-Market . {3AF33F2E-1136-4D97-BBB7-1795711AC8B8};{349c5851-65df-11da-9384-00065b846f21};{9092AA53-FB77-4645-B42D-1CCCA6BD08BD} @@ -19,12 +20,7 @@ - - - - - @@ -33,7 +29,6 @@ - diff --git a/Multi-Period-Market/Interval.js b/Multi-Period-Market/Interval.js index 466eaeae6..79a02bfcc 100644 --- a/Multi-Period-Market/Interval.js +++ b/Multi-Period-Market/Interval.js @@ -96,35 +96,7 @@ Read the candles and volumes from Bruce and produce a single Index File for each try { if (LOG_INFO === true) { - logger.write("[INFO] Entering function 'start', with year = " + year + " and month = " + month); - } - - let processDate = new Date(year + "-" + month + "-1 00:00:00.000 GMT+0000"); - - let lastMinuteOfMonth = new Date(year + "-" + month + "-1 00:00:00.000 GMT+0000"); - - lastMinuteOfMonth.setUTCMonth(lastMinuteOfMonth.getUTCMonth() + 1); // First we go 1 month into the future. - lastMinuteOfMonth.setUTCSeconds(lastMinuteOfMonth.getUTCSeconds() - 30); // Then we go back 30 seconds, or to the last minute of the original month. - - let thisDatetime = new Date(); - - if ((year === thisDatetime.getUTCFullYear() && parseInt(month) > thisDatetime.getUTCMonth() + 1) || year > thisDatetime.getUTCFullYear()) { - - logger.write("[INFO] We are too far in the future. Interval will not execute. Sorry."); - return; - - } - - let atHeadOfMarket; // This tell us if we are at the month which includes the head of the market according to current datetime. - - if ((year === thisDatetime.getUTCFullYear() && parseInt(month) === thisDatetime.getUTCMonth() + 1)) { - - atHeadOfMarket = true; - - } else { - - atHeadOfMarket = false; - + logger.write("[INFO] Entering function 'start'"); } let nextIntervalExecution = false; // This tell weather the Interval module will be executed again or not. By default it will not unless some hole have been found in the current execution. diff --git a/this.bot.config.json b/this.bot.config.json index 5cec80417..48c155288 100644 --- a/this.bot.config.json +++ b/this.bot.config.json @@ -11,17 +11,17 @@ "description": "Produces different files with multi-period candles and volumes for entire markets.", "startMode": { "allMonths": { - "run": "true", - "minYear": "2014", - "maxYear": "2018" + "run": "false", + "minYear": "", + "maxYear": "" }, "oneMonth": { "run": "false", - "year": "2018", - "month": "2" + "year": "", + "month": "" }, "noTime": { - "run": "false" + "run": "true" } }, "intervalLapse": 3600000,