Skip to content

feat: allow and require {{ stdlib("c") }} in recipes#1044

Closed
aliciaaevans wants to merge 3 commits intomasterfrom
lint-stdlib-c
Closed

feat: allow and require {{ stdlib("c") }} in recipes#1044
aliciaaevans wants to merge 3 commits intomasterfrom
lint-stdlib-c

Conversation

@aliciaaevans
Copy link
Copy Markdown
Contributor

@aliciaaevans aliciaaevans commented May 1, 2025

  • add stdlib function to JINJA_VARS to prevent the version_constraints_missing_whitespace lint error
  • add new lint to require stdlib function if compilers are used
  • update tests for the new lint (and to avoid tripping it when testing other lints)
  • Add {{ stdlib("c") }} to bioconductor-skeleton

See bioconda/bioconda-recipes#51185

From what I can tell, the JINJA_VARS part is used to allow for converting the recipe from string to yaml (which would reject the jinja vars as syntax errors) for various actions by bioconda-utils (such as linting) and not used in the actual build by conda-build. A thorough second look might be a good idea.

@aliciaaevans aliciaaevans requested review from bgruening and mbargull May 1, 2025 20:46
@aliciaaevans aliciaaevans marked this pull request as ready for review May 1, 2025 20:50
``requirements: build:`` section.
"""

def check_deps(self, deps):
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need a check for having stdlib but no compiler?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good question. It doesn't seem like conda-forge has that check. Although maybe someone might get confused and think they could use it in place of a compiler.

Copy link
Copy Markdown
Member

@bgruening bgruening left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just one small question.

@johanneskoester
Copy link
Copy Markdown
Contributor

@aliciaaevans there are some remaining conflicts. Can you fix them and then merge?

dlaehnemann added a commit to bioconda/bioconda-recipes that referenced this pull request Mar 31, 2026
Originally identified as an issue here: #51185

Similar workaround in:
d717ce6

Being resolved in:
bioconda/bioconda-utils#1044
@mbhall88
Copy link
Copy Markdown
Contributor

mbhall88 commented Apr 7, 2026

I have resolved these conflicts locally but can't push to this PR as I don't have the appropriate access rights. Should I open a separate PR or can someone upgrade my permissions?

See #1091

epruesse pushed a commit that referenced this pull request Apr 7, 2026
This supersedes #1044. It rebases the original work onto the latest
master and resolves conflicts in `bioconductor_skeleton.py` and the
linting test suite.

It should also maintain author info of previous work by @aliciaaevans.

I had left a comment on #1044 saying I didn't have access to push
directly to that PR and I also note that Alicia doesn't seem to have had
much github activity recently, so thought creating a new PR might be the
easiest route to getting this merged?

I have been hitting this lint bug (reported in
bioconda/bioconda-recipes#51185) a bit
recently.

Original PR text from #1044:

- add stdlib function to JINJA_VARS to prevent the version_constraints_missing_whitespace lint error
- add new lint to require stdlib function if compilers are used
- update tests for the new lint (and to avoid tripping it when testing other lints)
- Add {{ stdlib("c") }} to bioconductor-skeleton
See bioconda/bioconda-recipes#51185

From what I can tell, the JINJA_VARS part is used to allow for converting the recipe from string to yaml (which would reject the jinja vars as syntax errors) for various actions by bioconda-utils (such as linting) and not used in the actual build by conda-build. A thorough second look might be a good idea.

---------

Co-authored-by: Alicia A. Evans <108547992+aliciaaevans@users.noreply.github.com>
@aliciaaevans
Copy link
Copy Markdown
Contributor Author

Thanks, @mbhall88! I haven't had any time lately to keep up with Bioconda, so stepping in to help out is always appreciated.

@mbhall88
Copy link
Copy Markdown
Contributor

mbhall88 commented Apr 7, 2026

No problem I can totally relate. And thanks for the work on this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants