Open QO-Development opened 1 year ago
Hi @QO-Development,
the repository URL will be created internally based on the information you would provide in owner
and repository
properties. Here is the link to the source code where the concatenation happens:
In the GitHubSourceCodeProviderProps
documentation there is also the hint to use the name of the repository (and hence not the URL) . Here is the relevant information
Name | Type | Description |
---|---|---|
oauthToken🔹 | SecretValue | A personal access token with the repo scope. |
owner🔹 | string | The user or organization owning the repository. |
repository🔹 | string | The name of the repository. |
from the online documentation available here.
Hope this helps a bit.
Thanks for the reply @stefanfreitag, you're correct 🙂
@QO-Development Do you think it would be more clear if the examples specified something like <repoName>
instead of <repo>
like what's currently here?
Yes, that would be more clear, thank you. But I think the most confusing thing here is the error message, saying the repo URL is invalid. I suppose digging through the source code could have provided a better answer as well, but I think the most helpful thing to do would be to changes the error message. Something like:
GitHubSourceCodeProvider: Computed property repository URL is invalid. Please validate the constructor input props `owner` and `repository`.
The error message isn't something we have control over unfortunately. Since CloudFormation asks for a URL, it will provide a message about an invalid URL if the value provided is invalid. We could implement a validation check to make sure the repo provided is a valid repository name
Could you output the actual url being called as that would make it obvious what the issue is?
Describe the bug
I attempt to deploy a new Amplify app via CDK and a GitHubSourceCodeProvider. However, the cdk cli tool errors out and returns an error.
Expected Behavior
I expect the app to deploy properly.
Current Behavior
The error log looks like this:
Reproduction Steps
Possible Solution
This URL looks perfectly valid to me. I cannot find the proper URL format anywhere in any documentation, nor the error message.
Two possible solutions here:
Either way, I don't think I should have to guess at the correct string format.
Additional Information/Context
No response
CDK CLI Version
2.79.1
Framework Version
No response
Node.js Version
18.16.0
OS
Ventura 13.3.1
Language
Typescript
Language Version
No response
Other information
No response