Dataframe loading fails on Colab: 'localhost refused to connect'
bzz opened this issue Β· comments
π team, thanks for an awesome library.
Is it supposed to work on Collab? I'm having difficulties making a small demo.
Describe the bug
After mk.gui.start(api_port=2024, frontend_port=8010)
iframe fails to load on attempt to show the dataframe.
To Reproduce
Steps and code snippet that reproduce the behavior:
- Code snippet
import os
import io
import meerkat as mk
import numpy as np
import pandas as pd
samples = io.StringIO(r"""
{"X":"a","Y":"b","Z": 1}
""")
df = mk.from_json(samples, lines=True)
mk.gui.start(api_port=2024, frontend_port=8010)
df
- Instructions in this notebook
- Errors and traceback
Onlylocalhost refused to connect.
![Screenshot 2023-10-29 at 16 57 59](https://private-user-images.githubusercontent.com/5582506/278882251-770d963f-0c89-4ec1-bcc2-ba86036c0558.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTU4Njc4NjUsIm5iZiI6MTcxNTg2NzU2NSwicGF0aCI6Ii81NTgyNTA2LzI3ODg4MjI1MS03NzBkOTYzZi0wYzg5LTRlYzEtYmNjMi1iYTg2MDM2YzA1NTgucG5nP1gtQW16LUFsZ29yaXRobT1BV1M0LUhNQUMtU0hBMjU2JlgtQW16LUNyZWRlbnRpYWw9QUtJQVZDT0RZTFNBNTNQUUs0WkElMkYyMDI0MDUxNiUyRnVzLWVhc3QtMSUyRnMzJTJGYXdzNF9yZXF1ZXN0JlgtQW16LURhdGU9MjAyNDA1MTZUMTM1MjQ1WiZYLUFtei1FeHBpcmVzPTMwMCZYLUFtei1TaWduYXR1cmU9MzllMWQwMzE2YzUwMjVkODZmYzgzMWMwZDM3MmM3MzAzOWEwYjc2MjdkNTNmZjUyNGE0MTljYTg3MmU1ZmVhMyZYLUFtei1TaWduZWRIZWFkZXJzPWhvc3QmYWN0b3JfaWQ9MCZrZXlfaWQ9MCZyZXBvX2lkPTAifQ.zlmIuUq3uE7_pGgyTXdhXG0MTWNHHF81ngOFHIYSXrM)
But !curl 127.0.0.1:8010
returns the HTLM.
Changing the name in run_frontend
to 127.0.0.1
didn't change the outcome (127.0.0.1 refused to connect.
)
Expected behavior
See a dataframe table.
System Information
- Google Colab
Would appreciate any pointers for getting a demo up and running on Colab.
Thanks!