Issue running airflow on Mac M1: error in Flask-OpenID setup command: use_2to3 is invalid

We Are Going To Discuss About Issue running airflow on Mac M1: error in Flask-OpenID setup command: use_2to3 is invalid. So lets Start this Article.

Issue running airflow on Mac M1: error in Flask-OpenID setup command: use_2to3 is invalid

How to solve Issue running airflow on Mac M1: error in Flask-OpenID setup command: use_2to3 is invalid

Yes. It’s been fixed in flask_openid 1.2.6 (It’s not a problem with Airflow but with FlaskOpenID).
Looks like for some reason your setuptools is not what you think it is. See:
https://github.com/pallets-eco/flask-openid/issues/59
You have not explained a crucial things – how you are installing airflow, neither which version of Airflow you try to install – which does not help in trying to help you unfortunately, so I have to make some guesses. Here is what you can do if you cannot – for any reason – downgrade to setuptools < 0.58.
If you are using Airlfow 2 and using constraints (as you should – this is the only supported way https://airflow.apache.org/docs/apache-airflow/stable/installation/installing-from-pypi.html) for some older version of Airflow, then possibly flask-openid is 1.2.5 in those old constraint versions. Please check it and if you REALLY want to stay with an older version, then you can download the constraint file locally, modify flask-openid version to 1.2.6 and point to the file instead of the github URL as you should do normally (If you don’t use constraints – start using them immediately).
However, better option than installing an old version of Airflow, will be to update to the latest version of Airflow (currently 2.2.2 but we are about to start voting on 2.2.3), where this problem is for sure fixed (also in few other versions). Airflow folows SemVer so you should be generally safe to migrate to 2.2.2 if you’ve used an earlier version of Airflow 2.
If you are trying to install Airflow 1.10.* – then don’t do it. Move Airflow 2 immediately. Airflow 1.10 has reached end of life in June 2021 and it’s almost half a year as it did not receive any fixes – it won’t receive any fixes for the Flask OpenID problem, so you are pretty much on your own here.
Also you make yourself vulnerable to unpatched security issues (Airlfow 1.10 stopped receiving also critical security fixes as of June 2021).

Issue running airflow on Mac M1: error in Flask-OpenID setup command: use_2to3 is invalid

Yes. It’s been fixed in flask_openid 1.2.6 (It’s not a problem with Airflow but with FlaskOpenID).
Looks like for some reason your setuptools is not what you think it is. See:
https://github.com/pallets-eco/flask-openid/issues/59
You have not explained a crucial things – how you are installing airflow, neither which version of Airflow you try to install – which does not help in trying to help you unfortunately, so I have to make some guesses. Here is what you can do if you cannot – for any reason – downgrade to setuptools < 0.58.
If you are using Airlfow 2 and using constraints (as you should – this is the only supported way https://airflow.apache.org/docs/apache-airflow/stable/installation/installing-from-pypi.html) for some older version of Airflow, then possibly flask-openid is 1.2.5 in those old constraint versions. Please check it and if you REALLY want to stay with an older version, then you can download the constraint file locally, modify flask-openid version to 1.2.6 and point to the file instead of the github URL as you should do normally (If you don’t use constraints – start using them immediately).
However, better option than installing an old version of Airflow, will be to update to the latest version of Airflow (currently 2.2.2 but we are about to start voting on 2.2.3), where this problem is for sure fixed (also in few other versions). Airflow folows SemVer so you should be generally safe to migrate to 2.2.2 if you’ve used an earlier version of Airflow 2.
If you are trying to install Airflow 1.10.* – then don’t do it. Move Airflow 2 immediately. Airflow 1.10 has reached end of life in June 2021 and it’s almost half a year as it did not receive any fixes – it won’t receive any fixes for the Flask OpenID problem, so you are pretty much on your own here.
Also you make yourself vulnerable to unpatched security issues (Airlfow 1.10 stopped receiving also critical security fixes as of June 2021).

Solution 1

Yes. It’s been fixed in flask_openid 1.2.6 (It’s not a problem with Airflow but with FlaskOpenID).

Looks like for some reason your setuptools is not what you think it is. See:
https://github.com/pallets-eco/flask-openid/issues/59

You have not explained a crucial things – how you are installing airflow, neither which version of Airflow you try to install – which does not help in trying to help you unfortunately, so I have to make some guesses. Here is what you can do if you cannot – for any reason – downgrade to setuptools < 0.58.

If you are using Airlfow 2 and using constraints (as you should – this is the only supported way https://airflow.apache.org/docs/apache-airflow/stable/installation/installing-from-pypi.html) for some older version of Airflow, then possibly flask-openid is 1.2.5 in those old constraint versions. Please check it and if you REALLY want to stay with an older version, then you can download the constraint file locally, modify flask-openid version to 1.2.6 and point to the file instead of the github URL as you should do normally (If you don’t use constraints – start using them immediately).

However, better option than installing an old version of Airflow, will be to update to the latest version of Airflow (currently 2.2.2 but we are about to start voting on 2.2.3), where this problem is for sure fixed (also in few other versions). Airflow folows SemVer so you should be generally safe to migrate to 2.2.2 if you’ve used an earlier version of Airflow 2.

If you are trying to install Airflow 1.10.* – then don’t do it. Move Airflow 2 immediately. Airflow 1.10 has reached end of life in June 2021 and it’s almost half a year as it did not receive any fixes – it won’t receive any fixes for the Flask OpenID problem, so you are pretty much on your own here.
Also you make yourself vulnerable to unpatched security issues (Airlfow 1.10 stopped receiving also critical security fixes as of June 2021).

Original Author Jarek Potiuk Of This Content

Conclusion

So This is all About This Tutorial. Hope This Tutorial Helped You. Thank You.

Also Read,

ittutorial team

I am an Information Technology Engineer. I have Completed my MCA And I have 4 Year Plus Experience, I am a web developer with knowledge of multiple back-end platforms Like PHP, Node.js, Python and frontend JavaScript frameworks Like Angular, React, and Vue.

Leave a Comment