Change:
<ins> { stdenv , lib , makeWrapper , fetchurl , makeDesktopItem , copyDesktopItems , imagemagick , openjdk11 , dpkg , writeScript , coreutils , bash , tor , psmisc }: let bisq-launcher = writeScript "bisq-launcher" '' #! ${bash}/bin/bash # Setup a temporary Tor instance TMPDIR=$(${coreutils}/bin/mktemp -d) CONTROLPORT=$(${coreutils}/bin/shuf -i 9100-9499 -n 1) SOCKSPORT=$(${coreutils}/bin/shuf -i 9500-9999 -n 1) ${coreutils}/bin/head -c 1024 < /dev/urandom > $TMPDIR/cookie ${tor}/bin/tor --SocksPort $SOCKSPORT --ControlPort $CONTROLPORT  --ControlPortWriteToFile $TMPDIR/port --CookieAuthFile $TMPDIR/cookie  --CookieAuthentication 1 >$TMPDIR/tor.log --RunAsDaemon 1 torpid=$(${psmisc}/bin/fuser $CONTROLPORT/tcp) echo Temp directory: $TMPDIR echo Tor PID: $torpid echo Tor control port: $CONTROLPORT echo Tor SOCKS port: $SOCKSPORT echo Tor log: $TMPDIR/tor.log echo Bisq log file: $TMPDIR/bisq.log JAVA_TOOL_OPTIONS="-XX:MaxRAM=4g" bisq-desktop-wrapped  --torControlCookieFile=$TMPDIR/cookie  --torControlUseSafeCookieAuth  --torControlPort $CONTROLPORT "$@" > $TMPDIR/bisq.log echo Bisq exited. Killing Tor... kill $torpid ''; in stdenv.mkDerivation rec { version = "1.7.0"; pname = "bisq-desktop"; nativeBuildInputs = [ makeWrapper copyDesktopItems dpkg ]; src = fetchurl { url = "https://github.com/bisq-network/bisq/releases/download/v${version}/Bisq-64bit-${version}.deb"; sha256 = "0crry5k7crmrqn14wxiyrnhk09ac8a9ksqrwwky7jsnyah0bx5k4"; }; desktopItems = [ (makeDesktopItem { name = "Bisq"; exec = "bisq-desktop"; icon = "bisq"; desktopName = "Bisq"; genericName = "Decentralized bitcoin exchange"; categories = "Network;Utility;"; }) ]; unpackPhase = '' dpkg -x $src . ''; installPhase = '' mkdir -p $out/lib $out/bin cp opt/bisq/lib/app/desktop-${version}-all.jar $out/lib makeWrapper ${openjdk11}/bin/java $out/bin/bisq-desktop-wrapped  --add-flags "-jar $out/lib/desktop-${version}-all.jar bisq.desktop.app.BisqAppMain" makeWrapper ${bisq-launcher} $out/bin/bisq-desktop  --prefix PATH : $out/bin copyDesktopItems for n in 16 24 32 48 64 96 128 256; do size=$n"x"$n ${imagemagick}/bin/convert opt/bisq/lib/Bisq.png -resize $size bisq.png install -Dm644 -t $out/share/icons/hicolor/$size/apps bisq.png done; ''; meta = with lib; { description = "A decentralized bitcoin exchange network"; homepage = "https://bisq.network"; license = licenses.mit; maintainers = with maintainers; [ juaningan emmanuelrosa ]; platforms = [ "x86_64-linux" ]; }; } </ins>

Discussion:
Project description It's a p2p marketplace for crypto currencies. Metadata homepage URL: https://bisq.network/ source URL: license: AGPL 3 platforms: linux, mac
I read somewhere that was trying to package it, is it still the case?
I had it running at one point but ran into issues with Tor. I should try again with a newer version...
Heya, any luck with the newer version by any chance ? :)
nope
Good news! Bisq now runs on NixOS :) It was an... adventure getting it to work. Phew! !
Awesome work ! Do you need any help to get it to the PR stage in nixpkgs ?
There are three known run-time issues that need to be worked out: upstrem library has an embeded tor binary which gets extracted within the user's $HOME. I patchelf'ed the binary, though now I'm using the tor package in Nixpkgs instead. But the problem remains that Nix is unaware of this runtime dependency. I think the best solution is to patch the upstream library and get Gradle to use it instead of upstream. I think that can be done with Gradle repo priority. JVM crashes hard when trying to set a wallet passphrase. app launches fine the first time, but subsequent runs fail with an error about being unable to read an RSA key. I think it's referring to the Tor hidden service private key. I was going to tackle the above, until I noticed the poor liquidity. It doesn't make much sense to put in the hours and then not be able to transact.
Thanks for the update ! :) The poor liquidity problem you mention, just to make sure - is this an issue with the market conditions themselves/number of people on the application, or there something technical to fix there that creates this problem ?
It's an issue with the market conditions. I didn't get any indication that the problem was technical in nature.
Hello, I'm a bot and I thank you in the name of the community for opening this issue. To help our human contributors focus on the most-relevant reports, I check up on old issues to see if they're still relevant.

This issue has had no activity for 180 days, and so I marked it as stale, but you can rest assured it will never be closed by a non-human. The community would appreciate your effort in checking if the issue is still valid. If it isn't, please close it. If the issue persists, and you'd like to remove the stale label, you simply need to leave a comment. Your comment can be as simple as "still important to me". If you'd like it to get more attention, you can ask for help by searching for maintainers and people that previously touched related code and @ mention them in a comment. You can use or on the relevant files to find them. Lastly, you can always ask for help at or at .
I would love for this to land, I don't think it's stale, if that's okay
I have Bisq compiling and working in my laptop since some time ago. The only caveat is that I launch tor manually. But maybe you are interested in my nix file. Just update 1.3 to 1.5 and works well at first attempt.
I'm absolutely intetested,
Hi, I share it here:
If you don't mind I want to add your package to my NUR.
Great!! ideally debug and improve and send upstream also.
I finally got around to working on the Bisq package some more. The package in my NUR () is based on 's work. It uses a launcher script which runs a Tor instance in the background on a random port. Said Tor instance is killed once Bisq exits. There's also a .desktop file, so it can be launched from a desktop environment, dmenu, etc. Let me know how it works out for you all.
will test in a bit !
getting when installing from scratch trying again gives me a different hash, e.g.
That fixed-point business is proving to be unreliable. It certainly won't be acceptable for Nixpkgs. Perhaps we can use upstream's .dep package instead of building from source.
I changed the package such that the end-user build is reproduceable, which should eliminate the hash mismatch problem. In a nutshell, the fixed-point "fake build" is now a separate Nix package only meant to be used by package maintainers.

This new "package" called does the "fake build" and produces a script, which when executed generates a fixed-point derivation for all of the Java dependencies; A file named The Bisq package uses , effectively "pinning" the Java dependencies and making the Bisq package reproduceable. Let's see how this works out.
Seems working, good job ! Haven't done transactions, but just clicking around seems okay ? can port wallet over later and try more things, but this may take some time
I successfully completed a transaction!
This issue has been mentioned on NixOS Discourse. There might be relevant details there:
Did you try using when you created the Bisq package? If not, I'll try it and compare.
I was able to make a transactions, everything seem to be working ! :) Thanks for your hard work :) Would it make sense to part to package into nixpkgs now ? This could lower maintenance burden on you specifically, we could ask for more maintainers maybe ? Asking because I think there's a new version of bisq available already
Right now there's a lot of duplicated code, so I need to refactor it to get it ready for Nixpkgs. I plan to compare the current implementation (refactoring needs considered) with . If the latter can reduce the amount of code that needs to be maintained, I'll submit that implementation. If not, I'll submit a refactored version of the current implementation. As for the new version of Bisq, it's already available in my NUR. So far it's working too.
awesome, thanks for that, really good work :)
I tried using your package: but got this error:
is not available on the stable branch yet, so you need to get NUR use unstable:
I tried that and get the same error, is there a specific version I need to pin?
You can pin it to commit or simply the most recent commit from the master branch.
Hmmm, I can't seem to get the package pinning working for nur. I guess I'll just wait until this makes it into the main package listing.
Something is missing in your NUR definition. You first need to import the NUR so that you get a function. Then, apply the function.

Like this:
- would the referenced commits be good to be included in nixpkgs or is something missing ? I've tested 1.6.4 from your recent commit and it just works :)
The commits are ready.
Is there a PR we could try to push through ?
The PR is