Add indexer.py under third-party/indexer/#717
Conversation
6c6371c to
9438859
Compare
|
First time handling third-party. Is this way we want? |
There was a problem hiding this comment.
First time handling third-party. Is this way we want?
Close. I would also add a README.md and a LICENSE file... which would be the full contents of https://github.com/joshbrunty/Indexer/. Here's an example third_party folder in another project: https://github.com/iree-org/iree/tree/main/third_party/nccl . Could also directly use a git submodule, if we don't need to carry local patches.
@stellaraccident may have other suggestions too. For context, we've been downloading this file then running it CI workflows to generate logs index pages:
TheRock/.github/workflows/build_linux_packages.yml
Lines 152 to 159 in 25516d0
I've been suggesting that we pull the file in directly and ideally fork it so it does exactly what we want: #648 (comment) . @marbre has also proposed a new implementation: #587 (comment)
Instead of forking
indexer.pyI propose to rather implement a solution based on boto3 which can then be used in an AWS Lambda.
I want to at least stop downloading something only in a CI workflow, so scripts work locally without extra setup. Refactoring/replacing can come later.
There was a problem hiding this comment.
Thanks for the info. Added as submodule.
There was a problem hiding this comment.
Does fetch_sources.py automatically pull that submodule down, or does it need an explicit git submodule update --init? I'm leaning towards forking the files instead of a submodule given that our other submodule deps are using by the source build, while this is an optional side script... could be convinced either way though. Regardless, the longer term solutions are to drop our dependency on this entirely. It's just 400 lines of Python and we will want to heavily change its behavior.
There was a problem hiding this comment.
I just checked fetch_sources.py did not fetch it. I can go for the fork option. Will add manually the code , license, and README.
There was a problem hiding this comment.
Adding the indexer from
https://raw.githubusercontent.com/joshbrunty/Indexer/6d8cbfd15d3853b482e6a49f2d875ded9188b721/indexer.pyunder third-party/indexer/ for TheRock project.
I would just say https://github.com/joshbrunty/Indexer/. That's a URL for humans, unlike the raw.githubusercontent.com URL. You can specify the commit hash also (joshbrunty/Indexer@6d8cbfd) if you want to be exact.
There was a problem hiding this comment.
Thanks. Made a few tweaks to the PR description myself.
0e323d7 to
a7d0b06
Compare
There was a problem hiding this comment.
Another option for this README file is to replace it with a link to the upstream https://github.com/joshbrunty/Indexer/. I don't feel too strongly either way.
# Indexer
This is a fork of https://github.com/joshbrunty/Indexer/, a Python script used to generate
an .html index of file within a selected directory.
## Local modifications
None yet.There was a problem hiding this comment.
I see. For me, either the same as well, I can keep it as is for now. If we want, I can update it.
|
Instead of forking Furthermore, I am not sure if |
Adding the indexer from https://github.com/joshbrunty/Indexer/ under
third-party/indexer/, sourced from commit joshbrunty/Indexer@6d8cbfd.