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

Jira Commit Hint plugin doesn't work #6154

Closed
IEVin opened this issue Jan 22, 2019 · 27 comments
Closed

Jira Commit Hint plugin doesn't work #6154

IEVin opened this issue Jan 22, 2019 · 27 comments

Comments

@IEVin
Copy link
Contributor

IEVin commented Jan 22, 2019

Current behaviour

Preview button in Jira commit hint plugin show dialog with error message.

Expected behaviour

Preview button in Jira commit hint plugin show dialog with available jira tasks.

Steps to reproduce

  1. Open Tools/Settings/Plugins/Jira Commit Hint;
  2. Configurate it and Press "Preview" button;
  3. Get error dialog.

For reproduce this problem without correct configuration would be enought add StringTemplate.Format("", null); in JiraCommitHintPlugin constructor and get TypeLoadException while plugin loading.

Screenshots

shot_190118_115728

Did this work in previous version of GitExtensions

Yes, it works correct on GE 3.00.00

Environment

  • Git Extensions 3.0.1.4933
  • Build a269358
  • Git 2.19.2.windows.1
  • Microsoft Windows NT 10.0.17134.0
  • .NET Framework 4.7.3260.0
  • DPI 96dpi (no scaling)

Diagnostics

Look like problem in wrong version of System.Collections.Immutable.dll.

@vbjay
Copy link
Contributor

vbjay commented Jan 22, 2019

Great. c7e4f51

@vbjay
Copy link
Contributor

vbjay commented Jan 22, 2019

Can you please open gitextensions.exe.config where you installed GE to and see if immutable is listed in the binding redirects and also find all .immutable.dll files and report on their version numbers.

@IEVin
Copy link
Contributor Author

IEVin commented Jan 22, 2019

GitExtensions.exe.config have no any definitions .immutable.dll files. Only System.Collections.Concurrent and System.Collections.

@vbjay
Copy link
Contributor

vbjay commented Jan 22, 2019

Search the folder for *.Immu*.dll Report on the versions of all files found, please.

@IEVin
Copy link
Contributor Author

IEVin commented Jan 22, 2019

I found 2 files in root and in Plugins folder.
In root folder:
ProductVersion : 4.6.26515.06 @BuiltBy: dlab-DDVSOWINAGE059 @Branch: release/2.1 @SrcCode: https://github.com/dotnet/corefx/tree/30ab651fcb4354552bd4891619a0 bdd81e0ebdbf

In 'Plugins' folder:
ProductVersion : 4.6.24816.01. Commit Hash: 4d1af962ca0fede10beb01d197367c2f90e92c97

@vbjay
Copy link
Contributor

vbjay commented Jan 22, 2019 via email

@vbjay
Copy link
Contributor

vbjay commented Jan 23, 2019

Ok. Found the issue. In master we used the composition reference in plugins library. That caused a binding redirect between Nstring use of an earlier version of immutable and composition. I added a package reference to the same package in the Jira plugin and it makes the project use the same version. I will ask that you test the build once I get the pull request done. Look forward to an update soon.

@RussKie
Copy link
Member

RussKie commented Feb 21, 2019

@vbjay is there a quick workaround/binding redirect users could apply to solve the issue?

@vbjay
Copy link
Contributor

vbjay commented Feb 21, 2019 via email

@vbjay
Copy link
Contributor

vbjay commented Feb 22, 2019

How I generated this output:

  1. Run these git commands
    • git clean -d -x -f
    • git submodule foreach git clean -d -x -f
  2. run setup\build
  3. Run provided linqpad script on the root folder where I have GE repo. Adjust as needed

These are the dlls excluding *resources.dll that have different hashes. The config file shows the current assembly binding redirects when built.
GE 3.02 DLL analyze report.zip

@PaulAdams-Conti
Copy link

FYI, I have downloaded the latest source and compiled but even though there is no exception any longer, the text pasted into the commit box is not correct:
image
and then when it is pasted:
image
The colon and space are missing and the commits are not linked in Jira.

@IEVin
Copy link
Contributor Author

IEVin commented Mar 7, 2019

FYI, I have downloaded the latest source and compiled but even though there is no exception any longer

This bug is only reproduced in the release/3.00 branch for me.

the text pasted into the commit box is not correct

The text template can be configured in the settings but it is not applied in the pop-up.

@PaulAdams-Conti
Copy link

Sorry for the confusion, my mistake. It had been working before so I assumed (wrongly) that I hadn't changed anything in the settings, but that was not the case. 🙄

@RussKie
Copy link
Member

RussKie commented Apr 16, 2019

Is this still a problem in the latest master?
https://ci.appveyor.com/project/gitextensions/gitextensions/branch/master/artifacts

@gerhardol
Copy link
Member

The portable works fine, have not tested the installer

@RussKie
Copy link
Member

RussKie commented Apr 16, 2019

Let's presume it is fixed, thank you.

@zroytman
Copy link

Hi, i'm using GitExtensions 3.1.1 and have a placeholder {CustomFields} in the Jira Hint Comment plugin definition. Using this placeholder as is returns me the message that this is a collection. How can i specify the custom field from this collection? The required custom field is "Application". Tried several ways like {CustomFields["Application"]}, {CustomFields("Application")}. {CustomFields.Application}, etc... getting error messages.
Please help.
Thanks.

@zroytman
Copy link

Hi, i'm using GitExtensions 3.1.1 and have a placeholder {CustomFields} in the Jira Hint Comment plugin definition. Using this placeholder as is returns me the message that this is a collection. How can i specify the custom field from this collection? The required custom field is "Application". Tried several ways like {CustomFields["Application"]}, {CustomFields("Application")}. {CustomFields.Application}, etc... getting error messages.
Please help.
Thanks.

H! Any updates? Thanks.

@IEVin
Copy link
Contributor Author

IEVin commented Jun 25, 2019

There is no way to get an array element now. GE using NString for parsing jira issue object but NString can only get fields and properties from top level object.
In fact fields like AffectsVersions, CustomFields, FixVersions, Labels is useless now.
This is an NString restriction.

@zroytman
Copy link

There is no way to get an array element now. GE using NString for parsing jira issue object but NString can only get fields and properties from top level object.
In fact fields like AffectsVersions, CustomFields, FixVersions, Labels is useless now.
This is an NString restriction.

Thanks for the explanation. Is this functionality presented in the GE roadmap? If so, any expectation of the implementation of it? Thanks.

@pmiossec
Copy link
Member

Is this functionality presented in the GE roadmap?

There is no roadmap other than a list of bug that we'd like to see fixed. See https://github.com/gitextensions/gitextensions/issues?q=is%3Aopen+is%3Aissue+milestone%3A3.2.0

But we live with contributions (we are all volunteers), so if you want to see something fixed or improved, please contribute.

@IEVin
Copy link
Contributor Author

IEVin commented Jun 25, 2019

Thanks for the explanation. Is this functionality presented in the GE roadmap? If so, any expectation of the implementation of it? Thanks.

I think no. You can add new issue about this. I think it's a good idea add issue in NString repository and just update it after implement this feature.

@RussKie
Copy link
Member

RussKie commented Jun 25, 2019 via email

@zroytman
Copy link

Thanks for the explanation. Is this functionality presented in the GE roadmap? If so, any expectation of the implementation of it? Thanks.

I think no. You can add new issue about this. I think it's a good idea add issue in NString repository and just update it after implement this feature.

Opened a new issue in NString repository:
thomaslevesque/NString#13 (comment)

@IEVin
Copy link
Contributor Author

IEVin commented Jun 25, 2019

Now GE just getting jira issue and put it in StringTemplate.Format(...) with user format without any aditional parsing (click).
Either add this feature in NString or implement formatter like NString itself.

@pmiossec
Copy link
Member

Opened a new issue in NString repository:

@zroytman I think that your issue title and description should be rewritten.
All the information you provided talk about GitExtensions which the developer of NString should not know of.
That don't help him understand what is the problem you want him to fix (I don't understand it neither).

Your text should be written in the point of view of the NString library perhaps with some source code examples.

@zroytman
Copy link

zroytman commented Jun 25, 2019

Opened a new issue in NString repository:

@zroytman I think that your issue title and description should be rewritten.
All the information you provided talk about GitExtensions which the developer of NString should not know of.
That don't help him understand what is the problem you want him to fix (I don't understand it neither).

Your text should be written in the point of view of the NString library perhaps with some source code examples.

As i don't understand what is the real problem (NString etc...), i just describe my issue. No source code examples to add... i just asked why cannot i use specific field from CustomFields placeholder in GE Jira Hint Comment plugin. You guys explained here that the reason is the limitations of NString and i opened a relevant case in NString repository. But i even don't know what is NString.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants