Package: josm / 0.0.svn19369+dfsg-2

01-bts.patch Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
Description: Include Debian version number and BTS link.
 Bugs for the JOSM version present in Debian have to be filed in Debian's
 BTS and not upstream. Also include the Debian version number for better
 bug triaging.
Author: Andreas Putzo <andreas@putzo.net>
Forwarded: not-needed

--- a/src/org/openstreetmap/josm/actions/AboutAction.java
+++ b/src/org/openstreetmap/josm/actions/AboutAction.java
@@ -101,6 +101,8 @@ public final class AboutAction extends J
                 "<p style='font-size:75%'></p>" +
                 "<p>" + tr("Version {0}", version.getVersionString()) + "</p>" +
                 "<p style='font-size:50%'></p>" +
+                "<p>" + tr("Debian release {0}", version.getDebianVersionString()) + "</p>" +
+                "<p style='font-size:50%'></p>" +
                 "<p>" + tr("Last change at {0}", version.getTime()) + "</p>" +
                 "<p style='font-size:50%'></p>" +
                 "<p>" + tr("Java Version {0}", getSystemProperty("java.version")) + "</p>" +
--- a/src/org/openstreetmap/josm/data/Version.java
+++ b/src/org/openstreetmap/josm/data/Version.java
@@ -40,6 +40,7 @@ public class Version {
 
     private int version;
     private String releaseDescription;
+    private String debianVersion;
     private String time;
     private String buildName;
     private boolean isLocalBuild;
@@ -75,6 +76,8 @@ public class Version {
             version = JOSM_UNKNOWN_VERSION;
         }
 
+        debianVersion = properties.getProperty("Debian-Release");
+
         // the last changed data
         //
         time = properties.getProperty("Last Changed Date");
@@ -125,6 +128,10 @@ public class Version {
         return version == 0 ? tr("UNKNOWN") : Integer.toString(version);
     }
 
+    public String getDebianVersionString() {
+        return  debianVersion;
+    }
+
     /**
      * Replies a text with the release attributes
      *
--- a/src/org/openstreetmap/josm/actions/ShowStatusReportAction.java
+++ b/src/org/openstreetmap/josm/actions/ShowStatusReportAction.java
@@ -48,6 +48,7 @@ import org.openstreetmap.josm.io.OsmApi;
 import org.openstreetmap.josm.plugins.PluginHandler;
 import org.openstreetmap.josm.spi.preferences.Config;
 import org.openstreetmap.josm.tools.Logging;
+import org.openstreetmap.josm.tools.OpenBrowser;
 import org.openstreetmap.josm.tools.PlatformHookUnixoid;
 import org.openstreetmap.josm.tools.PlatformManager;
 import org.openstreetmap.josm.tools.Shortcut;
@@ -360,7 +361,7 @@ public final class ShowStatusReportActio
 
         switch (ed.showDialog().getValue()) {
             case 1: ta.copyToClipboard(); break;
-            case 2: BugReportSender.reportBug(reportHeader); break;
+            case 2: OpenBrowser.displayUrl("https://bugs.debian.org/"); break;
             default: // do nothing
         }
         GuiHelper.destroyComponents(ed, false);
--- a/src/org/openstreetmap/josm/gui/bugreport/BugReportDialog.java
+++ b/src/org/openstreetmap/josm/gui/bugreport/BugReportDialog.java
@@ -93,7 +93,8 @@ public class BugReportDialog extends JDi
     private void addMessageSection() {
         String message = tr(
                 "An unexpected exception occurred.\n" + "This is always a coding error. If you are running the latest "
-                        + "version of JOSM, please consider being kind and file a bug report.");
+                        + "version of JOSM, please consider being kind and file a bug report."
+                        + "See https://bugs.debian.org/ for a guide how to do this.");
         Icon icon = UIManager.getIcon("OptionPane.errorIcon");
 
         JPanel panel = new JPanel(new GridBagLayout());
@@ -111,7 +112,7 @@ public class BugReportDialog extends JDi
         panel.add(textPanel, GBC.eop().fill());
 
         panel.add(new JLabel(tr("Manually report at:")+' '), GBC.std());
-        panel.add(new UrlLabel(Config.getUrls().getJOSMWebsite() + "/newticket"), GBC.std().fill(GBC.HORIZONTAL));
+        panel.add(new UrlLabel("https://bugs.debian.org/"), GBC.std().fill(GBC.HORIZONTAL));
         JButton copy = new JButton("Copy to clipboard");
         copy.addActionListener(e -> textPanel.copyToClipboard());
         panel.add(copy, GBC.eol().anchor(GBC.EAST));
@@ -131,8 +132,7 @@ public class BugReportDialog extends JDi
         JMultilineLabel helpText = new JMultilineLabel(
                 tr("If you are running the latest version of JOSM and the plugins, "
                         + "please file a bug report in our bugtracker.\n"
-                        + "There the error information should already be "
-                        + "filled in for you. Please include information on how to reproduce "
+                        + "Please include information on how to reproduce "
                         + "the error and try to supply as much detail as possible."));
         helpText.setMaxWidth(MAX_MESSAGE_SIZE);
         panel.add(helpText, GBC.eop().fill(GridBagConstraints.HORIZONTAL));
@@ -144,9 +144,6 @@ public class BugReportDialog extends JDi
         }
         panel.add(settings);
 
-        JButton sendBugReportButton = new JButton(tr("Report bug"), ImageProvider.getIfAvailable("bug"));
-        sendBugReportButton.addActionListener(e -> sendBug());
-        panel.add(sendBugReportButton, GBC.eol().insets(0, 0, 0, 0).anchor(GBC.SOUTHEAST));
         content.add(panel, GBC.eop().fill(GBC.HORIZONTAL));
     }
 
--- a/src/org/openstreetmap/josm/tools/bugreport/BugReportSender.java
+++ b/src/org/openstreetmap/josm/tools/bugreport/BugReportSender.java
@@ -88,9 +88,7 @@ public class BugReportSender extends Thr
     @Override
     public void run() {
         try {
-            // first, send the debug text using post.
-            String debugTextPasteId = pasteDebugText();
-            String bugUrl = getJOSMTicketURL() + "?pdata_stored=" + debugTextPasteId;
+            String bugUrl = "https://bugs.debian.org/";
 
             // then notify handler
             errorMessage = handler.sendingBugReport(bugUrl, statusText);
@@ -98,7 +96,7 @@ public class BugReportSender extends Thr
                 Logging.warn(errorMessage);
                 handler.failed(errorMessage, statusText);
             }
-        } catch (BugReportSenderException e) {
+        } catch (Exception e) {
             Logging.warn(e);
             errorMessage = e.getMessage();
             handler.failed(errorMessage, statusText);
@@ -134,7 +132,7 @@ public class BugReportSender extends Thr
     }
 
     private static String getJOSMTicketURL() {
-        return Config.getUrls().getJOSMWebsite() + "/josmticket";
+        return "https://bugs.debian.org/";
     }
 
     private static String retrieveDebugToken(Document document) throws XPathExpressionException, BugReportSenderException {
--- a/src/org/openstreetmap/josm/gui/bugreport/DefaultBugReportSendingHandler.java
+++ b/src/org/openstreetmap/josm/gui/bugreport/DefaultBugReportSendingHandler.java
@@ -37,7 +37,7 @@ public class DefaultBugReportSendingHand
             errorPanel.add(new JMultilineLabel(
                     tr("Opening the bug report failed. Please report manually using this website:")),
                     GBC.eol().fill(GridBagConstraints.HORIZONTAL));
-            errorPanel.add(new UrlLabel(Config.getUrls().getJOSMWebsite() + "/newticket", 2), GBC.eop().insets(8, 0, 0, 0));
+            errorPanel.add(new UrlLabel("https://bugs.debian.org/", 2), GBC.eop().insets(8, 0, 0, 0));
             errorPanel.add(new DebugTextDisplay(statusText));
 
             JOptionPane.showMessageDialog(MainApplication.getMainFrame(), errorPanel, tr("You have encountered a bug in JOSM"),