Skip to content
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

[Bug]: ALLOWED_ENV_SUBSTITUTIONS cannot be empty #303

Closed
emil-wire opened this issue Jan 11, 2024 · 5 comments · Fixed by #304
Closed

[Bug]: ALLOWED_ENV_SUBSTITUTIONS cannot be empty #303

emil-wire opened this issue Jan 11, 2024 · 5 comments · Fixed by #304
Assignees
Labels
bug Something isn't working

Comments

@emil-wire
Copy link
Contributor

Expected Behavior

If I leave it empty, I expect the application to continue and not operate on an empty string

Actual Behavior

The following error message appears when I leave the variable empty:

{
  "timestamp": "2024-01-10T17:15:46.142038583Z",
  "sequence": 57,
  "loggerClassName": "org.jboss.logging.Logger",
  "loggerName": "io.quarkiverse.githubapp",
  "level": "ERROR",
  "message": "Error handling delivery e3cbf188-afdb-11ee-9961-07c7a1592f55\n› Repository: emil-wire/wire-webapp\n› Event:      push\n› Context:    refs/heads/dev\n› Redeliver:  https://github.com/settings/apps/Technolinator/advanced\nException",
  "threadName": "executor-thread-2",
  "threadId": 52,
  "mdc": {
    "ref": "refs/heads/dev",
    "commitSha": "a708b4fe7a1c23155fa118976a4effec779f3169",
    "repository": "emil-wire/wire-webapp",
    "traceId": "6fe245ae"
  },
  "ndc": "",
  "hostName": "82cac32cb8d6",
  "processName": "quarkus-run.jar",
  "processId": 1,
  "exception": {
    "refId": 1,
    "exceptionType": "java.util.NoSuchElementException",
    "message": "SRCFG00040: The config property app.allowed_env_substitutions is defined as the empty String (\"\") which the following Converter considered to be null: io.smallrye.config.Converters$BuiltInConverter",
    "frames": [
      {
        "class": "io.smallrye.config.SmallRyeConfig",
        "method": "convertValue",
        "line": 298
      },
      {
        "class": "io.smallrye.config.SmallRyeConfig",
        "method": "getValue",
        "line": 241
      },
      {
        "class": "io.smallrye.config.SmallRyeConfig",
        "method": "getValue",
        "line": 167
      },
      {
        "class": "com.mediamarktsaturn.technolinator.sbom.CdxgenClient",
        "method": "<init>",
        "line": 98
      },
      {
        "class": "com.mediamarktsaturn.technolinator.sbom.CdxgenClient_ClientProxy",
        "method": "<init>"
      },
      {
        "class": "com.mediamarktsaturn.technolinator.sbom.CdxgenClient_Bean",
        "method": "proxy"
      },
      {
        "class": "com.mediamarktsaturn.technolinator.sbom.CdxgenClient_Bean",
        "method": "get"
      },
      {
        "class": "com.mediamarktsaturn.technolinator.sbom.CdxgenClient_Bean",
        "method": "get"
      },
      {
        "class": "com.mediamarktsaturn.technolinator.handler.PushHandler_Bean",
        "method": "doCreate"
      },
      {
        "class": "com.mediamarktsaturn.technolinator.handler.PushHandler_Bean",
        "method": "create"
      },
      {
        "class": "com.mediamarktsaturn.technolinator.handler.PushHandler_Bean",
        "method": "create"
      },
      {
        "class": "io.quarkus.arc.impl.AbstractSharedContext",
        "method": "createInstanceHandle",
        "line": 117
      },
      {
        "class": "io.quarkus.arc.impl.AbstractSharedContext$1",
        "method": "get",
        "line": 41
      },
      {
        "class": "io.quarkus.arc.impl.AbstractSharedContext$1",
        "method": "get",
        "line": 38
      },
      {
        "class": "io.quarkus.arc.generator.Default_jakarta_enterprise_context_ApplicationScoped_ContextInstances",
        "method": "c12"
      },
      {
        "class": "io.quarkus.arc.generator.Default_jakarta_enterprise_context_ApplicationScoped_ContextInstances",
        "method": "computeIfAbsent"
      },
      {
        "class": "io.quarkus.arc.impl.AbstractSharedContext",
        "method": "get",
        "line": 38
      },
      {
        "class": "io.quarkus.arc.impl.ClientProxies",
        "method": "getApplicationScopedDelegate",
        "line": 21
      },
      {
        "class": "com.mediamarktsaturn.technolinator.handler.PushHandler_ClientProxy",
        "method": "arc$delegate"
      },
      {
        "class": "com.mediamarktsaturn.technolinator.handler.PushHandler_ClientProxy",
        "method": "onPush"
      },
      {
        "class": "com.mediamarktsaturn.technolinator.events.OnPushDispatcher",
        "method": "onPush",
        "line": 85
      },
      {
        "class": "com.mediamarktsaturn.technolinator.events.OnPushDispatcher_Multiplexer",
        "method": "onPush_d7e94306c790daa532e25db38c91382b4575d8e4"
      },
      {
        "class": "com.mediamarktsaturn.technolinator.events.OnPushDispatcher_Multiplexer_Observer_onPush_d7e94306c790daa532e25db38c91382b4575d8e4_74Bomtm3kXNgtGnbpcULVw6cRgk",
        "method": "notify"
      },
      {
        "class": "io.quarkus.arc.impl.EventImpl$Notifier",
        "method": "notifyObservers",
        "line": 346
      },
      {
        "class": "io.quarkus.arc.impl.EventImpl$Notifier",
        "method": "notify",
        "line": 328
      },
      {
        "class": "io.quarkus.arc.impl.EventImpl$1",
        "method": "get",
        "line": 112
      },
      {
        "class": "java.util.concurrent.CompletableFuture$AsyncSupply",
        "method": "run",
        "line": 1768
      },
      {
        "class": "io.quarkus.vertx.core.runtime.VertxCoreRecorder$14",
        "method": "runWith",
        "line": 582
      },
      {
        "class": "org.jboss.threads.EnhancedQueueExecutor$Task",
        "method": "run",
        "line": 2513
      },
      {
        "class": "org.jboss.threads.EnhancedQueueExecutor$ThreadBody",
        "method": "run",
        "line": 1538
      },
      {
        "class": "org.jboss.threads.DelegatingRunnable",
        "method": "run",
        "line": 29
      },
      {
        "class": "org.jboss.threads.ThreadLocalResettingRunnable",
        "method": "run",
        "line": 29
      },
      {
        "class": "io.netty.util.concurrent.FastThreadLocalRunnable",
        "method": "run",
        "line": 30
      },
      {
        "class": "java.lang.Thread",
        "method": "run",
        "line": 1583
      }
    ]
  }
}

also, could you tell me what the meaning of "https://github.com/settings/apps/Technolinator" in the error message is?

Steps to Reproduce

No response

Additional Information

No response

@emil-wire emil-wire added the bug Something isn't working label Jan 11, 2024
beiertu-mms added a commit that referenced this issue Jan 11, 2024
SmallRyeConfig getValue doesn't allow the provided configured value to
be empty, therefore use getOptionalValue instead.

See also: eclipse/microprofile-config#407

Fixes #303
@beiertu-mms
Copy link
Contributor

could you tell me what the meaning of "github.com/settings/apps/Technolinator" in the error message is?

I assume that's where you can find the settings for this app.
@heubeck please correct this statement if it's wrong.

beiertu-mms added a commit that referenced this issue Jan 11, 2024
SmallRyeConfig getValue doesn't allow the provided configured value to
be empty, therefore use getOptionalValue instead.

See also: eclipse/microprofile-config#407

Fixes #303
@heubeck
Copy link
Member

heubeck commented Jan 11, 2024

Thx @beiertu-mms for the quick fix 💟

could you tell me what the meaning of "github.com/settings/apps/Technolinator" in the error message is?

have you installed the app with name "Technolinator" in your personal profile, @emil-wire?
would guess that's logging the github installation location, what's github.com/settings for your personal account.

beiertu-mms added a commit that referenced this issue Jan 11, 2024
SmallRyeConfig `getValue` doesn't allow the provided configured value to
be empty, therefore use `getOptionalValue` instead.

See also: eclipse/microprofile-config#407

Fixes #303
@beiertu-mms beiertu-mms reopened this Jan 11, 2024
@emil-wire
Copy link
Contributor Author

@heubeck wow, you guys are quick :) Thanks!
I followed your readme and set up the github app, but not under that name. Just checked, and the URL for my github app is very different

@heubeck
Copy link
Member

heubeck commented Jan 11, 2024

@heubeck wow, you guys are quick :) Thanks! I followed your readme and set up the github app, but not under that name. Just checked, and the URL for my github app is very different

interesting. will look out for that.
can you please test with version 1.49.4 that's now available, @emil-wire ?

@emil-wire
Copy link
Contributor Author

@heubeck 1.49.4 fixed it :) thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Development

Successfully merging a pull request may close this issue.

4 participants