Comments (21)
Can you let me know if you're using SOAP or REST mode for org-jira?
What version Jira are you using on the server?
There were recently some updates that make issue type dynamically fill based on the available issuetypes under a given project (as opposed to showing all issue types, which are not always available under all projects).
from org-jira.
Also prior to this update, when was your last org-jira update?
In the last couple weeks there have been many changes (all calls converted to async about 1 or 2 weeks ago, and then the issue type change just in the last week).
from org-jira.
Can you let me know if you set this in your ~/.emacs (or manually with setvar) and then run some of the org-jira functions if you still experience the issues?
(setq org-jira-deadline-duedate-sync-p nil)
from org-jira.
jiralib-use-restapi
is set to t
(default), if this is what you meant.
The docker container runs JIRA Core 7.2.6.
I only just tried org-jira last Friday at work for the first time.
(setq org-jira-deadline-duedate-sync-p nil)
made no difference I could observe.
I'll try a minimalistic init.el next.
from org-jira.
A minimalistic init.el
did not change anything. Removing org-jira-20161218.1938
, as well as request-20161121.600
followed by their reinstallation via use-package helped somewhat. Now C-c ir and C-c ig work fine. C-c iu though does not update the issue on the server side, but refreshes it just like C-c ir does.
For C-c ir I get in *Messages*
:
Contacting host: 192.168.99.100:8080
org-jira-refresh-issue cb
Tag :NEXT_1: set in 1 headings
Updating buffer list...done
whereas for C-c iu
Contacting host: 192.168.99.100:8080
REQUEST [error] Error (error) while connecting to http://192.168.99.100:8080/rest/api/2/issue/NEXT-1.
Issue ’NEXT-1’ updated!
Tag :NEXT_1: set in 1 headings
Updating buffer list...done
from org-jira.
Can you let me know what your Jira says when you set up request.el debug as such?
(setq request-log-level 'debug)
(setq request-message-level 'debug)
And the update fails?
from org-jira.
Make sure to test with tonight's changes as well, in case any of the cleanup fixed your problem.
from org-jira.
Yes, that helped....
REQUEST [debug] REQUEST
Contacting host: 192.168.99.100:8080
REQUEST [debug] REQUEST--CALLBACK
REQUEST [debug] (buffer-string) =
HTTP/1.1 404 Not Found
Server: Apache-Coyote/1.1
X-AREQUESTID: 356x1247x1
X-ASESSIONID: e4hc5x
X-ASEN: SEN-L9001015
X-Seraph-LoginReason: OK
X-AUSERNAME: aaa
Cache-Control: no-cache, no-store, no-transform
X-Content-Type-Options: nosniff
Content-Encoding: gzip
Vary: User-Agent
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Tue, 20 Dec 2016 05:56:07 GMT
{"errorMessages":["The user named 'aaabbb' does not exist"],"errors":{}}
REQUEST [debug] REQUEST-RESPONSE--CANCEL-TIMER
REQUEST [debug] -CLEAN-HEADER
REQUEST [debug] -CUT-HEADER
REQUEST [debug] error-thrown = nil
REQUEST [debug] -PARSE-DATA
REQUEST [debug] parser = json-read
REQUEST [debug] data = ((errorMessages . [The user named 'aaabbb' does not exist]) (errors))
REQUEST [debug] symbol-status = success
REQUEST [debug] REQUEST
REQUEST [debug] Start querying: http://192.168.99.100:8080/rest/api/2/issue/NEXT-1
REQUEST [debug] -URL-RETRIEVE-CALLBACK
REQUEST [debug] status = (:error (error http 400))
REQUEST [debug] url-http-method = PUT
REQUEST [debug] url-http-response-status = 400
REQUEST [debug] REQUEST--CALLBACK
REQUEST [debug] (buffer-string) =
HTTP/1.1 400 Bad Request
Server: Apache-Coyote/1.1
X-AREQUESTID: 356x1248x1
X-ASESSIONID: e4hc5x
X-ASEN: SEN-L9001015
X-Seraph-LoginReason: OK
X-AUSERNAME: aaa
Cache-Control: no-cache, no-store, no-transform
X-Content-Type-Options: nosniff
Content-Encoding: gzip
Vary: User-Agent
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Date: Tue, 20 Dec 2016 05:56:07 GMT
Connection: close
{"errorMessages":[],"errors":{"assignee":"expected Object containing a 'name' property"}}
REQUEST [debug] REQUEST-RESPONSE--CANCEL-TIMER
REQUEST [debug] -CLEAN-HEADER
REQUEST [debug] -CUT-HEADER
REQUEST [debug] error-thrown = (error http 400)
REQUEST [debug] -PARSE-DATA
REQUEST [debug] parser = json-read
REQUEST [debug] data = ((errorMessages . []) (errors (assignee . expected Object containing a 'name' property)))
REQUEST [debug] symbol-status = error
REQUEST [debug] Executing error callback.
REQUEST [error] Error (error) while connecting to http://192.168.99.100:8080/rest/api/2/issue/NEXT-1.
REQUEST [debug] Executing complete callback.
Issue ’NEXT-1’ updated!
Due to the email address I used a user aaabbb
was created initially. I changed it to only aaa
in JIRA user management. Only for org-jira-update-issue
this seems to be a problem. Even org-jira-progress-issue
worked fine. After changing the user back C-c iu went through alright.
from org-jira.
It seems like update was limited in permissions to the creating user (or authenticated user) and viewing/progressing is allowed by anyone even anonymous users perhaps?
There is lots of caching in org-jira/jiralib at the moment to ensure snappiness among the endpoints, so one thing to be careful of is if you make any changes to your Jira schemes/workflows, you will likely need to fully close and re-open Emacs (or manually nil out all the org-jira*cache
and jiralib*cache
named variables).
I'll probably add a helper function that clears all associated caches and wipes the user credential cookie.
The overall assumption is that on a day to day usage, the project schemas/workflows will change very little, so saving a few seconds on each action (by using caching in this way, for populating selections etc.) is worth it.
Let me know if you run into any other problems!
from org-jira.
With org-jira-get-issues
I get issues assigned to the user I logged in with. The JIRA sample setup creates only one user all sample tickets are created by and are assigned to. For convenience sake all I changed was the username. This change was not reflected in the assignee or reporter shown in JIRA on each ticket. Oh, well. I just hope at work these are also kept aligned.
Caching we can rule out I think. I restarted Emacs several times in the process of testing things out.
Thank you very much for your work on this package though.
from org-jira.
Back at work again. Using org-jira-20170105.2013 from MELPA.
In M-x org-jira-get-issues
is not offered initially. This used to be different. So I'll go with org-jira-get-projects
first:
Login works fine
Projects are shown
Now org-jira-get-issues
is available in M-x. After some processing, I'm back in projects-list.org
... where are my tickets?
*Messages*
has an answer:
The URL is not resolvable
URL: http://maxResults:100/
I'm trying org-jira-get-issues-headonly
... seeing empty buffer issues-headonly.org
. According to *Messages*
it's the same error.
To round things up, I'll give org-jira-get-projects
another try. This time I get org-find-exact-headline-in-buffer: Wrong type argument: stringp, nil and no projects
.
from org-jira.
I re-added the missing autoload for org-jira-get-projects, but normally the issues open in a buffer that matches the project name (so, if your project code is 'SUPER', you would find the projects in a buffer/file at ~/.org-jira/SUPER.org.
from org-jira.
The complete logs when calling org-jira-get-issues
:
REQUEST [debug] REQUEST
REQUEST [debug] Run: curl --silent --include --location --compressed --cookie c:\Users\a\.emacs.d\.cache\request\curl-cookie-jar --cookie-jar c:\Users\a\.emacs.d\.cache\request\curl-cookie-jar --write-out \n(:num-redirects %{num_redirects} :url-effective %{url_effective}) --header Authorization: Basic OMITTED --header Content-Type: application/json https://server.b.com/jira02/rest/api/2/project?expand=description%2Clead%2Curl%2CprojectKeys
REQUEST [debug] REQUEST
REQUEST [debug] Run: curl --silent --include --location --compressed --cookie c:\Users\a\.emacs.d\.cache\request\curl-cookie-jar --cookie-jar c:\Users\a\.emacs.d\.cache\request\curl-cookie-jar --write-out \n(:num-redirects %{num_redirects} :url-effective %{url_effective}) --data-binary @c:/Users/a/AppData/Local/Temp/emacs-request15748y6l --request POST --header Authorization: Basic OMITTED --header Content-Type: application/json https://server.b.com/jira02/rest/api/2/search
REQUEST [debug] REQUEST--CURL-CALLBACK event = finished
REQUEST [debug] REQUEST--CURL-CALLBACK proc = #<process request curl<1>>
REQUEST [debug] REQUEST--CURL-CALLBACK buffer = #<buffer *request curl*-326006>
REQUEST [debug] REQUEST--CURL-CALLBACK symbol-status = nil
REQUEST [debug] REQUEST--CALLBACK
REQUEST [debug] (buffer-string) =
HTTP/1.1 502 notresolvable
Content-Type: text/html
Cache-Control: no-cache
Content-Length: 2989
Proxy-Connection: Keep-Alive
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="X-UA-Compatible" content="IE=7" />
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
</head>
<body>
<p>
The URL is not resolvable
<p>
URL: http://maxResults:100/<br />
<p>For assistance, please contact ...</p>
</body>
</html>
(:num-redirects 0 :url-effective http://maxResults:100/)HTTP/1.1 400 Bad Request
Server: nginx/1.7.9
Date: Mon, 09 Jan 2017 11:56:11 GMT
Content-Type: application/json;charset=UTF-8
Transfer-Encoding: chunked
Connection: keep-alive
X-AREQUESTID: 776x4253168x5
X-ANODEID: node1
X-ASEN: SEN-6393077
Set-Cookie: JSESSIONID=E3899986406EC4C3142346CF11241CA3; Path=/jira02/; HttpOnly
X-Seraph-LoginReason: OK
X-ASESSIONID: 1kirgwf
X-AUSERNAME: [email protected]
Cache-Control: no-cache, no-store, no-transform
X-Content-Type-Options: nosniff
{"errorMessages":["Unexpected character ('j' (code 106)): expected a valid value (number, String, array, object, 'true', 'false' or 'null')\n at [Source: org.apache.catalina.connector.CoyoteInputStream@68ee1d20; line: 1, column: 2]"]}
REQUEST [debug] REQUEST-RESPONSE--CANCEL-TIMER
REQUEST [debug] -CLEAN-HEADER
REQUEST [debug] -CUT-HEADER
REQUEST [debug] error-thrown = (error http 502)
REQUEST [debug] -PARSE-DATA
REQUEST [debug] parser = json-read
REQUEST [debug] data = nil
REQUEST [debug] symbol-status = error
REQUEST [debug] Executing error callback.
REQUEST [error] Error (error) while connecting to https://server.b.com/jira02/rest/api/2/search.
REQUEST [debug] Executing complete callback.
REQUEST [debug] REQUEST--CURL-CALLBACK event = finished
So the :url-effective http://maxResults:100/
returned seems to be the problem. Very well possible that our JIRA server limits the number of tickets returned, deviating from the default which seems to be 1000. Any suggestions?
from org-jira.
Calling the respective curl
command from the log above manually (assuming some search criteria as the --data-binary
file got deleted after execution) works fine.
curl --silent --include --location --compressed --cookie c:\Users\a\.emacs.d\.cache\request\curl-cookie-jar --cookie-jar c:\Users\a\.emacs.d\.cache\request\curl-cookie-jar --write-out '\n(:num-redirects %{num_redirects} :url-effective %{url_effective})' --data '{ "jql": "project = PROJECT", "startAt": 0, "maxResults": 15, "fields": [ "summary", "status", "assignee" ]}' --request POST --header 'Authorization: Basic bWFydGluLmZlaGxoYWJlckBkYi5jb206c1BlY3RyMDc=' --header 'Content-Type: application/json' https://server.b.com/jira02/rest/api/2/search
and returns after the payload
(:num-redirects 0 :url-effective https://server.b.com/jira02/rest/api/2/search)
I have no idea where the :url-effective
above got messed up.
from org-jira.
I wonder if it is Windows related? I only have GNU/Linux available for testing, and it looks like the file paths referenced are Windows based?
it seems that where it is supposed to be grabbing your base domain, instead it is trying to authenticate against http://maxResults:100 (and I assume that isn't your domain/port), and also mangling the authentication JSON (it complains of illegal 'j' character).
from org-jira.
Can you check the value of jiralib-url
and confirm it is set to your domain in format protocol://domain.suffix (such as https://example.com)?
from org-jira.
Please note the comment I left on the other issue ticket you were assisting on, regarding pasting log output.
from org-jira.
I pinned the problem down. It is a regression in request.el
. I am not yet totally sure when exactly it was introduced, but reverting back to version https://raw.githubusercontent.com/tkf/emacs-request/cd5d7d5b8bd683d5847b280acdcaf61192895b22/request.el from 23 Aug 2016 makes org-jira-get-isuues
work fine.
from org-jira.
Thanks, I haven't upgraded request.el recently, so I'll try again with an updated request.el. If you can pinpoint the exact problem that would be awesome though 😄
from org-jira.
Lucky guess on my part. Right the next commit tkf/emacs-request@6e039bf breaks request.el
for me. I went from head down to this one and did not find a working version since.
Somewhat related... is there a way to introduce additional parameters to the curl
call? I need to provide a specific certificate, which I currently do by patching request.el
.
from org-jira.
I asked my question regarding additional curl
options in the respective forum tkf/emacs-request#66 as this really is independent of this project.
from org-jira.
Related Issues (20)
- At every issue update I get a new TODO keyword HOT 1
- Description is not being downloaded. Can't be updated either HOT 3
- Error in org-jira-get-issues: Calling org-fold-core-region with missing SPEC HOT 4
- Sync clock entries fails HOT 4
- clock entries disappear when running org-jira-update-worklogs-from-org-clocks HOT 1
- Multiple Jira Systems HOT 1
- Warnings in emacs 29 HOT 1
- request--curl-callback: event exited abnormally with code 3 HOT 2
- Top headline detection broken with Org 9.7 HOT 1
- org-jira won't get issues from team-managed board HOT 5
- How to delete a comment? HOT 1
- Issue when using an API token to log in HOT 1
- Top-level property support for buffer issue refresh HOT 1
- Unable to use jiralib with Jira cloud and API Token HOT 9
- The default behavior of org-element-use-cache to nil causes everything after the first query to fail HOT 1
- Is it possible to change or add to the fields that `org-jira-get-issues` obtains? HOT 1
- org-jira-create-issue HOT 2
- org-jira-create-issue HOT 2
- What you think about open source Jira alternative solution Plane ? HOT 1
- Is there any existing package for evil users? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from org-jira.