TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Show HN: Sourcetrail – Visual Source Explorer Now Supports Python

89 pointsby egraetheralmost 6 years ago

11 comments

mmmrkalmost 6 years ago
Looks very interesting, but seems to be excruciatingly slow at indexing Python projects. Ran it on <a href="https:&#x2F;&#x2F;github.com&#x2F;fonttools&#x2F;fonttools&#x2F;tree&#x2F;master&#x2F;Lib&#x2F;fontTools" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;fonttools&#x2F;fonttools&#x2F;tree&#x2F;master&#x2F;Lib&#x2F;fontT...</a> (~230 files) and it took 45 minutes while keeping all 16 cores of my Ryzen 1700 at full load, sometimes using ~16 GB of RAM. Exiting the application ends in a SEGV, but seemingly without consequences? Also, after moving the database files to a different folder and renaming the &quot;source group&quot;, it now asks me run re-index everything. AAAARRRGHHH.
评论 #20014403 未加载
omeid2almost 6 years ago
Absolutely amazing product! wish it supported more languages though.<p>Other than being a great and useful product, their Global Pricing is based on big-mac index is fantastic. To put this in perspective, the &quot;standard&quot; price of 744.47$ is twice the median wage in Afghanistan.
评论 #20009076 未加载
victor106almost 6 years ago
Never knew a product like this existed. This is a godsend for me as I navigate lot of old codebases.
albertzeyeralmost 6 years ago
I usually use PyCharm in a very similar manner, to browse others code locally. This is much more efficient compared to e.g. browsing&#x2F;reading the code on GitHub. Whenever I spend more than a few minutes browsing some code on GitHub, I just clone the repo instead and open it in PyCharm. Finding some usages of some function, or simple searching for some string or so is much faster and more comfortable (also because the search on GitHub is so limited). I can only recommend this workflow to anyone who reads others source code. And reading others source code is anyway also something I would recommend everyone.<p>About Sourcetrail, I see from the homepage that it also has some additional graphical representation. Is this more helpful over what PyCharm already offers?<p>If so, maybe this also can be a feature request to PyCharm.
评论 #20012250 未加载
tmikaeldalmost 6 years ago
There exists one for Javascript as well:<p><a href="https:&#x2F;&#x2F;github.com&#x2F;Bogdan-Lyashenko&#x2F;js-code-to-svg-flowchart" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;Bogdan-Lyashenko&#x2F;js-code-to-svg-flowchart</a><p>Including a VSCode extension (but it seems unmaintained):<p><a href="https:&#x2F;&#x2F;marketplace.visualstudio.com&#x2F;items?itemName=lucasbadico.code-flowchart" rel="nofollow">https:&#x2F;&#x2F;marketplace.visualstudio.com&#x2F;items?itemName=lucasbad...</a>
评论 #20007717 未加载
nebucnautalmost 6 years ago
Here is the release post that describes the Python integration a bit more detailed: <a href="https:&#x2F;&#x2F;www.sourcetrail.com&#x2F;blog&#x2F;sourcetrail_supports_python&#x2F;" rel="nofollow">https:&#x2F;&#x2F;www.sourcetrail.com&#x2F;blog&#x2F;sourcetrail_supports_python...</a>
dimmuborgiralmost 6 years ago
How does this compare to Code Maps in Visual Studio? Can anyone who has used both comment?
评论 #20008620 未加载
devbat8712almost 6 years ago
Oh my god, I&#x27;ve been looking for something like this for like a full year. This is awesome.
argd678almost 6 years ago
What frameworks did you use to create the UI?
topazasalmost 6 years ago
Awesome! Will try without a doubt.
Asookaalmost 6 years ago
I tried the demo back when this was still called Coati. Very impressive, but not quite suitable for my current job. I didn&#x27;t have time to fully evaluate it at the time, but these are my impressions from trying to use it on our codebase (I can&#x27;t say exactly who we are due to NDAs).<p>My first criticism would be that the UI wastes a lot of space with all the curves and thick borders. Might be due to me using Vim most of the time, but I&#x27;m used to a higher text density. It also felt sluggish, but this might have been improved in the meantime, and also I used it on Linux which is notoriously bad for graphical responsiveness.<p>Second, the indexing was kind of slow. Our codebase is very far from the size of Chrome&#x27;s, but it is a big commercial C++ project - something like 2M sloc (with comments). This was compounded by the fact that switching branches often led to nearly rebuilding a lot of files due to changes in often-used headers.<p>Third, it can only index one build configuration. Our single source tree is used to build several products and indexing only one build configuration is helpful, but often I need to know if changes necessary for product A will impact product B. It would be really nice if the indexing was split off into its own daemon and I could e.g. have three daemons looking over three build configurations on Linux, an additional remote daemon indexing the MacOS source, and further two running on a Windows host (possibly a VM). This might sound extreme and convoluted, but the kind of large C++ project where Sourcetrail would shine is the kind that has its own very opinionated idiosyncrasies.<p>Finally, it doesn&#x27;t actually solve my most frequent use-case. Sourcetrail is great for browsing and understanding OOP structure of code. However, I am most often interested in exploring dataflow. I really want to know where a particular member of a struct is set, where the values in the expression come from, where those values are set, where the values in those expressions are from, etc. This can be accomplished with pretty much the same hierarchical interface that Sourcetrail currently has, but instead of classes and methods, the basic units should be expressions and values. Another useful feature would be &quot;where is this value used&quot; - say you have a member of a struct, or a method returning a constant value, and you want to know where the value of the member is used. Not where the member is used, because the value of the member is often copied around, but without being modified. I would really like something that can track through assignments to tell me where this value ends up. Right now Sourcetrail doesn&#x27;t really cover this usecase better than Vim+ctags+rtags+ripgrep. Yes, this sounds a bit like &quot;Dropbox is just sftp+rsync&quot;, but I couldn&#x27;t make Coati work better for my usecase than my current setup.<p>I can&#x27;t demand that dataflow analysis be implemented, because I can&#x27;t promise that I&#x27;ll use Sourcetrail even if it is, but a data-oriented view of code might be a worthwhile development to consider.
评论 #20008073 未加载
评论 #20008003 未加载