itsmano opened a new issue #14963:
URL: https://github.com/apache/superset/issues/14963


   A clear and concise description of what the bug is.
   
   
   Getting the below error while upgrading the superset DB
   
     File "/usr/local/bin/superset", line 6, in <module>
       exec(compile(open(__file__).read(), __file__, 'exec'))
     File 
"/home/ubuntu/piperr_reports_git/superset_integrations/superset/bin/superset", 
line 21, in <module>
       cli()
     File "/usr/lib/python3/dist-packages/click/core.py", line 722, in __call__
       return self.main(*args, **kwargs)
     File "/usr/local/lib/python3.6/dist-packages/flask/cli.py", line 380, in 
main
       return AppGroup.main(self, *args, **kwargs)
     File "/usr/lib/python3/dist-packages/click/core.py", line 697, in main
       rv = self.invoke(ctx)
     File "/usr/lib/python3/dist-packages/click/core.py", line 1066, in invoke
       return _process_result(sub_ctx.command.invoke(sub_ctx))
     File "/usr/lib/python3/dist-packages/click/core.py", line 1066, in invoke
       return _process_result(sub_ctx.command.invoke(sub_ctx))
     File "/usr/lib/python3/dist-packages/click/core.py", line 895, in invoke
       return ctx.invoke(self.callback, **ctx.params)
     File "/usr/lib/python3/dist-packages/click/core.py", line 535, in invoke
       return callback(*args, **kwargs)
     File "/usr/lib/python3/dist-packages/click/decorators.py", line 17, in 
new_func
       return f(get_current_context(), *args, **kwargs)
     File "/usr/local/lib/python3.6/dist-packages/flask/cli.py", line 257, in 
decorator
       return __ctx.invoke(f, *args, **kwargs)
     File "/usr/lib/python3/dist-packages/click/core.py", line 535, in invoke
       return callback(*args, **kwargs)
     File "/usr/local/lib/python3.6/dist-packages/flask_migrate/cli.py", line 
134, in upgrade
       _upgrade(directory, revision, sql, tag, x_arg)
     File "/usr/local/lib/python3.6/dist-packages/flask_migrate/__init__.py", 
line 259, in upgrade
       command.upgrade(config, revision, sql=sql, tag=tag)
     File "/home/ubuntu/.local/lib/python3.6/site-packages/alembic/command.py", 
line 298, in upgrade
       script.run_env()
     File 
"/home/ubuntu/.local/lib/python3.6/site-packages/alembic/script/base.py", line 
489, in run_env
       util.load_python_file(self.dir, "env.py")
     File 
"/home/ubuntu/.local/lib/python3.6/site-packages/alembic/util/pyfiles.py", line 
98, in load_python_file
       module = load_module_py(module_id, path)
     File 
"/home/ubuntu/.local/lib/python3.6/site-packages/alembic/util/compat.py", line 
184, in load_module_py
       spec.loader.exec_module(module)
     File "<frozen importlib._bootstrap_external>", line 678, in exec_module
     File "<frozen importlib._bootstrap>", line 219, in 
_call_with_frames_removed
     File 
"/home/ubuntu/piperr_reports_git/superset_integrations/superset/migrations/env.py",
 line 103, in <module>
       run_migrations_online()
     File 
"/home/ubuntu/piperr_reports_git/superset_integrations/superset/migrations/env.py",
 line 96, in run_migrations_online
       context.run_migrations()
     File "<string>", line 8, in run_migrations
     File 
"/home/ubuntu/.local/lib/python3.6/site-packages/alembic/runtime/environment.py",
 line 846, in run_migrations
       self.get_context().run_migrations(**kw)
     File 
"/home/ubuntu/.local/lib/python3.6/site-packages/alembic/runtime/migration.py", 
line 522, in run_migrations
       step.migration_fn(**kw)
     File 
"/home/ubuntu/piperr_reports_git/superset_integrations/superset/migrations/versions/4451805bbaa1_remove_double_percents.py",
 line 82, in upgrade
       replace('%%', '%')
     File 
"/home/ubuntu/piperr_reports_git/superset_integrations/superset/migrations/versions/4451805bbaa1_remove_double_percents.py",
 line 53, in replace
       .join(Table)
     File 
"/home/ubuntu/.local/lib/python3.6/site-packages/sqlalchemy/orm/query.py", line 
2234, in join
       from_joinpoint=from_joinpoint,
     File "<string>", line 2, in _join
     File 
"/home/ubuntu/.local/lib/python3.6/site-packages/sqlalchemy/orm/base.py", line 
220, in generate
       fn(self, *args[1:], **kw)
     File 
"/home/ubuntu/.local/lib/python3.6/site-packages/sqlalchemy/orm/query.py", line 
2413, in _join
       left, right, onclause, prop, create_aliases, outerjoin, full
     File 
"/home/ubuntu/.local/lib/python3.6/site-packages/sqlalchemy/orm/query.py", line 
2436, in _join_left_to_right
       ) = self._join_determine_implicit_left_side(left, right, onclause)
     File 
"/home/ubuntu/.local/lib/python3.6/site-packages/sqlalchemy/orm/query.py", line 
2567, in _join_determine_implicit_left_side
       "Can't determine which FROM clause to join "
   sqlalchemy.exc.InvalidRequestError: Can't determine which FROM clause to 
join from, there are multiple FROMS which can join to this entity. Try adding 
an explicit ON clause to help resolve the ambiguity
   
   ### Environment
   
   (please complete the following information):
   
   - superset version: `0.999.0.dev0`
   - python version: `3.6`
   - node.js version: `v8.10.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.
   
   ### Additional context
   
   Add any other context about the problem here.
   


-- 
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:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to