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

Not able to login #34

Open
barrynorman opened this issue Mar 11, 2024 · 2 comments
Open

Not able to login #34

barrynorman opened this issue Mar 11, 2024 · 2 comments

Comments

@barrynorman
Copy link

barrynorman commented Mar 11, 2024

Thanks for this python package.
I was wondering if someone can tell me what I'm doing wrong.

from ejtraderCT import Ctrader
import time
import logging

logging.getLogger().setLevel(logging.INFO)

SERVER="demo1.p.ctrader.com"
LOGIN="demo.purpletradingprop.12346679"
PASSWORD="XXX"
CURRENCY="USD"

api = Ctrader(server=SERVER, account=LOGIN, password=PASSWORD, currency=CURRENCY, debug=True)

checkConnection = api.isconnected()
print("Is Connected?: ", checkConnection)
time.sleep(1)

quote = api.quote()
print(quote)

My output:

INFO:root:Market is Close or Disconnected 'NoneType' object is not callable
INFO:root:Market is Close or Logged out 'NoneType' object is not callable

Thanks for the help.

I tested also Python 3.9 but I have the same problem

Copy link

We're glad you've opened your first issue. Please provide all the necessary details and any relevant code or screenshots to help us understand the problem better. Our team will review your issue and provide assistance as soon as possible. Thank you for contributing!

@traderpedroso
Copy link
Member

Thanks for this python package. I was wondering if someone can tell me what I'm doing wrong.

from ejtraderCT import Ctrader
import time
import logging

logging.getLogger().setLevel(logging.INFO)

SERVER="demo1.p.ctrader.com"
LOGIN="demo.purpletradingprop.12346679"
PASSWORD="XXX"
CURRENCY="USD"

api = Ctrader(server=SERVER, account=LOGIN, password=PASSWORD, currency=CURRENCY, debug=True)

checkConnection = api.isconnected()
print("Is Connected?: ", checkConnection)
time.sleep(1)

quote = api.quote()
print(quote)

My output:

INFO:root:Market is Close or Disconnected 'NoneType' object is not callable
INFO:root:Market is Close or Logged out 'NoneType' object is not callable

Thanks for the help.

I tested also Python 3.9 but I have the same problem

I suggest you try testing with an IC Markets account. Sometimes, some forex brokers do not allow access to a demo account through FIX API. Check with your broker or conduct the test on IC Markets. Up until the date I used it, it worked normally on a demo account.

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

2 participants