Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
Marcin Kolny
@loganek
but it'd be nice to have
especially after I release the viewer
Screen Shot 2018-10-19 at 3.00.10 PM.png
so the idea is that you can put any value from the event to the graph
Alexandru Ene
@AlexEne
wow
:)
nice
Marcin Kolny
@loganek
sorry for spoiler, if you go to GStreamer conference ;)
Alexandru Ene
@AlexEne
to be honest, it's because of you that I added the network listener and refactored it :D
the shame that the code was kinda hacky :)
Marcin Kolny
@loganek
because of me?
Alexandru Ene
@AlexEne
Because you said you will mention the rust bindings :)
Alexandru Ene
@AlexEne
Published 0.3 on crates io https://crates.io/crates/rust_hawktracer
Andrew Chambers
@andrewrch
Looks awesome 👌
Both the viewer and the crate 😉
Alexandru Ene
@AlexEne
:) Hey @loganek, so if I do a hawktracer-converter in python, what are the chances of it being accepted if I raise a PR?
we can still publish executable packages from it
Marcin Kolny
@loganek
We can, but why?
Writing converter in python is actually ~20 lines of code
Marcin Kolny
@loganek
And there might be a problem with distributing it - I’m not sure if it’s worth it as I’ll eventually merge viewer and converter (but still provide command line interface)
Marcin Kolny
@loganek
@AlexEne btw I've started writing HawkTracer parser in C, so after that I could make Rust bindings and we could re-write parser/viewer in Rust ;)
Marcin Kolny
@loganek
@AlexEne actually, I was wrong. It took me ~40 lines to write converter in python, and is not as complete as the one written in C++, but it works :) https://gist.github.com/loganek/a059af3a9dd4b9c7e51a9d15fae4954a
Moreover, in the official repository there's an example how to write your own client in python: https://github.com/loganek/hawktracer/blob/master/bindings/python3/plot-events.py
Alexandru Ene
@AlexEne
Having to build it for osx was the reason that made me think this might be easier to work with in python or even rust rather than in c. Another idea might be changing it to rust and offering bindings for C from it, since a rust build is basically cargo build and it magically works everywhere.
Alexandru Ene
@AlexEne
I mostly was thinking at porting client too so we can allow people to use it more easy, especially if they don't develop in c :), I thought that python is always available even in osx, but i might be wrong and maybe i should think a bit more about it.
Marcin Kolny
@loganek
I'd rather do other way around - writing a parser in C, and expose bindings in other languages
I guess even in rust you'll have linker problems if you do something wrong (so I did for osx)
but I'm definitile
Alexandru Ene
@AlexEne
Yeah, python was my first option to just remove this build step for it
I'll just research how brew install works and maybe we can publish binaries for it too. osx is a pain :)
Marcin Kolny
@loganek
*but I'm definitely open for Rust, but still learning it and figuring out what are the advantages over C. Maybe re-writing parser in Rust wouldn't be a bad idea, if we only could have bindings in C, and the integration with other languages was easy
Marcin Kolny
@loganek
@AlexEne I'm fixing osx runtime today, so the pain will go away
In general, as long as something is single executable, no matter what language we choose, it's fine for users
actually, if you build hawktracer with -DENABLE_STATIC_LIB=ON, converter should work out of the box
Alexandru Ene
@AlexEne
cool, thanks :)
Marcin Kolny
@loganek
image.png
Just setup some checks for PRs. No more broken builds!
Alexandru Ene
@AlexEne
Hello, @loganek do you have a file that works with the rust hawktracer-converter? I want to use it as an input in some tests since I plan on integrating some nice terminal UI for it using this: https://github.com/mitsuhiko/indicatif
What the 0.7 release generates doesn't work.
Marcin Kolny
@loganek

Hey @AlexEne, sorry for inconvenience. Rust converter is still under development, and is missing a lot of things (e.g. documentation, requirements etc.). Also, it's not really stable yet. In order to work with 0.7.0 version, converter must use the latest parser (hawktracer-parser repository). For now, you can modify Cargo.toml to use latest version the hawktracer-parser:

[dependencies]
-hawktracer-parser = "0.2.0"
+hawktracer-parser = { git = "https://github.com/loganek/hawktracer-parser" }

I'll try to create 0.3.0 version of hawktracer-parser crate today and update the converter repository so it uses latest crate, but for now, you can use the workaround above.

Alexandru Ene
@AlexEne
Ah, ok thanks
Alexandru Ene
@AlexEne
hawktracer_converter.gif
Now with smooth animations even in the console :)
Marcin Kolny
@loganek
Oo nice!
Waiting for PR!
Alexandru Ene
@AlexEne
I opened one for the waiting, soon I will finish this up and open another one.
Marcin Kolny
@loganek
Did you eventually manage to test the first PR ?
Alexandru Ene
@AlexEne
Yes
Forgot to comment
Marcin Kolny
@loganek
Hey @AlexEne is there anything that stops us from merging this branch: https://github.com/alexene/hawktracer-converter/tree/alexene/add-nice-progress-bars ?