Repository navigation
Bug ReportI'm trying to migrate some custom FastAPI code over to the new perspective Starlette backend, but am not seeing any data updates or any evidence of the tables in a simple html frontend. Steps to Reproduce:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Title</title>
<script src="https://cdn.jsdelivr.net/npm/@finos/perspective"></script>
<script src="https://cdn.jsdelivr.net/npm/@finos/perspective-viewer"></script>
<script src="https://cdn.jsdelivr.net/npm/@finos/perspective-viewer-datagrid"></script>
<script src="https://cdn.jsdelivr.net/npm/@finos/perspective-viewer-d3fc"></script>
</head>
<body>
<script>
window.addEventListener("DOMContentLoaded", async function () {
const websocket = perspective.websocket("ws://localhost:8080/websocket");
const table = await websocket.open_table("data_source_one");
const viewer = document.getElementById("viewer");
await viewer.load(table);
});
</script>
<perspective-viewer id="viewer"></perspective-viewer>
</body>
</html>Expected Result:Can see datagrid with data in browser Actual Result:Empty datagrid without any schema, no exceptions. Environment:Backend
Frontend:
Additional Context:I can see the websocket connection being established, and data in the backend. The frontend js code connects to the socket and seemingly loads the table, but the viewer does not update. |
Answered by
timkpaine
Aug 27, 2022
Replies: 1 comment 1 reply
|
I don't see any issues on latest release other than that the and I see everything working as normal. do you see the same? |
1 reply
Answer selected by
limx0
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment

I don't see any issues on latest release other than that the
perspective-viewerelement is 0 sized. modifying yourindex.htmlto match the examples in the examples folder:and I see everything working as normal. do you see the same?