Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

YahooFinanceProcessor failure to download the market data #87

Open
randheerDas opened this issue May 13, 2024 · 6 comments
Open

YahooFinanceProcessor failure to download the market data #87

randheerDas opened this issue May 13, 2024 · 6 comments

Comments

@randheerDas
Copy link

I am facing an issue while executing the code to download market data.

Following is the error:

1 Failed download:
['AXP']: Exception('%ticker%: No price data found, symbol may be delisted (1d 2008-01-01 00:00:00 -> 2008-01-02 00:00:00)')

And this keeps repeating and it never ends.

I feel there is a bug here either in finrl or in yfinance. My old tutorial runs well.

Following is my current configuration:

Python 3.10 , Finrl = finrl-0.3.6 and yfinance-0.2.38

Screenshot

[
FinRlTutorialLatest-Error
]

@ven7782
Copy link

ven7782 commented Aug 5, 2024

This is not an issue. The error is because you are trying to download the data for Sat, Sun and public holiday which does not exist. If you check the dates, they are moving forward regardless.

@RontheSlow
Copy link

I have a similar problem. My software is the same version. I have a while loop that repeatedly pulls stock values until a condition is met. The loop works for several minutes then gives the data not found message. I can restart the program and it again works for several minutes than fails. The sleep function at the end is so that the data request is executed only 1 per minute. Any ideas on how to prevent this from failing are appreciated.

while MO == 0:

print("ctrl c will close a program from an infinite loop. Voice of experience.")

Count1 += 1

HL = current_price("HL")
now = datetime.datetime.now().strftime("%Y-%m-%d-%H-%M")
minuteValue = datetime.datetime.now().strftime("%M")
print ("Counter = ",Count1, "Time is ",now)

I am commenting out the next 2 print lines to see if that fixes the program terminating

print("Time ", now)

print ("Hecla Mining ", HL)

AIM evaluation goes here.

SV = Num_Shr * HL #(assumes ProShres UltraPro)  Can add more SV1, SV2, etc. for the other stocks

print("SV = ",SV)

BR = SV*.1  # BR stands for Buy Resistance
SR = SV*.12  # Sell Resistance (SR), the multipliers are different to encourage a little more selling that buying so that you don't run out of cash.
if PC > (SV + BR):   # Has the stock dropped in value, if yes, time to look at buying some more.
		Advice = PC - (SV+BR)
		Buy = Advice 
		print ("Buy this many dollars ", Buy)  # with 5000, 50, 5000, this results in Buy roughly 500
		MO = Buy
		#  Program terminates if Buy condition is satisfied
elif SV> (PC + SR):
		Sell = (SV - SR)-PC
		if Sell > 0.2 * SR:
			MO = Sell
			print ("Sell this many dollars ", Sell)
			#  Program terminates if Sell condition is satisfied
		else:
			 MO = 0

print("made it to MO = 0")

else:
	dosleep = 1
	while dosleep == 1:

@ven7782
Copy link

ven7782 commented Aug 13, 2024

What is your error message?

@leozhang9
Copy link

similar problem,can't download the data

@RontheSlow
Copy link

This is the error message I get after the program runs through the while loop for awhile.
image

Any and all help is appreciated

@ven7782
Copy link

ven7782 commented Aug 20, 2024

Data is missing for that bar. Open the csv file and check if data is present for 13:38 or 13:39. You need to handle missing data.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants