Comments (11)
seemed to be a dep issue
from plug.
How did you solve this?
from plug.
/cc @ericmj
from plug.
i am a bit of noob here, but i switched phoenix to use the hex version, and then forked OAuth2Ex and changed it's dep for plug to 0.7.0
I think i had a dependency mismatch because pheonix relies on plug 0.7.0 and I was trying to build 0.6.0 ?
I did mix deps.clean
and then a new mix do deps.get, compile
and it compiled.
I think this was mostly user error, sorry for the issue.
Here is my updated mix.exs
defmodule Koncur.Mixfile do
use Mix.Project
def project do
[ app: :koncur,
version: "0.0.1",
elixir: "~> 1.0.0-rc1",
elixirc_paths: ["lib", "web"],
deps: deps ]
end
# Configuration for the OTP application
def application do
[
mod: { Koncur, [] },
applications: [:cowboy, :phoenix, :logger, :postgrex, :ecto, :oauth2ex]
]
end
# Returns the list of dependencies in the format:
# { :foobar, git: "https://github.com/elixir-lang/foobar.git", tag: "0.1" }
#
# To specify particular versions, regardless of the tag, do:
# { :barbat, "~> 0.1", github: "elixir-lang/barbat" }
defp deps do
[
{:cowboy, "~> 1.0.0"},
{:phoenix, "0.4.0"},
{:postgrex, ">= 0.0.0"},
{:ecto, "~> 0.2.0"},
{:oauth2ex, github: "j-mcnally/oauth2ex"}
]
end
end
from plug.
Well, it may not be an user error because someone else reported it too. So if it happens again and you can provide a way to reproduce it, we would really appreciate it. :)
from plug.
@josevalim @ericmj I ran into this issue recently and am able to reproduce by simply symlinking the _build directory. The following steps can reproduce this issue (using Elixir 1.0.2):
mix new bug_finder
cd bug_finder
Set the dependencies in mix.exs
to:
defp deps do
[
{:plug, "~> 0.8.2"},
{:cowboy, "~> 1.0"}
]
end
mkdir ../_build
ln -nsf ../_build ./_build
mix do deps.get, compile
Error returned is:
== Compilation error on file lib/plug/conn/adapter.ex ==
** (RuntimeError) cannot compile Plug because the :cowboy application is not available. Please ensure it is listed as a dependency before the plug one.
lib/plug/conn/adapter.ex:4: (file)
(elixir) lib/kernel/parallel_compiler.ex:97: anonymous fn/4 in Kernel.ParallelCompiler.spawn_compilers/8
==> plug
could not compile dependency plug, mix compile failed. You can recompile this dependency with `mix deps.compile plug` or update it with `mix deps.update plug`
(full output - https://gist.github.com/efatsi/ae8163a454b0400df05f)
If I haven't symlinked the _build directory the compile runs without issues.
from plug.
@efatsi what do you mean by symlinking the _build directory?
from plug.
And more importantly, why are you doing that? :)
from plug.
@josevalim I'm using capistrano to deploy an elixir app to a remote server, and in order to avoid rebuilding the gitignored _build directory on every deploy (since cap creates a fresh directory on every deploy), I attempted to symlink the _build directory with a shared location. I've since resorted to saving the _build directory out to a shared location and copying it in before compiling the app.
While trying to debug though I came across this issue and noticed you were looking for a way to reproduce.
from plug.
Ah, perfect @efatsi. Thanks for digging this up. I believe we don't really support symlinking _build, as you have noticed, as it contains symlinks inside of itself. Hopefully this was also the reason for @j-mcnally bug, as we haven't seen it in other forms lately.
from plug.
im not sure if my issue was symlinking or not. i dont think it was, i was new born baby new so i just assumed i had messed something up and eventually got it to work.
from plug.
Related Issues (20)
- Mismatch spec for `Plug.Conn.Query.decode` HOT 1
- Plug.RequestId: put the `request_id` in `:private` or `:assigns`? HOT 1
- 1.15 changes decoding behaviour of `[]` HOT 5
- Request: Support MFA tuple for Plug.Session opts HOT 4
- Plug.Upload's random-tempdir generation is not very random HOT 1
- `strip_spaces` fails on `nil` since 1.15.0 HOT 1
- Plug.Conn.Query has changed the way it decodes parameters from 1.14 to 1.15 without warning HOT 1
- More flexible dynamic routes with `:` parameters HOT 2
- Compatibility issue with plug_crypto 2.0.0 HOT 3
- Error: There isn't enough space to open the popup HOT 1
- Docs inconsistency between Plug moduledoc and Plug.run HOT 1
- Plug.Upload: demonitor previous owner when giving away HOT 1
- Compilation issues on Erlang 26.x HOT 3
- html array items are dropped. HOT 1
- Plug.Conn is not closed when user closes the browser's tab (SSE) HOT 2
- setting max_age to nil in put_resp_cookie/4 causes crash HOT 1
- Sending a zip created on-the-fly via Plug.Conn.chunk fails after around 200Mb HOT 8
- Performance Regression in Plug.Conn.Cookies.decode/1 after Upgrading Elixir and Erlang HOT 3
- Plug.Router macros and functional plugs HOT 2
- Wrong editor links when running inside a container HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from plug.