万年素人からHackerへの道

万年素人がHackerになれるまで殴り書きするぜ。

  • ・資産運用おすすめ
    10万円は1000円くらい利益
    資産運用ブログ アセマネ
    • ・寄付お願いします
      YENTEN:YYzNPzdsZWqr5THWAdMrKDj7GT8ietDc2W
      BitZenny:ZfpUbVya8MWQkjjGJMjA7P9pPkqaLnwPWH
      c0ban:8KG95GXdEquNpPW8xJAJf7nn5kbimQ5wj1
      Skycoin:KMqcn7x8REwwzMHPi9fV9fbNwdofYAWKRo

    Phoenixの起動でエラー

    mix phoenix.server

    でサーバ起動しようとしたら。

    Compiled lib/phoenixapp.ex
    [warning] calling "plug :router, YourApp.Router" in your endpoint is deprecated, plug your router directly instead: "plug YourApp.Router"
        lib/phoenixapp/endpoint.ex:32: Phoenixapp.Endpoint (module)
    Compiled web/web.ex
    Compiled lib/phoenixapp/repo.ex
    [deprecated] plug :action is no longer required in controllers, please remove it from Phoenixapp.PageController
    Compiled web/controllers/page_controller.ex
    Compiled web/router.ex
    Compiled lib/phoenixapp/endpoint.ex
    
    == Compilation error on file web/views/page_view.ex ==
    ** (CompileError) web/views/page_view.ex:2: module Phoenix.HTML is not loaded and could not be found
        (elixir) expanding macro: Kernel.use/1
        web/views/page_view.ex:2: Phoenixapp.PageView (module)
        expanding macro: Phoenixapp.Web.__using__/1
        web/views/page_view.ex:2: Phoenixapp.PageView (module)
        (elixir) expanding macro: Kernel.use/2
        web/views/page_view.ex:2: Phoenixapp.PageView (module)
    
    
    == Compilation error on file web/views/layout_view.ex ==
    ** (CompileError) web/views/layout_view.ex:2: module Phoenix.HTML is not loaded and could not be found
        (elixir) expanding macro: Kernel.use/1
        web/views/layout_view.ex:2: Phoenixapp.LayoutView (module)
        expanding macro: Phoenixapp.Web.__using__/1
        web/views/layout_view.ex:2: Phoenixapp.LayoutView (module)
        (elixir) expanding macro: Kernel.use/2
        web/views/layout_view.ex:2: Phoenixapp.LayoutView (module)
    
    
    == Compilation error on file web/views/error_view.ex ==
    ** (CompileError) web/views/error_view.ex:2: module Phoenix.HTML is not loaded and could not be found
        (elixir) expanding macro: Kernel.use/1
        web/views/error_view.ex:2: Phoenixapp.ErrorView (module)
        expanding macro: Phoenixapp.Web.__using__/1
        web/views/error_view.ex:2: Phoenixapp.ErrorView (module)
        (elixir) expanding macro: Kernel.use/2
        web/views/error_view.ex:2: Phoenixapp.ErrorView (module)

    となった・・。

    新しいの入れる

     mix archive.install https://github.com/phoenixframework/phoenix/releases/download/v0.16.1/phoenix_new-0.16.1.ez

    一旦プロジェクト消す

    cd ../
    rm -rf phoenix_app

    そしてまた作ってみた

    mix phoenix.new phoenix_app
    cd phoenix_app
    mix ecto.create

    起動した。

    mix phoenix.server
    [info] Running Phoenixapp.Endpoint with Cowboy on http://localhost:4000