sphinx-needs icon indicating copy to clipboard operation
sphinx-needs copied to clipboard

Hardcoded build path in esbonio.py file

Open MohSam1 opened this issue 2 years ago • 3 comments

I have a different out directory name (eg: _out), so the json is generated at _out/needs/needs.json, but in the below file https://github.com/useblocks/sphinxcontrib-needs/blob/master/sphinx_needs/lsp/esbonio.py

The build directory is hard coded to start with _build, this causes the extension fail continuously with below error.

raise FileNotFoundError(f"JSON file not found: {​​json_file}​​")

Can you please check if this is an issue ?

LOC - 89

needs_json = confdir / "_build/needs/needs.json"

MohSam1 avatar Jul 06 '22 17:07 MohSam1

Hi @MohSam1,

Thanks for reporting this.

Yes, currently the needs.json path is hard coded by default there. It doesn't check the config of esbonio.sphinx.buildDir yet. I am on it now.

haiyangToAI avatar Jul 07 '22 07:07 haiyangToAI

@haiyangToAI Is this done with #637? If yes I think there are no docs for this feature.

danwos avatar Jul 11 '22 15:07 danwos

Hi @danwos,

yes, this issue is fixed.

In the docs I just mentioned in the usage section: https://github.com/useblocks/sphinx-needs/blob/master/docs/ide/index.rst#usage.

I didn't thought this as a feature. I think it makes sense to update it to the docs.

haiyangToAI avatar Jul 12 '22 07:07 haiyangToAI