Skip to content

Commit

Permalink
Fix error on observability page (skyportal#1971)
Browse files Browse the repository at this point in the history
* Fix error in ephemeris handler

* Update observability test to wait for plot
  • Loading branch information
kmshin1397 authored May 7, 2021
1 parent c65cdf2 commit b30e6ea
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion skyportal/handlers/api/internal/ephemeris.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ def get(self, telescope_id):
except TypeError:
return self.error(f'Invalid telescope id: {telescope_id}, must be integer.')

telescope = Telescope.query.get_if_accessible_by(
telescope = Telescope.get_if_accessible_by(
telescope_id, self.current_user, raise_if_none=True
)

Expand Down
2 changes: 2 additions & 0 deletions skyportal/tests/frontend/test_observability.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,5 @@ def test_fixed_location_filtering( # noqa: E302
driver.get(f'/observability/{public_source.id}')
driver.wait_for_xpath(f'//*[text()="{keck1_telescope.name}"]')
driver.wait_for_xpath_to_disappear(f'//*[text()="{hst.name}"]')
# Make sure a plot loads
driver.wait_for_xpath("//canvas")

0 comments on commit b30e6ea

Please sign in to comment.