Skip to content

aeson+witherable dependency issue building simplex-chat on openbsd 7.7 #10943

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
machatata opened this issue May 3, 2025 · 13 comments
Open

Comments

@machatata
Copy link

Describe the bug
building simplex-chat on openbsd 7.7 with ghc 9.8.3 and cabal.

To Reproduce
within simplex-chat git folder, executing:

cabal update

doas cabal install --allow-newer=base,bytestring,template-haskell,text,process simplex-chat:exe:simplex-chat

OR

doas cabal install simplex-chat:exe:simplex-chat

Expected behavior
installation of simplex-chat

System information
OpenBSD 7.7
GHC 9.8.3
cabal-install version 3.14.1.1

Output Error

Warning: The package list for 'hackage.haskell.org' does not exist. Run 'cabal
update' to download it.
Error: [Cabal-7107]
Could not resolve dependencies:
[__0] trying: aeson-2.2.1.0 (user goal)
[__1] unknown package: witherable (dependency of aeson)
[__1] fail (backjumping, conflict set: aeson, witherable)
After searching the rest of the dependency tree exhaustively, these were the goals I've had most trouble fulfilling: aeson, witherable

@geekosaur
Copy link
Collaborator

Did you try running cabal update as per the warning?

@machatata
Copy link
Author

indeed, ran cabal update,
reran it again just to show this output:
"Configuration is affected by the following files:

  • cabal.project
    Downloading the latest package list from hackage.haskell.org
    Package list of hackage.haskell.org is up to date.
    The index-state is set to 2025-05-03T16:54:17Z."

reran the cabal install command and still the same output.

@geekosaur
Copy link
Collaborator

Why do you have a cabal.project? Does --ignore-project change anything?

@machatata
Copy link
Author

cabal.project was there to begin with in the github repo. there is also a simplex-chat.cabal file in the simplex-chat folder.

interesting, with your suggestion, the output to the following command:

doas cabal install --ignore-project simplex-chat:exe:simplex-chat

is

Warning: The package list for 'hackage.haskell.org' does not exist. Run 'cabal
update' to download it.
Downloading simplex-chat:exe:simplex-chat
Error: cabal: '/usr/local/bin/curl' exited with an error:
curl: (3) URL rejected: Port number was not a decimal number between 0 and
65535

it seems like there is some port issue here.

@geekosaur
Copy link
Collaborator

Can you rerun that with -v3 to show the command it's running, please?

@machatata
Copy link
Author

i appreciate your patience.
executing:

doas cabal install -v3 --ignore-project simplex-chat:exe:simplex-chat

produces

Reading available packages of hackage.haskell.org...
Using most recent state specified from most recent cabal update
Warning: The package list for 'hackage.haskell.org' does not exist. Run 'cabal
update' to download it.
index-state(hackage.haskell.org) = Unknown or invalid timestamp
Searching for ghc in path.
Found ghc at /usr/local/bin/ghc
Running: /usr/local/bin/ghc --numeric-version
/usr/local/bin/ghc is version 9.8.3
looking for tool ghc-pkg near compiler in /usr/local/bin
candidate locations:
["/usr/local/bin/ghc-pkg-ghc-9.8.3","/usr/local/bin/ghc-pkg-9.8.3","/usr/local/bin/ghc-pkg","/usr/local/bin/ghc-pkg"]
found ghc-pkg in /usr/local/bin/ghc-pkg-9.8.3
Running: /usr/local/bin/ghc-pkg-9.8.3 --version
/usr/local/bin/ghc-pkg-9.8.3 is version 9.8.3
Running: /usr/local/bin/ghc --supported-languages
with environment: [("DISPLAY",":0"),("DOAS_USER","garfield"),("HOME","/root"),("LOGNAME","root"),("PATH","/usr/bin:/bin:/usr/sbin:/sbin:/usr/X11R6/bin:/usr/local/bin:/usr/local/sbin"),("SHELL","/bin/ksh"),("TERM","st-256color"),("USER","root")]
Running: /usr/local/bin/ghc --info
with environment: [("DISPLAY",":0"),("DOAS_USER","garfield"),("HOME","/root"),("LOGNAME","root"),("PATH","/usr/bin:/bin:/usr/sbin:/sbin:/usr/X11R6/bin:/usr/local/bin:/usr/local/sbin"),("SHELL","/bin/ksh"),("TERM","st-256color"),("USER","root")]
Reading installed packages...
Warning: Package db
/root/.local/state/cabal/store/ghc-9.8.3-inplace/package.db does not exist yet
Running: /usr/local/bin/ghc-pkg-9.8.3 dump --global -v0
with environment: [("DISPLAY",":0"),("DOAS_USER","garfield"),("HOME","/root"),("LOGNAME","root"),("PATH","/usr/bin:/bin:/usr/sbin:/sbin:/usr/X11R6/bin:/usr/local/bin:/usr/local/sbin"),("SHELL","/bin/ksh"),("TERM","st-256color"),("USER","root")]
Running: /usr/local/bin/ghc --print-libdir
with environment: [("DISPLAY",":0"),("DOAS_USER","garfield"),("HOME","/root"),("LOGNAME","root"),("PATH","/usr/bin:/bin:/usr/sbin:/sbin:/usr/X11R6/bin:/usr/local/bin:/usr/local/sbin"),("SHELL","/bin/ksh"),("TERM","st-256color"),("USER","root")]
creating /tmp/cabal-install.-74440/dist-newstyle
creating /tmp/cabal-install.-74440/dist-newstyle/cache
File monitor
'exe:simpl_-9cb170b53bcd3c524773baeef122247d0427a5e3d6e6e9671af903d4aab33ee1.cache'
changed: first run
Searching for curl in path.
Found curl at /usr/local/bin/curl
Searching for powershell in path.
Cannot find powershell on the path
Searching for wget in path.
Cannot find wget on the path
Selected http transport implementation: curl
Downloading simplex-chat:exe:simplex-chat
creating /tmp/cabal-install.-74440/dist-newstyle/src
Running: /usr/local/bin/curl 'simplex-chat:exe:simplex-chat' --output '/tmp/cabal-install.-74440/dist-newstyle/src/exe:simpl_-9cb170b53bcd3c524773baeef122247d0427a5e3d6e6e9671af903d4aab33ee1.tar74440-0.gz' --location --write-out '%{http_code}' --user-agent 'cabal-install/3.14.1.1 (openbsd; x86_64)' --silent --show-error --dump-header /tmp/cabal-install.-74440/dist-newstyle/src/curl-headers74440-1.txt
with environment: [("DISPLAY",":0"),("DOAS_USER","garfield"),("HOME","/root"),("LOGNAME","root"),("PATH","/usr/bin:/bin:/usr/sbin:/sbin:/usr/X11R6/bin:/usr/local/bin:/usr/local/sbin"),("SHELL","/bin/ksh"),("TERM","st-256color"),("USER","root")]
/usr/local/bin/curl returned ExitFailure 3
/usr/local/bin/curl returned ExitFailure 3 with error message:
curl: (3) URL rejected: Port number was not a decimal number between 0 and
65535
CallStack (from HasCallStack):
withMetadata, called at src/Distribution/Simple/Utils.hs:447:12 in Cabal-3.14.1.1-7ihibts0cDTFLoXoS4uGXL:Distribution.Simple.Utils
Error: cabal: '/usr/local/bin/curl' exited with an error:
curl: (3) URL rejected: Port number was not a decimal number between 0 and
65535

@geekosaur
Copy link
Collaborator

Ugh, that's completely wrong. Sounds like #9817, though.

@machatata
Copy link
Author

interesting. thanks for pointing this out. without the --ignore-project addition, i wouldn't have been able to diagnose the issue.

@geekosaur
Copy link
Collaborator

In the meantime, you can try using cabal install --ignore-project simplex-chat without naming the executable component. Sadly, if I understand the other ticket correctly, that may not work.

@machatata
Copy link
Author

indeed, it does not work with the same port error. i appreciate the help troubleshooting though!

look forward to it perhaps working some time in the future as having a way aside from ssh'ing through VMs on OpenBSD would be convenient.

@ulysses4ever
Copy link
Collaborator

@ulysses4ever
Copy link
Collaborator

ulysses4ever commented May 5, 2025

indeed, it does not work with the same port error

There shouldn't be the port error, if, as @geekosaur suggested, you don't specify the component (so, only specify the package name, simplex-chat).

On another note, can you specify what you're trying to achieve:

  1. Install an executable from a local checkout of the repository
  2. Install an executable from Hackage.

It's either 1 or 2. These are two very different things. If it's 1, then --ignore-peoject is not what you want.

Lastly, please use triple backticks (i.e. ```) on separate lines to delimit your console interactions, not the > sign, which is meant for text quotes.

@ulysses4ever
Copy link
Collaborator

Oh, it's not on Hackage, so I guess it's (1).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants