linusdm

linusdm

I’m trying to add ex_cldr_collation as a dependency to a standard phoenix application. I’m having an issue with the docker build.

I understood that the libicu-dev package is required for building, which got me one step further (at first compilation failed, but now the application at least compiles).

When the image starts the phoenix application, I get this error:

  crasher:
    initial call: application_master:init/4
    pid: <0.2044.0>
    registered_name: []
    exception exit: {{shutdown,
                      {failed_to_start_child,kernel_safe_sup,
                       {on_load_function_failed,'Elixir.Cldr.Collation',
                        {{badmatch,
                          {error,
                           {load_failed,
                            "Failed to load NIF library: '/app/lib/ex_cldr_collation-0.7.0/priv/ucol.so: undefined symbol: ucol_strcollIter_67'"}}},
                         [{'Elixir.Cldr.Collation',init,0,
                           [{file,"lib/cldr_collation.ex"},{line,20}]},
                          {init,'-run_on_load_handlers/2-fun-0-',1,[]}]}}}},
                     {kernel,start,[normal,[]]}}
      in function  application_master:init/4 (application_master.erl, line 142)
  ...

As far as I understand, the runner image also has to have an icu dependency although that’s not mentioned explicitly in the documentation of ex_cldr_collation. But I’m failing to understand which packages exactly would provide these undefined symbols (ucol_strcollIter_67). I’ve tried adding libicu-dev, just like in the builder image, but that didn’t work. The package libicu67 also didn’t resolve the problem.

There was some recent activity on the issue tracker of ex_cldr_collation, but that seems to be more related to ubuntu and alpine images. Moreover, there is no mention of packages required at runtime in the docs, only a mention of what’s required to build, which confuses me a bit.

Suggestions appreciated!

Showing Posts 1 to 2

kip

kip

ex_cldr Core Team

@linusdm, sorry for you not having much fun with this. The documentation definitely needs improvement in this area - my lack of knowledge of the various Linux denominations if the primary fault. I hope others more experienced than I am (probably everyone!) can chime in.

My reading suggests that installing the package icu should bring in the right versions of libicu-dev and libicu for whatever version of Debian you are on.

BTW, I’ve only recently become aware that while Ubuntu and MacOS come with libicu installed (the runtime requirement), Debian and Alpine do not. Which is why runtime requirements haven’t been mentioned - I will fix that now I have some more knowledge (albeit not enough!).

Please do open an issue so we can get to the bottom of this ASAP.

linusdm

linusdm OP

Thanks for the reply. I see you’ve improved the docs already.

There is no package literally called icu though, for debian based installs. There is libicu67 which should provide the missing symbol I think, but it doesn’t fix the error.

I’ve taken it to the issue tracker as you suggested: Can't load NIF library in the default phoenix debian docker image: undefined symbol: ucol_strcollIter_67 · Issue #6 · elixir-cldr/cldr_collation · GitHub
I’ll report back if there is any relevant news.

Thanks!

— All posts loaded —

Where Next? Top

Trending in Questions Top

RSP87
I’m working on a project that simulates the bumbl example in the programming phoenix book. It acts almost like an email client. We have a...
New
RemyXRenard
I’m seeing that a list inside a Kino.DataTable will be interpreted as a charlist, even if the Kino.configure() is set to charlists: :as_l...
New
nseaSeb
Hello, I know there is an approach for handling lists that allows for optimized traversal, but I can’t recall the specific method (somet...
New
velrest
So my question is quite simple and i have found no conclusive answer on forum, google or AI. Should we use :erlang.float for Integer to ...
New
samoloth
Hi, I’ve just set up an application with ash_authentication. There is only magic link strategy for now, so there is no confirmation add o...
New
FlyingNoodle
If a change or preparation module uses Ash.Changeset.get_argument/2 or Ash.Query.get_argument/2 (or any of the other get_argument functio...
New
ryanwinchester
apply_graft/2 doesn’t rewrite an add_many sub-workflow’s deps on an add step. Grafted jobs cancel with “upstream job was deleted” Version...
New

Other Trending Topics Top

mudasobwa
I am happy to introduce the very α version of the new programming language compiled to BEAM. Welcome Cure. It has literally three kille...
New
marciok
Hi there! We created Gust: A task orchestrator inspired by Airflow. For those who have never heard about Aiflow, it’s a Python-based wor...
New
jimsynz
Beam Bots (or just BB for short) is a framework for building fault-tolerant robotics applications in Elixir using familiar OTP patterns. ...
New
Dmk
Xamal is a deployment tool for Elixir apps that deploys native releases to bare metal servers over SSH. It’s a port of GitHub - basecamp/...
New
Damirados
Hello everyone. After busy few months I am happy to announce v0.1.0 of Emerge &amp; Solve. They are GUI (Emerge) and State management (S...
New
netoum
Corex is an accessible, unstyled UI component library for Phoenix that integrates Zag.js state machines using Vanilla JavaScript and Live...
New

We're in Beta

About us Mission Statement

Options

Thread Display Mode




Thread Preview

Skip Thread Previews