-
Notifications
You must be signed in to change notification settings - Fork 5
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
Error while creating issue in Atlassian JIRA. The step is: Calculating fields #36
Comments
Hi! Are you running v0.2.14 of the app? It looks like some null reference exception bug(s) have been fixed in recent releases. Knowing the Seq version too might help, if that's not the cause. HTH! |
Yes sorry i am running version 0.2.14 of the app and version 2022.1.7378 of the Seq App. Thanks for the help. |
Hi! I just gave the function in question a quick scan; do you happen to have the "Project Key Property" setting configured? The code suggests that this is optional, but appears to use it in a (non-nullable) dictionary key lookup. Happy to help fix this however I can; I'm not currently using Jira so it's a little tricky to locate the problem. If we can't track it down by inspection like this, I'll have a shot at making the solution locally-runnable with |
Hello, Apologies on the delay, yes i do have "Project Key Property" configured. I am however still getting the error. Just to confirm, does this App support Jira cloud? Or just Jira Server? |
I am also having this same issue. My project key is also set. I do not have any other values that are marked as optional set to a value. |
Any thoughts on this? Was really hoping to implement this plugin |
I'll take a fresh look, thanks for the nudge 👍 |
Hi again @mrshorten 👋 Supporting Jira is important for us; unfortunately, I've dug into the project and at the moment, the plug-in needs quite a bit of maintenance/upgrading to get onto the modern .NET tooling (no criticism of @aliozgur's efforts intended - it's nice to have this project out there!). I'm up for spending some time migrating to the new-style CSPROJ projects, .NET 6.0 or 7.0 targets, etc., but it's not something I can turn around very quickly. I've had a look at the Jira REST API documentation and tinkered for a couple of hours, I think there's a workable alternative in Seq.App.HttpRequest, which is intended for exactly this kind of integration, but I've only made it as far as getting Unauthorized from the API: In case you have better luck than I've had, here's the kind of configuration I'm using. The authentication header is:
where the Convert.ToBase64String(Encoding.UTF8.GetBytes("[email protected]:<api_token>")) The body is a template (see checkbox below body text area):
You could untick the "body is a template" option and just use JSON in there, but Seq.App.HttpRequest has a pretty flexible JSON templating system that's worth trying out. Sorry this isn't a more complete/useful response. Looping back around here and spending some time helping to get the project updated is on my list :-) Hope this helps, |
@nblumhardt thanks for the starting point. I was able to create an issue on Jira but only with hard coded values. As sson as I try and use the template the App crashes and a syntax error is reported. I've tried a few different approaches as well as ChatGPT but no joy. Is the syntax meant to be this template language? ChatGPT keeps inisiting it should be something like the below. Both approaches are crashing the app for me.
|
Hi @sipsorcery - yes, that's the template language 👍 ChatGPT's suggestion might work with the "Body is template" field _un-_checked - that version is JSON, and won't be a valid template, hence the crash (I think). If you get that far, the Let me know if this helps! Best regards, |
I got the app to stop crashing with "Body is a template" checked using the Body below:
The resulting Jira task description is:
I think my issue isn't the actual template and is instead the fact that I'm using a grouping query for the Seq alert. I've having diffculty working out how to get any useful info into my templates, which rare Mialgun and Jira, for this type of query. However, that's not related to this issue so I probably should ask elsewhere? |
Awesome! The { {
'fields': {
'description': {
'content': [
{
'content': [
{
'text': concat('Triggered at: ', @t, '. Description: ', @m),
'type': 'text'
}
],
'type': 'paragraph'
}
],
'type': 'doc',
'version': 1
},
'project': {
'key': 'ITOPS'
},
'issuetype': {
'name': 'Task'
},
'summary': @m
}
} } |
System.NullReferenceException: Object reference not set to an instance of an object. at Seq.App.Jira.JiraIssueReactor.CreateIssue(Event
1 evt)at Seq.App.Jira.JiraIssueReactor.OnAsync(Event
1 evt)
Not sure what i am doing wrong. I have all required fields filled out.
The text was updated successfully, but these errors were encountered: