Hex library claiming to be newer version than it is

I am using deps from hex.pm.
When I get deps the mix.lock file says I have the latest version of this library I am using.
When I go to use features specified in the hexdocs.pm documentation the libraries modules cannot be found and are not in my deps directory, so how can I have the latest version?

Can anyone tell me if there are any obvious gotchas or mistakes I could be making getting my deps?

Thanks

I find mix hex.outdated is a good thing to run to see what Hex thinks is configured and what is available. What output do you get from that?

It claims to be the latest version.

Is there any way that the hexdocs could be out of sync with the package?
Could this be an issue at the library owners end?

Can you please provide an example of how you try to update, what line is in your mix.exs for that dependency, what line is in your mix.lock for that dependency, what is the latest version for that dep on hex etc?

A full c&p of your terminal output when you try to update or get more info would be nice at well. Without having a concrete example to work with, we can only guess.

And my current guess is that your version constraints are to tight (eg: "~> 1.2.0" when 1.3 is available on hex. Still outdated will see 1.2.x as the latest version as it is the latest version in the specified constraint)

I’m not sure I was precise enough in my previous comment. To be clear - I have the library, but it does not appear to be the latest one as it doesn’t have new files specified in the corresponding docs.

Looking at docs for version 0.15.1

mix hex.outdated shows

Dependency                    Current  Latest  Update possible  
...
commanded                     0.15.1   0.15.1                   
...

mix.lock

%{
....
"commanded": {:hex, :commanded, "0.15.1", "e324ce6e109e716ff03da23a682791f67a0f8d73da64e79d4b03d77eff9faa0c", [:mix], [{:poison, "~> 3.1", [hex: :poison, repo: "hexpm", optional: false]}, {:uuid, "~> 1.1", [hex: :uuid, repo: "hexpm", optional: false]}], "hexpm"},
...
}

my deps…

defp deps do
  [
    ...
    {:commanded, "~> 0.15"},
    ...
  ]
end


https://hexdocs.pm/commanded/0.15.1/Commanded.Commands.CompositeRouter.html#content

Cannot find CompositeRouter in deps dir for this library.

This might be related to bad packaging. I can not even find the mentioned module in the git repository for that dependency in the tag.

It is in master though.

So it seems as if documentation has slipped into the packagedocs for files that are not part of the release. Please file a bug report at the git repository.

It looks like hexdocs.pm is using docs from the github master branch of this repository while claiming that they are 0.15.1: https://hexdocs.pm/commanded/0.15.1/Commanded.Commands.CompositeRouter.html

But github docs for branch 0.15.1** from the repo are different: https://github.com/commanded/commanded/blob/v0.15.1/guides/Commands.md

1 Like

@NobbZ Thanks, will file a bug report.