{"action":"created","issue":{"url":"https://api.github.com/repos/alexarchambault/coursier/issues/261","repository_url":"https://api.github.com/repos/alexarchambault/coursier","labels_url":"https://api.github.com/repos/alexarchambault/coursier/issues/261/labels{/name}","comments_url":"https://api.github.com/repos/alexarchambault/coursier/issues/261/comments","events_url":"https://api.github.com/repos/alexarchambault/coursier/issues/261/events","html_url":"https://github.com/alexarchambault/coursier/issues/261","id":157151983,"number":261,"title":"Support redirect to https for project sbt files","user":{"login":"jvliwanag","id":211068,"avatar_url":"https://avatars.githubusercontent.com/u/211068?v=3","gravatar_id":"","url":"https://api.github.com/users/jvliwanag","html_url":"https://github.com/jvliwanag","followers_url":"https://api.github.com/users/jvliwanag/followers","following_url":"https://api.github.com/users/jvliwanag/following{/other_user}","gists_url":"https://api.github.com/users/jvliwanag/gists{/gist_id}","starred_url":"https://api.github.com/users/jvliwanag/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jvliwanag/subscriptions","organizations_url":"https://api.github.com/users/jvliwanag/orgs","repos_url":"https://api.github.com/users/jvliwanag/repos","events_url":"https://api.github.com/users/jvliwanag/events{/privacy}","received_events_url":"https://api.github.com/users/jvliwanag/received_events","type":"User","site_admin":false},"labels":[{"id":225269281,"url":"https://api.github.com/repos/alexarchambault/coursier/labels/bug","name":"bug","color":"fc2929","default":true}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2016-05-27T08:06:05Z","updated_at":"2016-11-08T03:17:20Z","closed_at":null,"body":"Given urls starting with `http://flywaydb.org/repo` redirects to https, and the ff project sbt file:\n\n``` sbt\n// project/plugins.sbt\n\naddSbtPlugin(\"org.flywaydb\" % \"flyway-sbt\" % \"4.0.1\")\n\nresolvers += \"Flyway\" at \"http://flywaydb.org/repo\"\n```\n\nStarting sbt fails since the pom and hash fails to download.\n\n```\nhttp://flywaydb.org/repo/org/flywaydb/flyway-sbt_2.10_0.13/4.0.1/flyway-sbt-4.0.1.pom\n         [          ] 0 B (0 B / s)\nhttps://repo1.maven.org/maven2/com/jcraft/jsch/0.1.46/jsch-0.1.46.pom\n  100.0% [##########] 3.3 KiB (5.5 KiB / s)\n[error]\n[error] 1 error(s):\n[error]   org.flywaydb:flyway-sbt;sbtVersion=0.13;scalaVersion=2.10:4.0.1:\n[error]     not found: /Users/jvliwanag/.sbt/0.13/plugins/target/resolution-cache/org.flywaydb/flyway-sbt/scala_2.10/sbt_0.13/4.0.1/resolved.xml.xml\n[error]     Not found\n[error]     not found: https://repo.typesafe.com/typesafe/ivy-releases/org.flywaydb/flyway-sbt/scala_2.10/sbt_0.13/4.0.1/ivys/ivy.xml\n[error]     not found: https://repo.scala-sbt.org/scalasbt/sbt-plugin-releases/org.flywaydb/flyway-sbt/scala_2.10/sbt_0.13/4.0.1/ivys/ivy.xml\n[error]     not found: /Users/jvliwanag/.ivy2/local/org.flywaydb/flyway-sbt/scala_2.10/sbt_0.13/4.0.1/ivys/ivy.xml\n[error]     not found: https://repo1.maven.org/maven2/org/flywaydb/flyway-sbt_2.10_0.13/4.0.1/flyway-sbt-4.0.1.pom\n[error]     not found: /doesnotexist/repository/org.flywaydb/flyway-sbt/scala_2.10/sbt_0.13/4.0.1/ivys/ivy.xml\n[error]     not found: /usr/local/Cellar/typesafe-activator/1.3.2/libexec/repository/org.flywaydb/flyway-sbt/scala_2.10/sbt_0.13/4.0.1/ivys/ivy.xml\n[error]     not found: http://repo.typesafe.com/typesafe/releases/org/flywaydb/flyway-sbt_2.10_0.13/4.0.1/flyway-sbt-4.0.1.pom\n[error]     not found: http://repo.typesafe.com/typesafe/ivy-releases/org.flywaydb/flyway-sbt/scala_2.10/sbt_0.13/4.0.1/ivys/ivy.xml\n[error]     checksum format error: /Users/jvliwanag/.coursier/cache/v1/http/flywaydb.org/repo/org/flywaydb/flyway-sbt_2.10_0.13/4.0.1/flyway-sbt-4.0.1.pom.sha1\njava.lang.Exception: Encountered 1 error(s) in dependency resolution\n```\n\nCuriously, the url (http://flywaydb.org/...) where coursier attempted to download form is not listed in the `not found` section of the error log.\n\nFixing the resolver to the proper https file of course fixes the issue.\n\n```\nresolvers += \"Flyway\" at \"https://flywaydb.org/repo\"\n```\n\nLooks like this is only an issue on `project/*.sbt` files. The main sbt files (not in `project`) are not affected.\n"},"comment":{"url":"https://api.github.com/repos/alexarchambault/coursier/issues/comments/259034313","html_url":"https://github.com/alexarchambault/coursier/issues/261#issuecomment-259034313","issue_url":"https://api.github.com/repos/alexarchambault/coursier/issues/261","id":259034313,"user":{"login":"kzys","id":19111,"avatar_url":"https://avatars.githubusercontent.com/u/19111?v=3","gravatar_id":"","url":"https://api.github.com/users/kzys","html_url":"https://github.com/kzys","followers_url":"https://api.github.com/users/kzys/followers","following_url":"https://api.github.com/users/kzys/following{/other_user}","gists_url":"https://api.github.com/users/kzys/gists{/gist_id}","starred_url":"https://api.github.com/users/kzys/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kzys/subscriptions","organizations_url":"https://api.github.com/users/kzys/orgs","repos_url":"https://api.github.com/users/kzys/repos","events_url":"https://api.github.com/users/kzys/events{/privacy}","received_events_url":"https://api.github.com/users/kzys/received_events","type":"User","site_admin":false},"created_at":"2016-11-08T03:17:20Z","updated_at":"2016-11-08T03:17:20Z","body":"Apparently flyway.org itself is not working properly.\r\n\r\n```\r\n% curl -D - http://flywaydb.org/repo/org/flywaydb/flyway-sbt/4.0.1/flyway-sbt-4.0.1.pom\r\nHTTP/1.1 301 Moved Permanently\r\nDate: Tue, 08 Nov 2016 03:05:44 GMT\r\nTransfer-Encoding: chunked\r\nConnection: keep-alive\r\nSet-Cookie: __cfduid=d88095cdf0ee097fb00933642220d579e1478574344; expires=Wed, 0\r\n8-Nov-17 03:05:44 GMT; path=/; domain=.flywaydb.org; HttpOnly\r\nLocation: https://flywaydb.org/repo/org/flywaydb/flyway-sbt/4.0.1/flyway-sbt-4.0\r\n.1.pom\r\nServer: cloudflare-nginx\r\nCF-RAY: 2fe5ce17c26d1b97-SEA\r\n\r\n%\r\n```\r\n\r\nHowever, the HTTPS URL in the Location header is 404.\r\n\r\n```\r\n% curl -D - https://flywaydb.org/repo/org/flywaydb/flyway-sbt/4.0.1/flyway-sbt-4.0.1.pom\r\nHTTP/1.1 404 Not Found\r\nDate: Tue, 08 Nov 2016 03:05:58 GMT\r\nContent-Type: text/html; charset=utf-8\r\nTransfer-Encoding: chunked\r\nConnection: keep-alive\r\nSet-Cookie: __cfduid=d54490c2f8c15234d5c1815a6c8b8a2e11478574358; expires=Wed, 0\r\n8-Nov-17 03:05:58 GMT; path=/; domain=.flywaydb.org; HttpOnly\r\nAccess-Control-Allow-Origin: *\r\nX-GitHub-Request-Id: 6CA2F5F0:31ED:1533EAE:58214114\r\nServer: cloudflare-nginx\r\nCF-RAY: 2fe5ce6dff2a2a19-SEA\r\n\r\n<!DOCTYPE HTML>\r\n<html lang=\"en-US\">\r\n<head>\r\n    <meta charset=\"UTF-8\">\r\n    <meta http-equiv=\"refresh\" content=\"1;url=/\">\r\n    <script type=\"text/javascript\">\r\n        window.location.href = \"/\"\r\n    </script>\r\n    <title>Page Not Found</title>\r\n</head>\r\n<body>\r\nPage Not Found! Return to the <a href='/'>home page</a>\r\n</body>\r\n</html>%\r\n```\r\n\r\nDoes it work with SBT or Maven?\r\n"}}
{"actor":{"display_login":"kzys"}}