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

Unable to retrieve CreateMetadata #335

Open
c4uran opened this issue Jan 29, 2019 · 13 comments
Open

Unable to retrieve CreateMetadata #335

c4uran opened this issue Jan 29, 2019 · 13 comments

Comments

@c4uran
Copy link

c4uran commented Jan 29, 2019

Hi,

I got the error below when i try to use this

Get-JiraIssueCreateMetadata -Project 11601 -IssueType 3

Do you have any idea ?

PS C:\Windows\system32> Get-JiraIssueCreateMetadata -Project 11601 -IssueType '3'

Get-Member : You must specify an object for the Get-Member cmdlet.
At C:\Program Files\WindowsPowerShell\Modules\PSJira\1.2.5.251\Internal\ConvertTo-JiraCreateMetaField.ps1:37 char:32
+ ... eldNames = (Get-Member -InputObject $fields -MemberType '*Property'). ...

The Project exist:

PS C:\Windows\system32> Get-JiraProject 11601 
ID          : 11601

isue exist too:

PS C:\Windows\system32> Get-JiraIssueType -IssueType 3
ID          : 3
Name        : Task

Debug:

PS C:\Windows\system32> Get-JiraIssueCreateMetadata -Project 11601 -IssueType '3' -Debug
DEBUG: [Get-JiraIssueCreateMetadata] Reading server from config file
DEBUG: [Get-JiraIssueCreateMetadata] Building URI for REST call based on parameters
DEBUG: [Get-JiraIssueCreateMetadata] Obtaining project ID for project [11601]
DEBUG: [Get-JiraProject] Reading server from config file
DEBUG: [Get-JiraProject] Processing project [11601]
DEBUG: [Get-JiraProject] Preparing for blastoff!
DEBUG: [Invoke-JiraMethod] Credentials were not provided. Checking for a saved session
DEBUG: [Get-JiraSession] Module private data exists
DEBUG: [Get-JiraSession] A Session object is saved; outputting
DEBUG: [Invoke-JiraMethod] A session was found; using saved session (Username=[itam], JSessionID=[6279E0B60207193686239F044BD91DB1])
DEBUG: [Invoke-JiraMethod] Invoking JIRA method Get to URI http://172.21.13.54:8080/rest/api/latest/project/11601?expand=projectKeys
DEBUG: [Invoke-JiraMethod] Status code: 200
DEBUG: [Invoke-JiraMethod] Converting body of response from JSON
DEBUG: [Invoke-JiraMethod] Outputting results from JIRA
DEBUG: [Get-JiraProject] Converting to object
DEBUG: [Get-JiraProject] Outputting result
DEBUG: Complete
DEBUG: [Get-JiraIssueCreateMetadata] Obtaining issue type ID for issue type [3]
DEBUG: [Get-JiraIssueType] Reading server from config file
DEBUG: [Get-JiraIssueType] Obtaining all issue types from Jira
DEBUG: [Invoke-JiraMethod] Credentials were not provided. Checking for a saved session
DEBUG: [Get-JiraSession] Module private data exists
DEBUG: [Get-JiraSession] A Session object is saved; outputting
DEBUG: [Invoke-JiraMethod] A session was found; using saved session (Username=[itam], JSessionID=[6279E0B60207193686239F044BD91DB1])
DEBUG: [Invoke-JiraMethod] Invoking JIRA method Get to URI http://172.21.13.54:8080/rest/api/latest/issuetype
DEBUG: [Invoke-JiraMethod] Status code: 200
DEBUG: [Invoke-JiraMethod] Converting body of response from JSON
DEBUG: [Invoke-JiraMethod] Outputting results from JIRA
DEBUG: [ConvertTo-JiraIssueType] Complete
DEBUG: [Get-JiraIssueType] Processing issue type [3]
DEBUG: [Get-JiraIssueType] Searching for issue type (name=[3])
DEBUG: [Get-JiraIssueType] No results were found for issue type by name. Searching for issue type (id=[3])
DEBUG: [Get-JiraIssueType] Found results; outputting
DEBUG: Complete
DEBUG: [Get-JiraIssueCreateMetadata] Preparing for blastoff!
DEBUG: [Invoke-JiraMethod] Credentials were not provided. Checking for a saved session
DEBUG: [Get-JiraSession] Module private data exists
DEBUG: [Get-JiraSession] A Session object is saved; outputting
DEBUG: [Invoke-JiraMethod] A session was found; using saved session (Username=[itam], JSessionID=[6279E0B60207193686239F044BD91DB1])
DEBUG: [Invoke-JiraMethod] Invoking JIRA method Get to URI http://172.21.13.54:8080/rest/api/latest/issue/createmeta?projectIds=11601&issuetypeIds=3&expand=projects.issuetypes.fields
DEBUG: [Invoke-JiraMethod] Status code: 200
DEBUG: [Invoke-JiraMethod] Converting body of response from JSON
DEBUG: [Invoke-JiraMethod] Outputting results from JIRA
DEBUG: [Get-JiraIssueCreateMetadata] Identified project key: [11601]
DEBUG: [Get-JiraIssueCreateMetadata] Converting results to custom object
DEBUG: [ConvertTo-JiraCreateMetaField] Processing object: '@{expand=projects; projects=}'
Get-Member : You must specify an object for the Get-Member cmdlet.
At C:\Program Files\WindowsPowerShell\Modules\PSJira\1.2.5.251\Internal\ConvertTo-JiraCreateMetaField.ps1:37 char:32
+ ... eldNames = (Get-Member -InputObject $fields -MemberType '*Property'). ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : CloseError: (:) [Get-Member], InvalidOperationException
    + FullyQualifiedErrorId : NoObjectInGetMember,Microsoft.PowerShell.Commands.GetMemberCommand
 
DEBUG: Outputting results

Please help...

@c4uran
Copy link
Author

c4uran commented Jan 29, 2019

Debug on 2.9.0 JiraPs module:

Get-JiraIssueCreateMetadata -Project 11601 -IssueType '3' -Debug

DEBUG: [Get-JiraConfigServer] ParameterSetName: __AllParameterSets
DEBUG: [Get-JiraConfigServer] PSBoundParameters: 
Key         Value
---         -----
ErrorAction  Stop



DEBUG: [Get-JiraIssueCreateMetadata] ParameterSetName: __AllParameterSets
DEBUG: [Get-JiraIssueCreateMetadata] PSBoundParameters: 
Key       Value
---       -----
Project   11601
IssueType 3    
Debug     True 



DEBUG: [Get-JiraConfigServer] ParameterSetName: __AllParameterSets
DEBUG: [Get-JiraConfigServer] PSBoundParameters: 
Key         Value
---         -----
ErrorAction  Stop



DEBUG: [Get-JiraProject] ParameterSetName: _Search
DEBUG: [Get-JiraProject] PSBoundParameters: 
Key         Value                                    
---         -----                                    
Project     {11601}                                  
Credential  System.Management.Automation.PSCredential
ErrorAction Stop                                     



DEBUG: [Get-JiraProject] Processing $_project [11601]
DEBUG: [Get-JiraProject] Invoking JiraMethod with $parameter
DEBUG: [Invoke-JiraMethod] ParameterSetName: __AllParameterSets
DEBUG: [Invoke-JiraMethod] PSBoundParameters: 
Key        Value                                                                                                    
---        -----                                                                                                    
Credential System.Management.Automation.PSCredential                                                                
Method     Get                                                                                                      
URI        http://172.21.13.54:8080/rest/api/latest/project/11601?expand=description,lead,issueTypes,url,projectKeys



DEBUG: [Get-JiraSession] ParameterSetName: __AllParameterSets
DEBUG: [Get-JiraSession] PSBoundParameters: 
Key                    Value
---                    -----
ErrorAction SilentlyContinue



DEBUG: [Invoke-JiraMethod] Invoke-WebRequest with $splatParameters: 
Name                           Value                                                                                           
----                           -----                                                                                           
ErrorAction                    Stop                                                                                            
Headers                        {Accept-Charset, Accept}                                                                        
ContentType                    application/json; charset=utf-8                                                                 
Method                         Get                                                                                             
WebSession                     Microsoft.PowerShell.Commands.WebRequestSession                                                 
Uri                            http://172.21.13.54:8080/rest/api/latest/project/11601?expand=description,lead,issueTypes,url...
UseBasicParsing                True                                                                                            
Verbose                        False                                                                                           



DEBUG: [Invoke-JiraMethod] Executed WebRequest. Access $webResponse to see details
DEBUG: [Test-ServerResponse] Investigating $InputObject.Headers['X-Seraph-LoginReason']
DEBUG: 
public class JsonObjectTypeResolver : System.Web.Script.Serialization.JavaScriptTypeResolver
{
	public override System.Type ResolveType(string id)
	{
		return typeof (System.Collections.Generic.Dictionary<string, object>);
	}

	public override string ResolveTypeId(System.Type type)
	{
		return string.Empty;
	}
}
DEBUG: [ConvertTo-JiraProject] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraUser] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [Get-JiraConfigServer] ParameterSetName: __AllParameterSets
DEBUG: [Get-JiraConfigServer] PSBoundParameters: 
Key         Value
---         -----
ErrorAction  Stop



DEBUG: [Get-JiraIssueType] ParameterSetName: _Search
DEBUG: [Get-JiraIssueType] PSBoundParameters: 
Key         Value                                    
---         -----                                    
IssueType   {3}                                      
Credential  System.Management.Automation.PSCredential
ErrorAction Stop                                     



DEBUG: [Get-JiraIssueType] Processing $_issueType [3]
DEBUG: [Get-JiraConfigServer] ParameterSetName: __AllParameterSets
DEBUG: [Get-JiraConfigServer] PSBoundParameters: 
Key         Value
---         -----
ErrorAction  Stop



DEBUG: [Get-JiraIssueType] ParameterSetName: _All
DEBUG: [Get-JiraIssueType] PSBoundParameters: 
Key        Value                                    
---        -----                                    
Credential System.Management.Automation.PSCredential



DEBUG: [Get-JiraIssueType] Invoking JiraMethod with $parameter
DEBUG: [Invoke-JiraMethod] ParameterSetName: __AllParameterSets
DEBUG: [Invoke-JiraMethod] PSBoundParameters: 
Key        Value                                             
---        -----                                             
Credential System.Management.Automation.PSCredential         
Method     Get                                               
URI        http://172.21.13.54:8080/rest/api/latest/issuetype



DEBUG: [Get-JiraSession] ParameterSetName: __AllParameterSets
DEBUG: [Get-JiraSession] PSBoundParameters: 
Key                    Value
---                    -----
ErrorAction SilentlyContinue



DEBUG: [Invoke-JiraMethod] Invoke-WebRequest with $splatParameters: 
Name                           Value                                                                                           
----                           -----                                                                                           
ErrorAction                    Stop                                                                                            
Headers                        {Accept-Charset, Accept}                                                                        
ContentType                    application/json; charset=utf-8                                                                 
Method                         Get                                                                                             
WebSession                     Microsoft.PowerShell.Commands.WebRequestSession                                                 
Uri                            http://172.21.13.54:8080/rest/api/latest/issuetype?maxResults=25                                
UseBasicParsing                True                                                                                            
Verbose                        False                                                                                           



DEBUG: [Invoke-JiraMethod] Executed WebRequest. Access $webResponse to see details
DEBUG: [Test-ServerResponse] Investigating $InputObject.Headers['X-Seraph-LoginReason']
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [ConvertTo-JiraIssueType] Converting $InputObject to custom object
DEBUG: [Get-JiraIssueCreateMetadata] Invoking JiraMethod with $parameter
DEBUG: [Invoke-JiraMethod] ParameterSetName: __AllParameterSets
DEBUG: [Invoke-JiraMethod] PSBoundParameters: 
Key        Value                                                                                                               
---        -----                                                                                                               
Credential System.Management.Automation.PSCredential                                                                           
Method     Get                                                                                                                 
URI        http://172.21.13.54:8080/rest/api/latest/issue/createmeta?projectIds=11601&issuetypeIds=3&expand=projects.issuety...



DEBUG: [Get-JiraSession] ParameterSetName: __AllParameterSets
DEBUG: [Get-JiraSession] PSBoundParameters: 
Key                    Value
---                    -----
ErrorAction SilentlyContinue



DEBUG: [Invoke-JiraMethod] Invoke-WebRequest with $splatParameters: 
Name                           Value                                                                                           
----                           -----                                                                                           
ErrorAction                    Stop                                                                                            
Headers                        {Accept-Charset, Accept}                                                                        
ContentType                    application/json; charset=utf-8                                                                 
Method                         Get                                                                                             
WebSession                     Microsoft.PowerShell.Commands.WebRequestSession                                                 
Uri                            http://172.21.13.54:8080/rest/api/latest/issue/createmeta?issuetypeIds=3&maxResults=25&expand...
UseBasicParsing                True                                                                                            
Verbose                        False                                                                                           



DEBUG: [Invoke-JiraMethod] Executed WebRequest. Access $webResponse to see details
DEBUG: [Test-ServerResponse] Investigating $InputObject.Headers['X-Seraph-LoginReason']
DEBUG: [ConvertTo-JiraCreateMetaField] Converting $InputObject to custom object
Username WebSession                                     
-------- ----------                                     
itam     Microsoft.PowerShell.Commands.WebRequestSession
Get-Member : You must specify an object for the Get-Member cmdlet.
At C:\Users\itam\Documents\WindowsPowerShell\Modules\jiraps\2.9.0\JiraPS.psm1:6094 char:28
+ ... eldNames = (Get-Member -InputObject $fields -MemberType '*Property'). ...

@c4uran c4uran changed the title Error Get-Member : You must specify an object for the Get-Member cmdlet. At C:\Program Files\WindowsPowerShell\Modules\PSJira\1.2.5.251\Internal\ConvertTo-JiraCreateMetaField.ps1:37 char:32 Error Get-Member : You must specify an object for the Get-Member cmdlet. At C:\Users\itam\Documents\WindowsPowerShell\Modules\jiraps\2.9.0\JiraPS.psm1:6094 char:28 Jan 29, 2019
@lipkau
Copy link
Member

lipkau commented Jan 29, 2019

@c4uran
Copy link
Author

c4uran commented Jan 29, 2019

{"expand":"projects","projects":[{"self":"http://172.21.13.54:8080/rest/api/2/project/11601","id":"11601","key":"IT","name":"IT","avatarUrls":{"48x48":"http://172.21.13.54:8080/secure/projectavatar?pid=11601&avatarId=10011","24x24":"http://172.21.13.54:8080/secure/projectavatar?size=small&pid=11601&avatarId=10011","16x16":"http://172.21.13.54:8080/secure/projectavatar?size=xsmall&pid=11601&avatarId=10011","32x32":"http://172.21.13.54:8080/secure/projectavatar?size=medium&pid=11601&avatarId=10011"},"issuetypes":[{"self":"http://172.21.13.54:8080/rest/api/latest/issuetype/3","id":"3","description":"Задача","iconUrl":"http://172.21.13.54:8080/secure/viewavatar?size=xsmall&avatarId=10318&avatarType=issuetype","name":"Задача","subtask":false}]}]}

@Mulaysh30
Copy link

Mulaysh30 commented Jan 31, 2019

Same is happening when I try with: -WHATIF

New-JiraIssue @parameter  -whatif
You must specify an object for the Get-Member cmdlet.
At C:\Users\XXXX\Documents\WindowsPowerShell\Modules\JiraPS\2.9.0\JiraPS.psm1:6094 char:28
+ ... eldNames = (Get-Member -InputObject $fields -MemberType '*Property'). ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : CloseError: (:) [Get-Member], InvalidOperationException
    + FullyQualifiedErrorId : NoObjectInGetMember,Microsoft.PowerShell.Commands.GetM

@lipkau
Copy link
Member

lipkau commented Feb 9, 2019

Thanks you. I will look into it

@c4uran
Copy link
Author

c4uran commented Feb 13, 2019

any ideas? i tried in another spaces create issue and when i dont need any Component/s, its worked fine

@lipkau
Copy link
Member

lipkau commented Feb 13, 2019

Last time I saw this behavior, the problem was with the setup of the project itself.
If I am not mistaken, it was about 2 custom fields that collided.

That One Guy [16:25]
We figured out the problem, it was just duplicate fields in the project.

@Mulaysh30
Copy link

Last time I saw this behavior, the problem was with the setup of the project itself.
If I am not mistaken, it was about 2 custom fields that collided.

That One Guy [16:25]

We figured out the problem, it was just duplicate fields in the project.

Any updates on this?
Thank you,

@c4uran
Copy link
Author

c4uran commented May 30, 2019

Still nothing?

@lipkau lipkau changed the title Error Get-Member : You must specify an object for the Get-Member cmdlet. At C:\Users\itam\Documents\WindowsPowerShell\Modules\jiraps\2.9.0\JiraPS.psm1:6094 char:28 Unable to retrieve CreateMetadata Jun 4, 2019
@lipkau
Copy link
Member

lipkau commented Jun 4, 2019

Hi @c4uran :
I have replied to this almost 4 months ago.

But please provide the output of

Get-JiraProject 11601

@Dejulia489
Copy link
Contributor

This happened to me recently and it was my permissions schema for the project. The credential used in the call needs Create Issues and Browse Projects access to return metadata.

https://community.atlassian.com/t5/Answers-Developer-Questions/Projects-are-not-being-returned-by-a-REST-API-call-to-createmeta/qaq-p/522042

@KristofStroobants
Copy link

For those who have this issue. I had this too when testing in PS7, reverting to 5.1 fixed it.

@ybeltrikov
Copy link

ybeltrikov commented Feb 6, 2024

This might be actually the reason: #498.

I am getting the same error with JiraPS 2.14.6, whereas it works with the same permissions and the same JIRA project on 2.14.
Using PowerShell 5.1

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

No branches or pull requests

6 participants