You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2021/06/08 09:53:36 UTC

[GitHub] [superset] nazrulhadi opened a new issue #15035: Unable to upgrade superset database

nazrulhadi opened a new issue #15035:
URL: https://github.com/apache/superset/issues/15035


   Hi guys currently i'm facing and issue regarding superset database when i run the command superset upgrade db  i hit this error regarding the posix issue and saw that the path should be return in string format but receive object
   
   im using python 3.9.5 and this issue also occured in 3.8.10
   
   
   ### Actual results
   ```
   [mohdnazrulhadi@nazrulhadi superset]$ superset db upgrade
   logging was configured successfully
   INFO:superset.utils.logging_configurator:logging was configured successfully
   /home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/flask_caching/__init__.py:201: UserWarning: Flask-Caching: CACHE_TYPE is set to null, caching is effectively disabled.
     warnings.warn(
   Failed to create app
   Traceback (most recent call last):
     File "/usr/lib64/python3.9/pkgutil.py", line 416, in get_importer
       importer = sys.path_importer_cache[path_item]
   KeyError: PosixPath('/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/db_engine_specs')
   
   During handling of the above exception, another exception occurred:
   
   Traceback (most recent call last):
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/app.py", line 62, in create_app
       app_initializer.init_app()
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/app.py", line 552, in init_app
       self.init_app_in_ctx()
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/app.py", line 522, in init_app_in_ctx
       self.configure_url_map_converters()
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/app.py", line 599, in configure_url_map_converters
       from superset.utils.url_map_converters import (
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/utils/url_map_converters.py", line 21, in <module>
       from superset.models.tags import ObjectTypes
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/models/__init__.py", line 17, in <module>
       from . import (
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/models/core.py", line 57, in <module>
       from superset import app, db_engine_specs, is_feature_enabled
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/db_engine_specs/__init__.py", line 40, in <module>
       for (_, name, _) in pkgutil.iter_modules([Path(__file__).parent]):  # type: ignore
     File "/usr/lib64/python3.9/pkgutil.py", line 130, in iter_modules
       for i in importers:
     File "/usr/lib64/python3.9/pkgutil.py", line 420, in get_importer
       importer = path_hook(path_item)
     File "<frozen importlib._bootstrap_external>", line 1601, in path_hook_for_FileFinder
     File "<frozen importlib._bootstrap_external>", line 1476, in __init__
     File "<frozen importlib._bootstrap_external>", line 177, in _path_isabs
   AttributeError: 'PosixPath' object has no attribute 'startswith'
   ERROR:superset.app:Failed to create app
   Traceback (most recent call last):
     File "/usr/lib64/python3.9/pkgutil.py", line 416, in get_importer
       importer = sys.path_importer_cache[path_item]
   KeyError: PosixPath('/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/db_engine_specs')
   
   During handling of the above exception, another exception occurred:
   
   Traceback (most recent call last):
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/app.py", line 62, in create_app
       app_initializer.init_app()
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/app.py", line 552, in init_app
       self.init_app_in_ctx()
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/app.py", line 522, in init_app_in_ctx
       self.configure_url_map_converters()
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/app.py", line 599, in configure_url_map_converters
       from superset.utils.url_map_converters import (
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/utils/url_map_converters.py", line 21, in <module>
       from superset.models.tags import ObjectTypes
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/models/__init__.py", line 17, in <module>
       from . import (
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/models/core.py", line 57, in <module>
       from superset import app, db_engine_specs, is_feature_enabled
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/db_engine_specs/__init__.py", line 40, in <module>
       for (_, name, _) in pkgutil.iter_modules([Path(__file__).parent]):  # type: ignore
     File "/usr/lib64/python3.9/pkgutil.py", line 130, in iter_modules
       for i in importers:
     File "/usr/lib64/python3.9/pkgutil.py", line 420, in get_importer
       importer = path_hook(path_item)
     File "<frozen importlib._bootstrap_external>", line 1601, in path_hook_for_FileFinder
     File "<frozen importlib._bootstrap_external>", line 1476, in __init__
     File "<frozen importlib._bootstrap_external>", line 177, in _path_isabs
   AttributeError: 'PosixPath' object has no attribute 'startswith'
   Traceback (most recent call last):
     File "/usr/lib64/python3.9/pkgutil.py", line 416, in get_importer
       importer = sys.path_importer_cache[path_item]
   KeyError: PosixPath('/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/db_engine_specs')
   
   During handling of the above exception, another exception occurred:
   
   Traceback (most recent call last):
     File "/home/mohdnazrulhadi/superset/venv/bin/superset", line 33, in <module>
       sys.exit(load_entry_point('apache-superset==1.1.0', 'console_scripts', 'superset')())
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/click/core.py", line 829, in __call__
       return self.main(*args, **kwargs)
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/flask/cli.py", line 586, in main
       return super(FlaskGroup, self).main(*args, **kwargs)
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/click/core.py", line 782, in main
       rv = self.invoke(ctx)
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/click/core.py", line 1256, in invoke
       Command.invoke(self, ctx)
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/click/core.py", line 1066, in invoke
       return ctx.invoke(self.callback, **ctx.params)
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/click/core.py", line 610, in invoke
       return callback(*args, **kwargs)
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/click/decorators.py", line 21, in new_func
       return f(get_current_context(), *args, **kwargs)
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/flask/cli.py", line 425, in decorator
       with __ctx.ensure_object(ScriptInfo).load_app().app_context():
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/flask/cli.py", line 381, in load_app
       app = call_factory(self, self.create_app)
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/flask/cli.py", line 119, in call_factory
       return app_factory()
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/app.py", line 69, in create_app
       raise ex
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/app.py", line 62, in create_app
       app_initializer.init_app()
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/app.py", line 552, in init_app
       self.init_app_in_ctx()
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/app.py", line 522, in init_app_in_ctx
       self.configure_url_map_converters()
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/app.py", line 599, in configure_url_map_converters
       from superset.utils.url_map_converters import (
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/utils/url_map_converters.py", line 21, in <module>
       from superset.models.tags import ObjectTypes
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/models/__init__.py", line 17, in <module>
       from . import (
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/models/core.py", line 57, in <module>
       from superset import app, db_engine_specs, is_feature_enabled
     File "/home/mohdnazrulhadi/superset/venv/lib64/python3.9/site-packages/superset/db_engine_specs/__init__.py", line 40, in <module>
       for (_, name, _) in pkgutil.iter_modules([Path(__file__).parent]):  # type: ignore
     File "/usr/lib64/python3.9/pkgutil.py", line 130, in iter_modules
       for i in importers:
     File "/usr/lib64/python3.9/pkgutil.py", line 420, in get_importer
       importer = path_hook(path_item)
     File "<frozen importlib._bootstrap_external>", line 1601, in path_hook_for_FileFinder
     File "<frozen importlib._bootstrap_external>", line 1476, in __init__
     File "<frozen importlib._bootstrap_external>", line 177, in _path_isabs
   AttributeError: 'PosixPath' object has no attribute 'startswith'
   
   ```
   
   
   #### How to reproduce the bug
   
   1. python3 -m venv venv
   2. . venv/bin/activate
   3. pip install apache-superset --use-feature=2020-resolver
   4. superset db upgrade
   
   ### Environment
   Python 3.9.5
   Flask 1.1.4
   Werkzeug 1.0.1
   (please complete the following information):
   
   - superset version:1.1.0
   - python version: 3.9.5
   - node.js version: v14.17.0
   
   ### Checklist
   
   Make sure to follow these steps before submitting your issue - thank you!
   
   - [ ] I have checked the superset logs for python stacktraces and included it here as text if there are any.
   - [ ] I have reproduced the issue with at least the latest released version of superset.
   - [ ] I have checked the issue tracker for the same issue and I haven't found one similar.
   
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] cortesjpb commented on issue #15035: Unable to upgrade superset database

Posted by GitBox <gi...@apache.org>.
cortesjpb commented on issue #15035:
URL: https://github.com/apache/superset/issues/15035#issuecomment-861449372


   Same error, any help?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] kkarski commented on issue #15035: Unable to upgrade superset database

Posted by GitBox <gi...@apache.org>.
kkarski commented on issue #15035:
URL: https://github.com/apache/superset/issues/15035#issuecomment-867266691


   I am having the same issue with 3.7.9.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] nazrulhadi commented on issue #15035: Unable to upgrade superset database

Posted by GitBox <gi...@apache.org>.
nazrulhadi commented on issue #15035:
URL: https://github.com/apache/superset/issues/15035#issuecomment-861988324


   hi @cortesjpb currently i test it in my local


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] kkarski edited a comment on issue #15035: Unable to upgrade superset database

Posted by GitBox <gi...@apache.org>.
kkarski edited a comment on issue #15035:
URL: https://github.com/apache/superset/issues/15035#issuecomment-867266691


   I am having the same issue with 3.7.9 on a mac.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] cortesjpb removed a comment on issue #15035: Unable to upgrade superset database

Posted by GitBox <gi...@apache.org>.
cortesjpb removed a comment on issue #15035:
URL: https://github.com/apache/superset/issues/15035#issuecomment-861449372


   Same error, any help?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] junlincc closed issue #15035: Unable to upgrade superset database

Posted by GitBox <gi...@apache.org>.
junlincc closed issue #15035:
URL: https://github.com/apache/superset/issues/15035


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] cortesjpb commented on issue #15035: Unable to upgrade superset database

Posted by GitBox <gi...@apache.org>.
cortesjpb commented on issue #15035:
URL: https://github.com/apache/superset/issues/15035#issuecomment-861528620


   Hello @nazrulhadi , after a lot of research I found out [this article](https://bugs.python.org/issue44061) explaining that this problem is present in Python version 3.9.5 and 3.8.10.
   
   I was trying to deploy Superset on Heroku and the supported Python runtime are those versions so the problem will persist.
   Using Python 3.7.10 runtime there is no issue.
   
   Let me know if you are using Heroku or if you are testing locally.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] doublear commented on issue #15035: Unable to upgrade superset database

Posted by GitBox <gi...@apache.org>.
doublear commented on issue #15035:
URL: https://github.com/apache/superset/issues/15035#issuecomment-891066917


   I am having this problem on Ubuntu. I dont know how to upgrade to Python 3.8.11 that supposed have this fix


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org