Download | Wiki

PTFeeder does not read email


#1

Hi,
My PT-Feeder is working well, exept from reading email (GMail).
my config is like
“Email”: {
“ImapServer”: “imap.gmail.com”,
“ImapPort”: “993”,
“ImapUsername”: “@gmail.com",
“ImapPassword”: "

“FromAddress”: "noreply@tradingview.com”, // this is the only from address that PTF will act on
“Subject”: “TradingView Alert” // this is what should be contained in the subject line for PTF to act on the email
},

in the logs i found a few times
2018-11-07 11:40:13.583 +01:00 [Information] Logging into email

I had some problems with the installation and returned a snapshot on my VMWare, should i delete the database?


#2

Have you setup your tradingview alerts like this: https://wiki.ptfeeder.co/advanced.html#trading-view-alerts?


#3

Thanks for the quick response,

Yes i did, i noticed also i had the wrong dot net version, updated it to 2.1.4

Now it reading email, but the subject differs from the config rule.
“Subject”: “TradingView Alert” // this is what should be contained in the subject line for PTF to act on the email

the subject tradingview is sending is: TradingView Alert: BINANCE:ADABTC SELL


#4

That should be ok, as long as the subject is in your config is included in Subject.

If it isn’t working, can you also send me an example of the alert text you are using and the section of your appsettings that reacts on TV alerts.


#5

{
“PtFeeder”: {
“BaseCurrency”: “BTC”,
“MaxTrailingProfit”: “999999”, // This is set extremely high, so that Profit Trailer will not sell without an alert.
“MinTrailingProfit”: “0”,
“MaxTrailingBuy”: “999999”, // This is set extremely high, so that Profit Trailer will not buy without an alert.
“MinTrailingBuy”: “0”,
“EnabledCoinsOnly”: “POLY”, // Whitelist. All coins with alerts on TradingView should be listed here.
“MinutesForLongerTermTrend”: “1440”,
“MinutesToMeasureMediumTrend”: “240”,
“MinutesToMeasureTrend”: “60”,
“TopCurrenciesToCheck”: “40”
},
“Common”: {
“KeepBalance”: “0”,
“KeepBalancePercentage”: “0”,
“MaxTradingPairs”: “1”, // This should be >= the number of coins with alerts on TradingView.
“OrderbookProfitCalculation”: “TRUE”,
“StartBalance”: “10”,
“BtcDust”: “0.000999”,
“EthDust”: “0.00999”,
“BnbDust”: “0.0105”,
“UsdtDust”: “9.99”,
“PriceTriggerMarket”: “BTC”,
“IndicatorsSomTriggerLength”: “288”,
“IndicatorsBbCandlePeriod”: “300”,
“IndicatorsBbLength”: “20”,
“IndicatorsBbStd”: “2”,
“IndicatorsSmaCandlePeriod”: “300”,
“IndicatorsSmaFastLength”: “8”,
“IndicatorsSmaSlowLength”: “13”,
“IndicatorsSmaCrossCandles”: “2”,
“IndicatorsEmaCandlePeriod”: “300”,
“IndicatorsEmaFastLength”: “12”,
“IndicatorsEmaSlowLength”: “26”,
“IndicatorsEmaCrossCandles”: “2”,
“IndicatorsRsiCandlePeriod”: “300”,
“IndicatorsRsiLength”: “14”,
“IndicatorsStochCandlePeriod”: “300”,
“IndicatorsStochLength”: “14”,
“IndicatorsMacdCandlePeriod”: “300”,
“IndicatorsMacdFastLength”: “12”,
“IndicatorsMacdSlowLength”: “26”,
“IndicatorsMacdSignal”: “9”,
“IndicatorsObvCandlePeriod”: “300”,
“IndicatorsObvLength”: “50”,
“IndicatorsObvSignal”: “1”,
“DcaKeepBalance”: “0”,
“DcaKeepBalancePercentage”: “0”,
“DcaOrderbookProfitCalculation”: “TRUE”,
},
“Defaults”: {
“PanicSellEnabled”: “FALSE”,
“SellOnlyModeEnabled”: “FALSE”,
“InitialCost”: “1”, // This will determine the amount of the initial purchase.
“InitialCostPercentage”: “10”, // This will determine the amount of the initial purchase.
“TrailingBuy”: “999999”, // This is set extremely high, so that Profit Trailer will not buy without an alert.
“ABuyStrategy”: “LOSS”,
“ABuyValue”: “-101”, // This is set extremely high, so that Profit Trailer will not buy without an alert.
“DcaEnabled”: “TRUE”, // This will immediately force all coin pairs into DCA, to allow pyramiding.
“MaxBuySpread”: “9”, // If too low, this will restrict purchases via script.
“MinBuyPrice”: “0”,
“MinBuyVolume”: “0”,
“MinOrderbookVolumePercentage”: “100”,
“RebuyTimeout”: “5”,
“TrailingProfit”: “999999”, // This is set extremely high, so that Profit Trailer will not sell without an alert.
“ASellStrategy”: “GAIN”,
“ASellValue”: “999999”, // This is set extremely high, so that Profit Trailer will not sell without an alert.
“DcaMaxCost”: “10”, // If too low, this will restrict quantities of additional purchases via script. // Remember that this is actual value, and not a percentage.
“DcaMaxBuyTimes”: “100”, // If too low, this will restrict quantities of additional purchases via script.
“DcaTrailingBuy”: “999999”, // This is set extremely high, so that Profit Trailer will not buy without an alert.
“DcaABuyStrategy”: “LOSS”,
“DcaABuyValue”: “-101”, // This is set extremely high, so that Profit Trailer will not buy without an alert.
“DcaIgnoreSellOnlyMode”: “TRUE”,
“DcaMaxBuySpread”: “9”, // If too low, this will restrict quantities of additional purchases via script.
“DcaMinBuyVolume”: “0”,
“DcaMinOrderbookVolumePercentage”: “100”,
“DcaRebuyTimeout”: “5”,
“DcaTrailingProfit”: “999999”, // This is set extremely high, so that Profit Trailer will not sell without an alert.
“DcaASellStrategy”: “GAIN”,
“DcaASellValue”: “999999”, // This is set extremely high, so that Profit Trailer will not sell without an alert.
“DcaBuyTrigger”: “0”, // This is set to Zero, so that Profit Trailer will make subsequent buys // with an alert.
“DcaBuyPercentage1”: “100”, // These are set, so that subsequent buys will be approximately the // same amount as the initial alert.
“DcaBuyPercentage2”: “50”,
“DcaBuyPercentage3”: “33.3333333333333”,
“DcaBuyPercentage4”: “25”,
“DcaBuyPercentage5”: “20”,
“DcaBuyPercentage6”: “16.6666666666667”,
“DcaBuyPercentage7”: “14.2857142857143”,
“DcaBuyPercentage8”: “12.5”,
“DcaBuyPercentage9”: “11.1111111111111”,
“DcaBuyPercentage10”: “10”,
“DcaBuyPercentage11”: “9.09090909090909”,
“DcaBuyPercentage12”: “8.33333333333333”,
“DcaBuyPercentage13”: “7.69230769230769”,
“DcaBuyPercentage14”: “7.14285714285714”,
“DcaBuyPercentage15”: “6.66666666666667”,
“DcaBuyPercentage16”: “6.25”,
“DcaBuyPercentage17”: “5.88235294117647”,
“DcaBuyPercentage18”: “5.55555555555556”,
“DcaBuyPercentage19”: “5.26315789473684”,
“DcaBuyPercentage20”: “5”,
“DcaBuyPercentage21”: “4.76190476190476”,
“DcaBuyPercentage22”: “4.54545454545455”,
“DcaBuyPercentage23”: “4.34782608695652”,
“DcaBuyPercentage24”: “4.16666666666667”,
“DcaBuyPercentage25”: “4”,
“DcaBuyPercentage26”: “3.84615384615385”,
“DcaBuyPercentage27”: “3.7037037037037”,
“DcaBuyPercentage28”: “3.57142857142857”,
“DcaBuyPercentage29”: “3.44827586206897”,
“DcaBuyPercentage30”: “3.33333333333333”,
“DcaBuyPercentage31”: “3.2258064516129”,
“DcaBuyPercentage32”: “3.125”,
“DcaBuyPercentage33”: “3.03030303030303”,
“DcaBuyPercentage34”: “2.94117647058824”,
“DcaBuyPercentage35”: “2.85714285714286”,
“DcaBuyPercentage36”: “2.77777777777778”,
“DcaBuyPercentage37”: “2.7027027027027”,
“DcaBuyPercentage38”: “2.63157894736842”,
“DcaBuyPercentage39”: “2.56410256410256”,
“DcaBuyPercentage40”: “2.5”,
“DcaBuyPercentage41”: “2.4390243902439”,
“DcaBuyPercentage42”: “2.38095238095238”,
“DcaBuyPercentage43”: “2.32558139534884”,
“DcaBuyPercentage44”: “2.27272727272727”,
“DcaBuyPercentage45”: “2.22222222222222”,
“DcaBuyPercentage46”: “2.17391304347826”,
“DcaBuyPercentage47”: “2.12765957446808”,
“DcaBuyPercentage48”: “2.08333333333333”,
“DcaBuyPercentage49”: “2.04081632653061”,
“DcaBuyPercentage50”: “2”,
“DcaBuyPercentage51”: “1.96078431372549”,
“DcaBuyPercentage52”: “1.92307692307692”,
“DcaBuyPercentage53”: “1.88679245283019”,
“DcaBuyPercentage54”: “1.85185185185185”,
“DcaBuyPercentage55”: “1.81818181818182”,
“DcaBuyPercentage56”: “1.78571428571429”,
“DcaBuyPercentage57”: “1.75438596491228”,
“DcaBuyPercentage58”: “1.72413793103448”,
“DcaBuyPercentage59”: “1.69491525423729”,
“DcaBuyPercentage60”: “1.66666666666667”,
“DcaBuyPercentage61”: “1.63934426229508”,
“DcaBuyPercentage62”: “1.61290322580645”,
“DcaBuyPercentage63”: “1.58730158730159”,
“DcaBuyPercentage64”: “1.5625”,
“DcaBuyPercentage65”: “1.53846153846154”,
“DcaBuyPercentage66”: “1.51515151515151”,
“DcaBuyPercentage67”: “1.49253731343284”,
“DcaBuyPercentage68”: “1.47058823529412”,
“DcaBuyPercentage69”: “1.44927536231884”,
“DcaBuyPercentage70”: “1.42857142857143”,
“DcaBuyPercentage71”: “1.40845070422535”,
“DcaBuyPercentage72”: “1.38888888888889”,
“DcaBuyPercentage73”: “1.36986301369863”,
“DcaBuyPercentage74”: “1.35135135135135”,
“DcaBuyPercentage75”: “1.33333333333333”,
“DcaBuyPercentage76”: “1.31578947368421”,
“DcaBuyPercentage77”: “1.2987012987013”,
“DcaBuyPercentage78”: “1.28205128205128”,
“DcaBuyPercentage79”: “1.26582278481013”,
“DcaBuyPercentage80”: “1.25”,
“DcaBuyPercentage81”: “1.23456790123457”,
“DcaBuyPercentage82”: “1.21951219512195”,
“DcaBuyPercentage83”: “1.20481927710843”,
“DcaBuyPercentage84”: “1.19047619047619”,
“DcaBuyPercentage85”: “1.17647058823529”,
“DcaBuyPercentage86”: “1.16279069767442”,
“DcaBuyPercentage87”: “1.14942528735632”,
“DcaBuyPercentage88”: “1.13636363636364”,
“DcaBuyPercentage89”: “1.12359550561798”,
“DcaBuyPercentage90”: “1.11111111111111”,
“DcaBuyPercentage91”: “1.0989010989011”,
“DcaBuyPercentage92”: “1.08695652173913”,
“DcaBuyPercentage93”: “1.0752688172043”,
“DcaBuyPercentage94”: “1.06382978723404”,
“DcaBuyPercentage95”: “1.05263157894737”,
“DcaBuyPercentage96”: “1.04166666666667”,
“DcaBuyPercentage97”: “1.03092783505155”,
“DcaBuyPercentage98”: “1.02040816326531”,
“DcaBuyPercentage99”: “1.01010101010101”,
“DcaBuyPercentage100”: “1”
},
“MarketConditionsGrouping”: { // PT Feeder will shut down if no Market Conditions are set. // Note that no offsets are made.
“Configs”: [
{ “Name”: “Bear”,
“MaxBaseCoinPriceChange”: “-2”
},
{ “Name”: “Neutral”,
“MaxBaseCoinPriceChange”: “2”
},
{ “Name”: “Bull”,
“MaxBaseCoinPriceChange”: “999999”
}
]
},
“TradingViewSignalsGrouping”: { // PT Feeder will not recognize TradingView Signals without this grouping.
// Note that all overrides are contained within the TradingView alerts.
“Condition”: “[pair.SignalDetected] == true”,
“Configs”: [
{
“Override”: {
“Weight”: “100”
}
}
]
},
}

“Email”: {
“ImapServer”: “imap.gmail.com”,
“ImapPort”: “993”,
“ImapUsername”: “****@gmail.com”,
“ImapPassword”: “*****”,
“FromAddress”: "noreply@tradingview.com", // this is the only from address that PTF will act on
“Subject”: “TradingView Alert” // this is what should be contained in the subject line for PTF to act on the email

Buy Now
BINANCE:POLYBTC
SET
ABuyStrategy=RSI
ABuyValue=100
TrailingBuy=0
DcaABuyStrategy=RSI
DcaABuyValue=100
DcaTrailingBuy=0
Weight=100


#6

Which version of Feeder are you using?


#7

i used ptf 1.6 and also ptf1.7b4
both dont read the mail, logging in but not reading or processing


#8

Additional info

image


#9

all mail in Gmail is unread


#10

If you are using the beta, the first line in your alert message needs to be BINANCE:POLYBTC for example, Sell now will not work.


#11

I changed the Tradingview comments, and rolled back to PTF 1.6
The above appsettings where for 1.6, translating them into 1.7 gives errors


#12

Ok, send an update once you get some alerts through


#13

Hi,

One step further, ptfeeder 1.7b4 configured and it is reading mail. But,

only the line BINANCE:BTCUSDT from TV, not if there are any set commands in the subject.

ptf-logfile says:
11/17/18 4:50:00 PM
PT2TESTFeeder
USDT-BTC
Exchange:Binance
From:TradingView
Latency:4s
Message:
BINANCE:BTCUSDT


#14

Can you show me the contents of that email that the alert? Or was that one without any commands? If so, can you show me one of the unread emails?


#15

attached the mail with the message field filled in. PTF doesn’t read/touch this mail.
I only reads it when in the TV message bos is BINANCE:BTCUSDT
Or do have to use commas and accolades?


#16

PTFeeder keeps also reading/processing old mails.
2018-11-17 19:05:15.563 +01:00 [Information] 0 out of 1 pairs queried
2018-11-17 19:05:15.566 +01:00 [Information] Signal detected:
11/17/18 6:05:02 PM
PT2TESTFeeder
USDT-BTC
Exchange:Binance
From:TradingView
Latency:3s
Message:
BINANCE:BTCUSDT

2018-11-17 19:05:15.590 +01:00 [Information] PAIRS.properties 1 out of 1 pairs queried.
2018-11-17 19:05:15.591 +01:00 [Information] Writing PAIRS.properties file to /var/opt/pt/ptf-generated-config
2018-11-17 19:05:15.593 +01:00 [Information] PAIRS.properties file written
2018-11-17 19:05:15.795 +01:00 [Information] 0 out of 1 pairs queried
2018-11-17 19:05:15.799 +01:00 [Information] Signal detected:
11/17/18 6:05:02 PM
PT2TESTFeeder
USDT-BTC
Exchange:Binance
From:TradingView
Latency:3s
Message:
BINANCE:BTCUSDT

2018-11-17 19:05:15.823 +01:00 [Information] DCA.properties 1 out of 1 pairs queried.


#17

It odd. I can’t seem to see what’s wrong. Can you set this property to Debug. It should give some more information in the logs https://wiki.ptfeeder.co/configuration.html#section-serilog


#18

Sure, i will.

Noticed also mail timestamp GMAIL 19:25 timestamp, it differs 1 hour with log in PTFeeder
LOG1
2018-11-17 19:25:09.406 +01:00 [Information] Signal detected:
11/17/18 6:25:00 PM
PT2TESTFeeder
USDT-BTC
Exchange:Binance
From:TradingView
Latency:4s
Message:
BINANCE:BTCUSDT

Debug Log:
2018-11-17 19:45:30.107 +01:00 [Debug] Ignoring email ‘TradingView Alert: Buy Now BINANCE:BTCUSDT SET ASellStrategy=GAIN ASellValue=0.1 TrailingProfit=0 DcaASellStrategy=GAIN DcaASellValue=0.1 DcaTrailingProfit=0 Weight=100’ as there is no hostname

2018-11-17 19:48:35.653 +01:00 [Debug] Initial email query resulted in 1 emails to check
2018-11-17 19:48:35.789 +01:00 [Debug] Ignoring email ‘TradingView Alert: Buy Now BINANCE:BTCUSDT SET ASellStrategy=GAIN ASellValue=0.1 TrailingProfit=0 DcaASellStrategy=GAIN DcaASellValue=0.1 DcaTrailingProfit=0 Weight=100’ as there is no hostname
2018-11-17 19:48:41.406 +01:00 [Debug] Initial email query resulted in 1 emails to check
2018-11-17 19:48:41.539 +01:00 [Debug] Ignoring email ‘TradingView Alert: Buy Now BINANCE:BTCUSDT SET ASellStrategy=GAIN ASellValue=0.1 TrailingProfit=0 DcaASellStrategy=GAIN DcaASellValue=0.1 DcaTrailingProfit=0 Weight=100’ as there is no hostname

2018-11-17 19:56:19.578 +01:00 [Debug] Ignoring email ‘TradingView Alert: Buy Now BINANCE:BTCUSDT SET ASellStrategy=GAIN ASellValue=0.1 TrailingProfit=0 DcaASellStrategy=GAIN DcaASellValue=0.1 DcaTrailingProfit=0 Weight=100’ as there is no hostname
2018-11-17 19:56:19.704 +01:00 [Debug] Ignoring email ‘TradingView Alert: Sell Now BINANCE:BTCUSDT SET ABuyStrategy=RSI ABuyValue=55 BBuyStrategy=DISABLED Weight=100’ as there is no hostname
2018-11-17 19:56:19.836 +01:00 [Debug] Ignoring email ‘TradingView Alert: BINANCE:BTCUSDT SET ASellStrategy=GAIN ASellValue=0.1 TrailingProfit=0 DcaASellStrategy=GAIN DcaASellValue=0.1 DcaTrailingProfit=0 Weight=100’ as there is an incorrect base currency


#19

So that’s quite useful.

The first one (hostname not set) means that the alert has a line before the BINANCE:BTCUSDT which isnt the hostname of your bot set in your hostsettings.

The second (incorrect base) is that your alert coin does not match the base currency in your appsettings. For example, BTCUSDT needs a baseCurrency of USDT


#20

This is my basecurrency part in the appsettings.
{
“PtFeeder”:{
“BaseCurrency”:“USDT”,
“EnabledCoinsOnly”:“BTC”,