ozgur/python-firebase

SyntaxError: invalid syntax

Opened this issue · 10 comments

I have just included the library and got this error

(base) bash-3.2$ python firebase_app.py
Traceback (most recent call last):
File "firebase_app.py", line 2, in
from firebase import firebase
File "/Users/manoj/anaconda3/lib/python3.7/site-packages/firebase/init.py", line 3
from .async import process_pool
^
SyntaxError: invalid syntax

here is the source:


from firebase import firebase
import requests
import json

def get_firebase_data():
    firebase = firebase.FirebaseApplication('https://my_storage.firebaseio.com', None)
    result = firebase.get('/words', None)
    print(result)

I just got the same error immediately upon including the library and running almost the same code as @mjangid .

Any update on this. It seems critical issue as it doesn't support Python 3.7

Anu update on this? I just got some issue

I think this issue was fixed on this commit: 9fccf87

And it hasn't propagated into pip packages yet. I solved the issue by cloning the repo and manually moving the python module code into my .virtualenv/lib/python3.8/site-packages/firebase folder. This may work for some of you?

Dear Ozgur,

When can we expect the public versions of this to be updated in pip for 3.7 and higher?

As a result of the bug, we have ~19 grad students and a few TAs who won't be using firebase as originally planned.

It isn't realistic for the teaching staff to be helping a couple dozen students debug various versions of 3rd party code as part of their homework assignments, and editing 3rd party libraries isn't a practice we want to encourage or condone.

Thanks, Mark

Hi @cs5001spr20, I'll work on updating the pip version of the project to support python 3.7 and higher. Hopefully, there are pull requests for Python 3.7 compatibility. Once we all the tests have passed, I will push it to PyPi. Both Ozgur and I are maintainers of the project, but we've been dormant due to work.

@tomlockwood Your solution worked, thank you.
Additionally, @b4oshany is there any progress on updating the pip version? According to https://pypi.org/project/python-firebase/#history it wasn't updated since 2014!

Just add,

...
git+https://github.com/ozgur/python-firebase

to your requirements.txt for now.