<p><b>@freimair</b> commented on this pull request.</p>

<hr>

<p>In <a href="https://github.com/bisq-network/bisq/pull/1893#discussion_r231907809">core/src/main/java/bisq/core/app/BisqExecutable.java</a>:</p>
<pre style='color:#555'>> @@ -330,6 +333,14 @@ protected void customizeOptionParsing(OptionParser parser) {
         parser.accepts(NetworkOptionKeys.SOCKS_5_PROXY_HTTP_ADDRESS,
                 description("A proxy address to be used for Http requests (should be non-Tor). [host:port]", ""))
                 .withRequiredArg();
+        parser.accepts(NetworkOptionKeys.TORRC_FILE,
+                description("An existing torrc-file to be sourced for Tor. Note that torrc-entries, which are critical to Bisqs flawless operation, cannot be overwritten.", ""))
+                .withRequiredArg();
+//                .withValuesConvertedBy(new PathConverter(PathProperties.FILE_EXISTING, PathProperties.READABLE));
+        parser.accepts(NetworkOptionKeys.TORRC_OPTIONS,
+                description("A list of torrc-entries to amend to Bisqs torrc. Note that torrc-entries, which are critical to Bisqs flawless operation, cannot be overwritten. [torrc options line, torrc option, ...]", ""))
+                .withRequiredArg();
+//                .withValuesConvertedBy(RegexMatcher.regex("^([^\\s,]+\\s[^,]+,?\\s*)+$"));
</pre>
<p>JOptSimple offers input parsing and therefore allows for instant feedback (i.e. showing --help). However, JOptSimple only engages these checks when the value of interest is accessed via <code>option.valueOf</code>. So as of now, these lines are disabled.</p>
<p>In order to make Bisq more user friendly, we can do something like:</p>
<ol>
<li>do not use this feature. Errors on command line inputs show up some time later (if manually checked), probably hidden under tons of logs.</li>
<li>enable line 339 and 343 above and receive an exception stating the cause</li>
<li>change BisqExecutable.java: move line 151: <code>setupEnvironment(options);</code> up after line 134, i.e. into the try-catch-block, that houses the initial parsing</li>
<li>enable line 339 and 343 and change BisqExecutable::setupEnvironment to something like that:
<pre><code>protected void setupEnvironment(OptionSet options) {
   try {
       bisqEnvironment = getBisqEnvironment(options);
   }catch (OptionException e) {
       System.err.println(e.getMessage() + ": " + e.getCause().getMessage());
       // we only tried to load some config, so no graceful shutdown is required
       System.exit(1);
   }
}
</code></pre>
resulting in a final log line such as
<pre><code>Cannot parse argument '/tmp/torr' of option torrcFile: File [/tmp/torr] does not exist
</code></pre>
</li>
<li>somehow influence JOptSimple to do the check on parse</li>
</ol>
<p>IMHO, 4 seems like a good solution. 1 and 2 are not user friendly at all, 3 only states the help index without any detailled information on the error and 5 might probably never happen</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/bisq-network/bisq/pull/1893#pullrequestreview-172982255">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AkpZtv5Iag7efebWgJUyEsO2XXsMGqthks5utEePgaJpZM4YSyWY">mute the thread</a>.<img src="https://github.com/notifications/beacon/AkpZtrDGhq0zt2V2Ag_n37URvggl-9xZks5utEePgaJpZM4YSyWY.gif" height="1" width="1" alt="" /></p>
<script type="application/json" data-scope="inboxmarkup">{"api_version":"1.0","publisher":{"api_key":"05dde50f1d1a384dd78767c55493e4bb","name":"GitHub"},"entity":{"external_key":"github/bisq-network/bisq","title":"bisq-network/bisq","subtitle":"GitHub repository","main_image_url":"https://assets-cdn.github.com/images/email/message_cards/header.png","avatar_image_url":"https://assets-cdn.github.com/images/email/message_cards/avatar.png","action":{"name":"Open in GitHub","url":"https://github.com/bisq-network/bisq"}},"updates":{"snippets":[{"icon":"PERSON","message":"@freimair commented on #1893"}],"action":{"name":"View Pull Request","url":"https://github.com/bisq-network/bisq/pull/1893#pullrequestreview-172982255"}}}</script>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/bisq-network/bisq/pull/1893#pullrequestreview-172982255",
"url": "https://github.com/bisq-network/bisq/pull/1893#pullrequestreview-172982255",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
},
{
"@type": "MessageCard",
"@context": "http://schema.org/extensions",
"hideOriginalBody": "false",
"originator": "AF6C5A86-E920-430C-9C59-A73278B5EFEB",
"title": "@freimair commented on 1893",
"sections": [
{
"text": "",
"activityTitle": "**Florian Reimair**",
"activityImage": "https://assets-cdn.github.com/images/email/message_cards/avatar.png",
"activitySubtitle": "@freimair",
"facts": [

]
}
],
"potentialAction": [
{
"targets": [
{
"os": "default",
"uri": "https://github.com/bisq-network/bisq/pull/1893#pullrequestreview-172982255"
}
],
"@type": "OpenUri",
"name": "View on GitHub"
},
{
"name": "Unsubscribe",
"@type": "HttpPOST",
"target": "https://api.github.com",
"body": "{\n\"commandName\": \"MuteNotification\",\n\"threadId\": 407578008\n}"
}
],
"themeColor": "26292E"
}
]</script>