Skip to content

Compilation Error #6

@xanderdunn

Description

@xanderdunn

Elixir 1.5.1. When I attempt to compile with secure_headers 0.0.1 added to my project's dependencies, I get this error:

== Compilation error in file lib/headers/x_xss_protection.ex ==
** (ArgumentError) expected the moduledoc attribute to contain a binary, a boolean, or nil, got: 'IO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: [value: 0]])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: [value: 1]])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: [value: 1, mode: "block"]])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: [value: 1, report: "http://google.com/"]])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: [value: 1, mode: "block", report: "http://google.com/report"]])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: [value: 1, mode: "block", report: "/report/"]])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: "0"])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: "0;"])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: "1"])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: "1;"])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: "1;mode=block"])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: "1; mode=block"])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: "1; report=http://google.com/"])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: "1; report=/google.com/"])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: "1; mode=block; report=/google.com/"])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: "1; mode=block; report=http://google.com/"])\n\n\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: [value: 0, mode: "block"]])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: [value: 0, report: "http://google.com/"]])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: [value: 0, mode: "block", report: "http://google.com/"]])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: [value: 0, mode: "block", report: "/report/"]])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: [value: 1, mode: "allow"]])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: [value: 1, mode: "allow", report: "http://google.com/"]])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: [value: 2, mode: "block"]])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: [value: 2, modes: "block"]])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: [value: 2, mode: "allow"]])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: [value: 2, report: "google.com"]])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: [value: 2, mode: "allow", report: "http://google.com/"]])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: [value: 2, mode: "block", report: "google.com"]])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: [values: 2]])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: [value: 2, reportz: "google.com"]])\nIO.inspect( SecureHeaders.XXssProtection.validate [x_xss_protection: [valuez: 2, mode: "block", reportz: "google.com"]])\n'
    (elixir) lib/module.ex:1384: Module.preprocess_attribute/2
    (elixir) lib/module.ex:1350: Module.put_attribute/5
    lib/headers/x_xss_protection.ex:3: (module)
    (stdlib) erl_eval.erl:670: :erl_eval.do_apply/6
could not compile dependency :secure_headers, "mix compile" failed. You can recompile this dependency with "mix deps.compile secure_headers", update it with "mix deps.update secure_headers" or clean it with "mix deps.clean secure_headers"

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions