Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to view traces after the first one? #49

Closed
alexmojaki opened this issue Oct 12, 2020 · 5 comments
Closed

How to view traces after the first one? #49

alexmojaki opened this issue Oct 12, 2020 · 5 comments
Labels
documentation Improvements or additions to documentation

Comments

@alexmojaki
Copy link

I tried out the demo on Gitpod and followed the instructions. After viewing the first example I ran a different example but didn't know how to view the graph. Eventually I figured out that killing the first process with Ctrl+C made it possible to reinitialize Cyberbrain with a new example. Is this the best way? If so, consider adding it to the instructions.

@laike9m
Copy link
Owner

laike9m commented Oct 12, 2020

This is definitely something I need to improve. Right now the server listens on a hard-coded port, and UI talks to that port. If you have a better idea for how to make it work better, let me know. The only solution I can think of right now is to dump the mapping (port -> program being debugged) to a file, but I don't really like this approach since it brings in an extra outer dependency which is the file system.

@laike9m
Copy link
Owner

laike9m commented Oct 12, 2020

Actually, I think I can add a new API endpoint for discovering the currently running program. It should not be too hard. It's not that easy but I will think about it.

@alexmojaki
Copy link
Author

I don't know how the system works right now, but I imagine you could have multiple running programs all communicating with the UI so that the UI can show a selection of different running programs.

A completely different approach would be that running a traced program both immediately starts a server on a random port and opens the webbrowser in that port.

Either way, document the best available workaround in the docs for now while you come up with a solution. As I said, this stumped me for a bit when I tried the demo.

@laike9m
Copy link
Owner

laike9m commented Oct 12, 2020

OK will do 😂

@laike9m
Copy link
Owner

laike9m commented Oct 13, 2020

I closed this issue cause it's more related to documentation. Will have separate issue(s) for optimizing the use case.

@laike9m laike9m added the documentation Improvements or additions to documentation label Oct 13, 2020
laike9m added a commit that referenced this issue Oct 18, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

2 participants