R
Railway

✋|help

Fix Missing libuuid Library

Tthorgexyz8/24/2023
Hey, I am currently runnig into problems deploying my FastAPI backend after adding a new dependency to my requirements.txt (azure-cognitiveservices-speech==1.31.0).

project and service id:
project/21c22b76-3eeb-4e49-8c44-af1f48a72060/service/b1ea6565-9ca2-485e-8f39-be6b7f6cbbe9

Error:
File "/opt/venv/lib/python3.10/site-packages/azure/cognitiveservices/speech/__init__.py", line 8, in <module>

from .speech import *

File "/opt/venv/lib/python3.10/site-packages/azure/cognitiveservices/speech/speech.py", line 13, in <module>

from .interop import (

File "/opt/venv/lib/python3.10/site-packages/azure/cognitiveservices/speech/interop.py", line 20, in <module>

_sdk_lib = load_library.LoadLibrary(lib_path)

File "/root/.nix-profile/lib/python3.10/ctypes/__init__.py", line 452, in LoadLibrary

return self._dlltype(name)

File "/root/.nix-profile/lib/python3.10/ctypes/__init__.py", line 374, in __init__

self._handle = _dlopen(self._name, mode)

OSError: libuuid.so.1: cannot open shared object file: No such file or directory


I tried installing it in my nixpacks.toml file, but it still doesn't work
[phases.validate_libuuid]
cmds = ["ldconfig -p | grep libuuid"]
dependsOn = ["setup"]


# Add a new phase for installing the Prisma CLI
[phases.install_prisma]
cmds = ["npm install -g prisma","which python","python --version"]
dependsOn = ["install"]

# Add a new phase for Prisma generation
[phases.prisma_generate]
cmds = ["prisma generate --schema ./trellis_backend/prisma/schema.prisma"]
dependsOn = ["install_prisma"]

# Update the build phase to depend on the new 'prisma_generate' phase
[phases.build]
dependsOn = ["...", "prisma_generate"]
Solution:
www.unrealspeech.com
Jump to solution
Bbrody1928/24/2023
please enclose code blocks with tripple backticks
as for the missing libuuid

try adding this to your nixpacks.toml file
[phases.setup]
nixPkgs = ['...', 'libuuid']
nixLibs = ['...', 'libuuid']
Tthorgexyz8/24/2023
yes, just formatted!

and thanks, just redeployed to test again
Bbrody1928/24/2023
chill with the edits
Tthorgexyz8/24/2023
yeah sorry just wanted to include the error message
think my message disappeared
Bbrody1928/24/2023
it wasnt deleted by the bot
Tthorgexyz8/24/2023
I'm running into other problems with the azure package when I try to call the tts code. I need to install more dependencies according:
https://learn.microsoft.com/en-us/azure/ai-services/speech-service/quickstarts/setup-platform?pivots=programming-language-csharp&tabs=linux%2Crhel-centos%2Cdotnetcli%2Cdotnet%2Cjre%2Cmaven%2Cnodejs%2Cmac%2Cpypi

current nixpacks:
# nixpacks.toml

# Include auto-detected provider and Python provider
providers = ["..."]

# Install Node.js and other required packages during the setup phase
[phases.setup]
nixPkgs = ["...", "nodejs", "libuuid"]
nixLibs = ['...', 'libuuid']
aptPkgs = ["...", "libssl-dev", "build-essential", "ca-certificates", "libasound2", "wget"]


[phases.validate_libuuid]
cmds = ["ldconfig -p | grep libuuid"]
dependsOn = ["setup"]


# Add a new phase for installing the Prisma CLI
[phases.install_prisma]
cmds = ["npm install -g prisma","which python","python --version"]
dependsOn = ["install"]

# Add a new phase for Prisma generation
[phases.prisma_generate]
cmds = ["prisma generate --schema ./trellis_backend/prisma/schema.prisma"]
dependsOn = ["install_prisma"]

# Update the build phase to depend on the new 'prisma_generate' phase
[phases.build]
dependsOn = ["...", "prisma_generate"]


error:
https://codeshare.io/OdbNl0
Any idea what might be going on? sry for the edits
Bbrody1928/24/2023
so is this a python app or a node app?
Tthorgexyz8/24/2023
python fastapi server
im just installing node to install prisma which is used by the python prisma port (IIRC)
Bbrody1928/24/2023
i thought it was a native python package
double check that
Tthorgexyz8/24/2023
yeah I think the command lines commands still use the regular prima commands
Bbrody1928/24/2023
so yes it does need node?
Tthorgexyz8/24/2023
yes
is that a problem?
Bbrody1928/24/2023
no, just odd
send full logs please
Tthorgexyz8/24/2023
here
Tthorgexyz8/24/2023
this seems to be the problem:
The Speech SDK does not yet support OpenSSL 3.0, which is the default in Ubuntu 22.04 and Debian 12.

locally, I have: OpenSSL 1.1.1u 30 May 2023

on railway, I have:
OpenSSL 3.0.7 1 Nov 2022
Bbrody1928/24/2023
kinda cringe Microsoft, not supporting openssl 1
Tthorgexyz8/24/2023
yeah super annoying
im getting destroyed over here
trying to downgrade openssll with these environment variables
NIXPACKS_DEBIAN
1
NIXPACKS_NIX_PKG
openssl

but shit hits the fan when deploying
Tthorgexyz8/24/2023
Tthorgexyz8/24/2023
do u see any solution that I could try to get this thing to work?

saw this other comment of you that newer nixpacks versions are likely only using openssl 3
Bbrody1928/24/2023
bruh your already defining your nixPkgs in the nixpacks.toml file
Tthorgexyz8/24/2023
what do u mean
Bbrody1928/24/2023
🤨
Tthorgexyz8/24/2023
sorry brah
Bbrody1928/24/2023
you are already defining your nix packages in the nixpacks.toml file, don't go defining nix packages in the environment variables too
NIXPACKS_DEBIAN = 1 should be sufficient
Tthorgexyz8/24/2023
so I can define the openssl version in nixpacks.toml?
Tthorgexyz8/24/2023
okay sweet, got it. this is new deployment error log. trying to debug it rn
Bbrody1928/25/2023
send your nixpacks.toml file
Tthorgexyz8/25/2023
yeah I just fixed by ditching microsoft
cant deal with that shit anymore
Bbrody1928/25/2023
lmfao what did you use instead
Solution
Tthorgexyz8/25/2023
www.unrealspeech.com
Tthorgexyz8/25/2023
just was on a call with the founder
he send over code snippet, things worked in 30 seconds
Bbrody1928/25/2023
ay i love that
yeah thats 1000% a better solution
Tthorgexyz8/25/2023
yeah
thanks for the help anyways
and being patient with me
lmao
Bbrody1928/25/2023
always avoid clunky deps if possible, they just cause more headaches then needed
and while youre at it, maybe use an orm that doesnt need a whole other programing language installed lol
the slimmer you can get your app, generally the more performant it will be, plus less resource usage so lower railway bills
Tthorgexyz8/25/2023
yeah good point

Looking for more? Join the community!

Recommended Posts
I can no longer connect to my MySQL database, even after restarting the databaseI'm not sure what my project id is. My link is this: https://railway.app/project/31b9ee92-06cc-44c1-RPC showing forbidden access 403Hi. I've got some crypto related script which pings an RPC server - it works fine locally but on raiHow would I connect my project with the SQL database ?I have a model for users and I would like to populate my production DB with them. How can I do that?Hipaa/socI wanted to confirm if the information on https://railway.app/help is current as the email listed boMemory consumption differenceSame app deployed in docker local and Hw(M1 16gb) consumes 52 mb with no load railway took 74mb can Nextjs 13 Environmental variableHello! I recently installed Nextjs to try out the "new" app directory, because I heard server actioRailway CLI postgresql not installed?I installed the CLI and postgresql on my computer to use pgloader to migrate a mysql db to postgres How do I hook up my frontend correctly./I am able to deploy my backend but my frontend is not working yet. Error: ``` #8 [4/5] RUN npm ruStyling bug on project service usage pageIs there a way I can have Railway restart manually every 2 hours?Pretty self explanatory, I’m running some js codePostgres, Aspnet Core API and Angular WebguiHi guys. I'm new here and getting to know railway! I find it fantastic for us. I am lost. I would lCannot change default provider for environment thats created during GitHub Pull RequestI posted about this a while back (https://discord.com/channels/713503345364697088/112689969354953113expressidkI'm not sure on how to transfer my wiki.js database data to railway.86f37e49-db7c-4b6f-9c3e-71f5447b116a I am either getting a broken wiki.js database that results in Build and deployment is accountable in service consumptionconsider in a context of docker image number of images downloaded and each operation performed in doQuestion about billHello i have a railway acount and i work with my accounting team but they need an tax number identifEnvironment Variable Not foundI am using nodejs as a backend and the config plugin with it to get the access to the Railway envoirERROR: Cannot connect to the Docker daemon at unix:///var/run/docker.sockI tried deleting my Railway proc file and getting this error now ERROR: Cannot connect to the DockerNeed wordpress template helpI have this error: Please contact your hosting service and ask them to increase max_input_vars valueCan't login using my emailHi there, I'm trying to login to my account using the magic link, but whenever I do it I get this er