-
Notifications
You must be signed in to change notification settings - Fork 100
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Context access might be invalid: ACT #67
Comments
I'm also experiencing this issue. It makes no sense to me that this warning is being issued. Either the extension can validate all context or if it cannot do some then don't do any. Given that variables and secrets are viewable on the left I would imagine if can validate. |
Also having this issue. Is there a way to validate the context here? |
Fixed in next release: #61 (comment) |
Closing for fix in next release 💯 |
I can't see a commit which fixes this - even an unreleased one. Where did you see it was fixed? |
Still seeing this issue FYI |
I'm also still seeing this! |
definitely not fixed in the latest version. |
same here, the issue still persists in 0.25.8 |
I would love to have no yellow underline on my workflow files :) |
i'm almost disabling the extension... problem showing in v.0.25.8 here too :( |
I am disabling the extension for now. i'll check back in about 5 months 😞 |
@felipesu19 @cschleiden |
Have you tried declaring name: Demo workflow
env:
ACT:
on:
push:
workflow_dispatch:
inputs:
name:
type: string
jobs:
say-hello:
runs-on: ubuntu-latest
steps:
- run: echo "Hello ${{ env.ACT }}" |
I uninstalled, reinstalled and restarted VSCode and then the warnings went away. |
That didn't seem to work as expected. The "secrets" object is a simple dictionary of name / value pairs. Is it possible to add a config section for what we expect the object to look like ? Same with the env ? This way we don't need to erase the current value when its running to use an |
@epreston the |
No. The issue is being able to add custom values. It's good that it already has the values from the documentation. |
So unless we only use the prepopulated attributes on A way to add known values to the shape of these objects, like adding words to a spell checker, would resolve this issue. |
It uses the actual secrets configured for the repository, not just from the documentation. |
Possible issue with that feature. What's the best way for me to help ? How can I generate a reproduction ? |
One reproduction would be following the steps from https://app.codecov.io/ They have you create a:
Then when you go to edit that .yml file, it will always show this error where ![]() Other plugins, like the spell checker, allow us to add words to the workspace settings to resolve similar issues. |
I can confirm this works and is populated in github and that the plugin has no knowledge of the secrets configured for the repository. |
It would be a very impressive feature to have GH aware context. Just the keys mind you, values would not be good. |
@Zageron that is supported by the extension: |
@cschleiden what is required to allow the plugin to enumerate those secrets ? |
Nothing, just login and open the checked out repository in vscode. Edit: you need permissions to the repo, of course. |
Since those Azure ones are well known and might be populated by the plugin staticly, could you create a secret named Thank you kindly. |
@epreston I had to uninstall/reinstall the extension for the secret names autocomplete to start working. Also, fixed the yellow underlines. |
Any possible fix? |
This resolved the issue for me, can't believe I didn't try this first myself 😑 |
uninstall/reinstall only works temporarily, the issue still occurs if you're referencing organization secrets |
I think this issue need to be re-opened |
Just installed the extension (0.26.2) and immediately stumbled over this, which is not helpful. |
If I restart vscode, these warnings go away until I open a file under In my case the underlying cause seems to be a lack of alias support (#239). |
Describe the bug
I believe this is a quality of life issue rather than a bug.
It would be nice for there to be a documented way, perhaps a quick actions, to ignore certain warnings.
The issue is that
if: ${{ !env.ACT }}
warns that ACT might be invalid. Which it will be when not running in an environment that defines ACT. Not sure if warning that an environment variable might not be declared is useful.To Reproduce
Steps to reproduce the behavior:
Expected behavior
Either no warning, or a way to set particular environment variables to be ignored in this context.
Screenshots

Extension Version
v0.25.3
The text was updated successfully, but these errors were encountered: