Change:
<del> { lib , writeShellScript , buildFHSEnvBubblewrap , stdenvNoCC , fetchurl , autoPatchelfHook , dpkg , nss , libvorbis , libdrm , libGL , wayland , xkeyboard_config , libthai }: let pname = "insync"; version = "3.8.6.50504"; meta = with lib; { platforms = ["x86_64-linux"]; sourceProvenance = with lib.sourceTypes; [ binaryNativeCode ]; license = licenses.unfree; maintainers = with maintainers; [ hellwolf ]; homepage = "https://www.insynchq.com"; description = "Google Drive sync and backup with multiple account support"; longDescription = '' Insync is a commercial application that syncs your Drive files to your computer.  It has more advanced features than Google's official client such as multiple account support, Google Doc conversion, symlink support, and built in sharing. There is a 15-day free trial, and it is a paid application after that. Known bug(s): 1) Currently the system try icon does not render correctly. 2) libqtvirtualkeyboardplugin does not have necessary Qt library shipped from vendor. ''; mainProgram = "insync"; }; insync-pkg = stdenvNoCC.mkDerivation { name = "${pname}-pkg-${version}"; inherit version meta; src = fetchurl { # Find a binary from https://www.insynchq.com/downloads/linux#ubuntu. url = "https://cdn.insynchq.com/builds/linux/insync_${version}-lunar_amd64.deb"; sha256 = "sha256-BxTFtQ1rAsOuhKnH5vsl3zkM7WOd+vjA4LKZGxl4jk0="; }; buildInputs = [ nss libvorbis libdrm libGL wayland libthai ]; nativeBuildInputs = [ autoPatchelfHook dpkg ]; unpackPhase = '' dpkg-deb --fsys-tarfile $src | tar -x --no-same-permissions --no-same-owner ''; installPhase = '' runHook preInstall mkdir -p $out cp -R usr/* $out/ # use system glibc rm $out/lib/insync/{libgcc_s.so.1,libstdc++.so.6} # remove badly packaged plugins rm $out/lib/insync/PySide2/plugins/platforminputcontexts/libqtvirtualkeyboardplugin.so # remove the unused vendor wrapper rm $out/bin/insync runHook postInstall ''; # NB! This did the trick, otherwise it segfaults! However I don't understand why! dontStrip = true; }; in buildFHSEnvBubblewrap { name = pname; inherit meta; targetPkgs = pkgs: with pkgs; [ insync-pkg libudev0-shim ]; runScript = writeShellScript "insync-wrapper.sh" '' # QT_STYLE_OVERRIDE was used to suppress a QT warning, it should have no actual effect for this binary. echo Unsetting QT_STYLE_OVERRIDE=$QT_STYLE_OVERRIDE echo Unsetting QT_QPA_PLATFORMTHEME=$QT_QPA_PLATFORMTHEME unset QT_STYLE_OVERRIDE unset QPA_PLATFORMTHEME # xkb configuration needed: https://github.com/NixOS/nixpkgs/issues/236365 export XKB_CONFIG_ROOT=${xkeyboard_config}/share/X11/xkb/ echo XKB_CONFIG_ROOT=$XKB_CONFIG_ROOT # For debuging: # export QT_DEBUG_PLUGINS=1 # find -L /usr/share -name "*insync*" exec /usr/lib/insync/insync "$@" ''; # As intended by this bubble wrap, share as much namespaces as possible with user. unshareUser   = false; unshareIpc    = false; unsharePid    = false; unshareNet    = false; unshareUts    = false; unshareCgroup = false; # Since "insync start" command starts a daemon, this daemon should die with it. dieWithParent = false; } </del>

Discussion:
After installing and connecting to remote Drive, the syncing is prevented. ! insync version: 3.8.6.
So the behavior I'm currently observing is that a sync location on my main drive does actually sync but still shows this error, however files do not sync when using a different mounted drive. Both instances report the same error however.
Got the same error on today... I'm installing 23.05 now to see if it works. Edit: Installed 23.05... Same error
That would be because the 23.05 and unstable package are the same package, so the issue persists on both.
If you want to use the package in some capacity running insync with works without error on my end aswell.
amazing! Indeed it works! Thanks a ton man! =)))
I think I fixed it, if anyone wants to give it a try before I merge it to unstable and backport to 23.11: Also, a thumbs-up to the pull request would be helpful to make the process faster!
Could someone bisect what caused this issue in the first place?
It seems highly related to bubblewrap, so not many people can do that digging. I am looking into it, but I only started to get familiar with the bubblewarp code in nixpkgs.
By "bisect", I don't mean a manual process but rather which is a semi-manual way to find the cause of a regression using git. You don't need to be familiar with any code in order to do that, you just need to be able to observe the effects of the code and tell git about it. I'm the opposite; I'm familiar with the buildFHSEnv code but have never used insync and don't intend to do so.
perhaps you could give some guidelines, is there anyways of "chrooting"/entering into a bubble wrapped environment to debug, with insync qt program itself, it's a bit tricky. Though, on a quick thought, I could hack it and make it a bash wrapper instead just to debug what's going on.
I've been meaning to give easier access to this sort of thing but haven't found the time to do so. You should be able to simply replace the with and then run your wrapper manually for debugging purposes. See for inspiration; I intended to emulate that experience.

FYI: Also, a new package for nautilus users: please give a :+1: for faster merging!