Skip to content

feat: add environment variable support for mapping handlers#2901

Merged
stwiname merged 3 commits intosubquery:mainfrom
Gmin2:env-mapping
Sep 15, 2025
Merged

feat: add environment variable support for mapping handlers#2901
stwiname merged 3 commits intosubquery:mainfrom
Gmin2:env-mapping

Conversation

@Gmin2
Copy link
Copy Markdown
Contributor

@Gmin2 Gmin2 commented Sep 3, 2025

Description

Extends subql existing environment variable support from ts manifests to mapping handlers, allowing developers to access .env variables during indexing runtime.

Fixes #2471

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

Checklist

  • I have tested locally
  • I have performed a self review of my changes
  • [] Updated any relevant documentation
  • Linked to any relevant issues
  • I have added tests relevant to my changes
  • Any dependent changes have been merged and published in downstream modules
  • My code is up to date with the base branch
  • I have updated relevant changelogs. We suggest using chan

@Gmin2
Copy link
Copy Markdown
Contributor Author

Gmin2 commented Sep 3, 2025

cc @stwiname

Copy link
Copy Markdown
Collaborator

@stwiname stwiname left a comment

Choose a reason for hiding this comment

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

This looks really good, only a couple of minor changes. :D

Comment thread packages/cli/src/utils/env.spec.ts Outdated
Comment thread packages/cli/src/utils/env.ts Outdated
@Gmin2
Copy link
Copy Markdown
Contributor Author

Gmin2 commented Sep 4, 2025

done with the changes @stwiname

@Gmin2 Gmin2 requested a review from stwiname September 4, 2025 20:16
@stwiname stwiname merged commit 7e18488 into subquery:main Sep 15, 2025
2 of 3 checks passed
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.

[$300 in SQT] Support .env in mapping handlers

2 participants