-
Notifications
You must be signed in to change notification settings - Fork 189
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
UndefVarError: PARAMS_FLASH_KEY not defined #553
Comments
@essenciary constant is missing in Router.jl. const PARAMS_FLASH_KEY = :FLASH |
Genie.Router.PARAMS_FLASH_KEY - > GenieSession.PARAMS_FLASH_KEY |
The ViewHelper.jl file has been removed in Genie 5. If you don't use the file I suggest deleting it. |
Is there any other way output_flash() is exported or is there any alternative to output_flash() in Genie5? I have used output_flash() in many cases. |
I'll take a look and see how we can fix it - the complexity is, it can't be integrated in the same way in Genie as it's now a separate package. |
Error: 2022-07-31 05:27:39 UndefVarError: PARAMS_FLASH_KEY not defined
│ Stacktrace:
│ [1] getproperty
│ @ .\Base.jl:35 [inlined]
│ [2] flash()
│ @ GenieSession.Flash C:\Users\chara.julia\packages\GenieSession\meV9f\src\Flash.jl:18
│ [3] flash_has_message()
│ @ GenieSession.Flash C:\Users\chara.julia\packages\GenieSession\meV9f\src\Flash.jl:41
│ [4] output_flash(flashtype::String) (repeats 2 times)
│ @ Sailhood.ViewHelper D:\Sailhood\sailhood\app\helpers\ViewHelper.jl:8
│ [5] (::Sailhood.AuthenticationController.var"#5#14")()
│ @ Sailhood.AuthenticationController D:\Sailhood\sailhood\build\GenieViews\45f10c20d3ba4ee0e6aa0c77f156b84c5228917a.jl:28
│ [6] #invokelatest#2
│ @ .\essentials.jl:716 [inlined]
│ [7] invokelatest
│ @ .\essentials.jl:714 [inlined]
│ [8] normal_element(f::Function, elem::String, args::Vector{Any}, attrs::Vector{Pair{Symbol, Any}})
│ @ Genie.Renderer.Html C:\Users\chara.julia\packages\Genie\mMGS8\src\renderers\Html.jl:137
│ [9] #span#256
│ @ .\none:2 [inlined]
│ [10] func_45f10c20d3ba4ee0e6aa0c77f156b84c5228917a(; context::Module)
│ @ Sailhood.AuthenticationController D:\Sailhood\sailhood\build\GenieViews\45f10c20d3ba4ee0e6aa0c77f156b84c5228917a.jl:7
│ [11] func_45f10c20d3ba4ee0e6aa0c77f156b84c5228917a()
│ @ Sailhood.AuthenticationController D:\Sailhood\sailhood\build\GenieViews\45f10c20d3ba4ee0e6aa0c77f156b84c5228917a.jl:7
│ [12] (::Sailhood.AuthenticationController.var"#24#28")()
│ @ Sailhood.AuthenticationController D:\Sailhood\sailhood\build\GenieViews\b3b90ef7ee74747b4db93bbbaf6065fe7325a2b0.jl:22
│ [13] #invokelatest#2
│ @ .\essentials.jl:716 [inlined]
│ [14] invokelatest
│ @ .\essentials.jl:714 [inlined]
│ [15] normal_element(f::Function, elem::String, args::Vector{Any}, attrs::Vector{Pair{Symbol, Any}})
│ @ Genie.Renderer.Html C:\Users\chara.julia\packages\Genie\mMGS8\src\renderers\Html.jl:137
│ [16] #body#76
│ @ .\none:2 [inlined]
│ [17] (::Sailhood.AuthenticationController.var"#21#25")()
│ @ Sailhood.AuthenticationController D:\Sailhood\sailhood\build\GenieViews\b3b90ef7ee74747b4db93bbbaf6065fe7325a2b0.jl:10
│ [18] #invokelatest#2
│ @ .\essentials.jl:716 [inlined]
│ [19] invokelatest
│ @ .\essentials.jl:714 [inlined]
│ [20] normal_element(f::Function, elem::String, args::Vector{Any}, attrs::Vector{Pair{Symbol, Any}})
│ @ Genie.Renderer.Html C:\Users\chara.julia\packages\Genie\mMGS8\src\renderers\Html.jl:137
│ [21] #html#64
│ @ .\none:2 [inlined]
│ [22] func_b3b90ef7ee74747b4db93bbbaf6065fe7325a2b0(; context::Module)
│ @ Sailhood.AuthenticationController D:\Sailhood\sailhood\build\GenieViews\b3b90ef7ee74747b4db93bbbaf6065fe7325a2b0.jl:7
│ [23] func_b3b90ef7ee74747b4db93bbbaf6065fe7325a2b0()
│ @ Sailhood.AuthenticationController D:\Sailhood\sailhood\build\GenieViews\b3b90ef7ee74747b4db93bbbaf6065fe7325a2b0.jl:7
│ [24] #invokelatest#2
│ @ .\essentials.jl:716 [inlined]
│ [25] invokelatest
│ @ .\essentials.jl:714 [inlined]
│ [26] Genie.Renderer.WebRenderable(::Function)
│ @ Genie.Renderer C:\Users\chara.julia\packages\Genie\mMGS8\src\Renderer.jl:158
│ [27] |>
│ @ .\operators.jl:966 [inlined]
│ [28] render(::Type{MIME{Symbol("text/html")}}, viewfile::FilePathsBase.WindowsPath; layout::FilePathsBase.WindowsPath, context::Module, vars::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
│ @ Genie.Renderer.Html C:\Users\chara.julia\packages\Genie\mMGS8\src\renderers\Html.jl:475
│ [29] #html#30
│ @ C:\Users\chara.julia\packages\Genie\mMGS8\src\renderers\Html.jl:574 [inlined]
│ [30] html(resource::Symbol, action::Symbol; layout::Symbol, context::Module, status::Int64, headers::Dict{String, String}, vars::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
│ @ Genie.Renderer.Html C:\Users\chara.julia\packages\Genie\mMGS8\src\renderers\Html.jl:486
│ [31] show_login()
│ @ Sailhood.AuthenticationController D:\Sailhood\sailhood\app\resources\authentication\AuthenticationController.jl:16
│ [32] run_route(r::Genie.Router.Route)
│ @ Genie.Router C:\Users\chara.julia\packages\Genie\mMGS8\src\Router.jl:527
│ [33] route_request(req::HTTP.Messages.Request, res::HTTP.Messages.Response)
│ @ Genie.Router C:\Users\chara.julia\packages\Genie\mMGS8\src\Router.jl:169
│ [34] handle_request(req::HTTP.Messages.Request, res::HTTP.Messages.Response)
│ @ Genie.Server C:\Users\chara.julia\packages\Genie\mMGS8\src\Server.jl:269
│ [35] #29
│ @ C:\Users\chara\AppData\Local\Programs\Julia-1.7.3\share\julia\stdlib\v1.7\Distributed\src\macros.jl:123 [inlined]
│ [36] run_work_thunk(thunk::Genie.Server.var"#29#30"{HTTP.Messages.Request, HTTP.Messages.Response}, print_error::Bool)
│ @ Distributed C:\Users\chara\AppData\Local\Programs\Julia-1.7.3\share\julia\stdlib\v1.7\Distributed\src\process_messages.jl:63
│ [37] #remotecall_fetch#158
│ @ C:\Users\chara\AppData\Local\Programs\Julia-1.7.3\share\julia\stdlib\v1.7\Distributed\src\remotecall.jl:454 [inlined]
│ [38] remotecall_fetch
│ @ C:\Users\chara\AppData\Local\Programs\Julia-1.7.3\share\julia\stdlib\v1.7\Distributed\src\remotecall.jl:454 [inlined]
│ [39] #remotecall_fetch#162
│ @ C:\Users\chara\AppData\Local\Programs\Julia-1.7.3\share\julia\stdlib\v1.7\Distributed\src\remotecall.jl:496 [inlined]
│ [40] remotecall_fetch
│ @ C:\Users\chara\AppData\Local\Programs\Julia-1.7.3\share\julia\stdlib\v1.7\Distributed\src\remotecall.jl:496 [inlined]
│ [41] setup_http_listener(req::HTTP.Messages.Request, res::HTTP.Messages.Response)
│ @ Genie.Server C:\Users\chara.julia\packages\Genie\mMGS8\src\Server.jl:296
│ [42] setup_http_listener
│ @ C:\Users\chara.julia\packages\Genie\mMGS8\src\Server.jl:295 [inlined]
│ [43] handle
│ @ C:\Users\chara.julia\packages\HTTP\aTjcj\src\Handlers.jl:254 [inlined]
│ [44] handle(::HTTP.Handlers.RequestHandlerFunction{typeof(Genie.Server.setup_http_listener)}, ::HTTP.Streams.Stream{HTTP.Messages.Request, HTTP.ConnectionPool.Transaction{Sockets.TCPSocket}})
│ @ HTTP.Handlers C:\Users\chara.julia\packages\HTTP\aTjcj\src\Handlers.jl:277
│ [45] setup_http_streamer(http::HTTP.Streams.Stream{HTTP.Messages.Request, HTTP.ConnectionPool.Transaction{Sockets.TCPSocket}})
│ @ Genie.Server C:\Users\chara.julia\packages\Genie\mMGS8\src\Server.jl:285
│ [46] (::Genie.Server.var"#7#14"{Int64})(http::HTTP.Streams.Stream{HTTP.Messages.Request, HTTP.ConnectionPool.Transaction{Sockets.TCPSocket}})
│ @ Genie.Server C:\Users\chara.julia\packages\Genie\mMGS8\src\Server.jl:117
│ [47] macro expansion
│ @ C:\Users\chara.julia\packages\HTTP\aTjcj\src\Servers.jl:415 [inlined]
│ [48] (::HTTP.Servers.var"#13#14"{Genie.Server.var"#7#14"{Int64}, HTTP.ConnectionPool.Transaction{Sockets.TCPSocket}, HTTP.Servers.Server{Nothing, Sockets.TCPServer}, HTTP.Streams.Stream{HTTP.Messages.Request, HTTP.ConnectionPool.Transaction{Sockets.TCPSocket}}})()
│ @ HTTP.Servers .\task.jl:429
│
└ @ Genie.Server C:\Users\chara.julia\packages\Genie\mMGS8\src\Server.jl:308
┌ Error: 2022-07-31 05:27:42 UndefVarError: PARAMS_FLASH_KEY not defined
│ Stacktrace:
│ [1] getproperty
│ @ .\Base.jl:35 [inlined]
│ [2] flash()
│ @ GenieSession.Flash C:\Users\chara.julia\packages\GenieSession\meV9f\src\Flash.jl:18
│ [3] flash_has_message()
│ @ GenieSession.Flash C:\Users\chara.julia\packages\GenieSession\meV9f\src\Flash.jl:41
│ [4] output_flash(flashtype::String) (repeats 2 times)
│ @ Sailhood.ViewHelper D:\Sailhood\sailhood\app\helpers\ViewHelper.jl:8
│ [5] (::Sailhood.AuthenticationController.var"#5#14")()
│ @ Sailhood.AuthenticationController D:\Sailhood\sailhood\build\GenieViews\45f10c20d3ba4ee0e6aa0c77f156b84c5228917a.jl:28
│ [6] #invokelatest#2
│ @ .\essentials.jl:716 [inlined]
│ [7] invokelatest
│ @ .\essentials.jl:714 [inlined]
│ [8] normal_element(f::Function, elem::String, args::Vector{Any}, attrs::Vector{Pair{Symbol, Any}})
│ @ Genie.Renderer.Html C:\Users\chara.julia\packages\Genie\mMGS8\src\renderers\Html.jl:137
│ [9] #span#256
│ @ .\none:2 [inlined]
│ [10] func_45f10c20d3ba4ee0e6aa0c77f156b84c5228917a(; context::Module)
│ @ Sailhood.AuthenticationController D:\Sailhood\sailhood\build\GenieViews\45f10c20d3ba4ee0e6aa0c77f156b84c5228917a.jl:7
│ [11] func_45f10c20d3ba4ee0e6aa0c77f156b84c5228917a()
│ @ Sailhood.AuthenticationController D:\Sailhood\sailhood\build\GenieViews\45f10c20d3ba4ee0e6aa0c77f156b84c5228917a.jl:7
│ [12] (::Sailhood.AuthenticationController.var"#24#28")()
│ @ Sailhood.AuthenticationController D:\Sailhood\sailhood\build\GenieViews\b3b90ef7ee74747b4db93bbbaf6065fe7325a2b0.jl:22
│ [13] #invokelatest#2
│ @ .\essentials.jl:716 [inlined]
│ [14] invokelatest
│ @ .\essentials.jl:714 [inlined]
│ [15] normal_element(f::Function, elem::String, args::Vector{Any}, attrs::Vector{Pair{Symbol, Any}})
│ @ Genie.Renderer.Html C:\Users\chara.julia\packages\Genie\mMGS8\src\renderers\Html.jl:137
│ [16] #body#76
│ @ .\none:2 [inlined]
│ [17] (::Sailhood.AuthenticationController.var"#21#25")()
│ @ Sailhood.AuthenticationController D:\Sailhood\sailhood\build\GenieViews\b3b90ef7ee74747b4db93bbbaf6065fe7325a2b0.jl:10
│ [18] #invokelatest#2
│ @ .\essentials.jl:716 [inlined]
│ [19] invokelatest
│ @ .\essentials.jl:714 [inlined]
│ [20] normal_element(f::Function, elem::String, args::Vector{Any}, attrs::Vector{Pair{Symbol, Any}})
│ @ Genie.Renderer.Html C:\Users\chara.julia\packages\Genie\mMGS8\src\renderers\Html.jl:137
│ [21] #html#64
│ @ .\none:2 [inlined]
│ [22] func_b3b90ef7ee74747b4db93bbbaf6065fe7325a2b0(; context::Module)
│ @ Sailhood.AuthenticationController D:\Sailhood\sailhood\build\GenieViews\b3b90ef7ee74747b4db93bbbaf6065fe7325a2b0.jl:7
│ [23] func_b3b90ef7ee74747b4db93bbbaf6065fe7325a2b0()
│ @ Sailhood.AuthenticationController D:\Sailhood\sailhood\build\GenieViews\b3b90ef7ee74747b4db93bbbaf6065fe7325a2b0.jl:7
│ [24] #invokelatest#2
│ @ .\essentials.jl:716 [inlined]
│ [25] invokelatest
│ @ .\essentials.jl:714 [inlined]
│ [26] Genie.Renderer.WebRenderable(::Function)
│ @ Genie.Renderer C:\Users\chara.julia\packages\Genie\mMGS8\src\Renderer.jl:158
│ [27] |>
│ @ .\operators.jl:966 [inlined]
│ [28] render(::Type{MIME{Symbol("text/html")}}, viewfile::FilePathsBase.WindowsPath; layout::FilePathsBase.WindowsPath, context::Module, vars::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
│ @ Genie.Renderer.Html C:\Users\chara.julia\packages\Genie\mMGS8\src\renderers\Html.jl:475
│ [29] #html#30
│ @ C:\Users\chara.julia\packages\Genie\mMGS8\src\renderers\Html.jl:574 [inlined]
│ [30] html(resource::Symbol, action::Symbol; layout::Symbol, context::Module, status::Int64, headers::Dict{String, String}, vars::Base.Pairs{Symbol, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
│ @ Genie.Renderer.Html C:\Users\chara.julia\packages\Genie\mMGS8\src\renderers\Html.jl:486
│ [31] show_login()
│ @ Sailhood.AuthenticationController D:\Sailhood\sailhood\app\resources\authentication\AuthenticationController.jl:16
│ [32] run_route(r::Genie.Router.Route)
│ @ Genie.Router C:\Users\chara.julia\packages\Genie\mMGS8\src\Router.jl:527
│ [33] route_request(req::HTTP.Messages.Request, res::HTTP.Messages.Response)
│ @ Genie.Router C:\Users\chara.julia\packages\Genie\mMGS8\src\Router.jl:169
│ [34] handle_request(req::HTTP.Messages.Request, res::HTTP.Messages.Response)
│ @ Genie.Server C:\Users\chara.julia\packages\Genie\mMGS8\src\Server.jl:269
│ [35] #29
│ @ C:\Users\chara\AppData\Local\Programs\Julia-1.7.3\share\julia\stdlib\v1.7\Distributed\src\macros.jl:123 [inlined]
│ [36] run_work_thunk(thunk::Genie.Server.var"#29#30"{HTTP.Messages.Request, HTTP.Messages.Response}, print_error::Bool)
│ @ Distributed C:\Users\chara\AppData\Local\Programs\Julia-1.7.3\share\julia\stdlib\v1.7\Distributed\src\process_messages.jl:63
│ [37] #remotecall_fetch#158
│ @ C:\Users\chara\AppData\Local\Programs\Julia-1.7.3\share\julia\stdlib\v1.7\Distributed\src\remotecall.jl:454 [inlined]
│ [38] remotecall_fetch
│ @ C:\Users\chara\AppData\Local\Programs\Julia-1.7.3\share\julia\stdlib\v1.7\Distributed\src\remotecall.jl:454 [inlined]
│ [39] #remotecall_fetch#162
│ @ C:\Users\chara\AppData\Local\Programs\Julia-1.7.3\share\julia\stdlib\v1.7\Distributed\src\remotecall.jl:496 [inlined]
│ [40] remotecall_fetch
│ @ C:\Users\chara\AppData\Local\Programs\Julia-1.7.3\share\julia\stdlib\v1.7\Distributed\src\remotecall.jl:496 [inlined]
│ [41] setup_http_listener(req::HTTP.Messages.Request, res::HTTP.Messages.Response)
│ @ Genie.Server C:\Users\chara.julia\packages\Genie\mMGS8\src\Server.jl:296
│ [42] setup_http_listener
│ @ C:\Users\chara.julia\packages\Genie\mMGS8\src\Server.jl:295 [inlined]
│ [43] handle
│ @ C:\Users\chara.julia\packages\HTTP\aTjcj\src\Handlers.jl:254 [inlined]
│ [44] handle(::HTTP.Handlers.RequestHandlerFunction{typeof(Genie.Server.setup_http_listener)}, ::HTTP.Streams.Stream{HTTP.Messages.Request, HTTP.ConnectionPool.Transaction{Sockets.TCPSocket}})
│ @ HTTP.Handlers C:\Users\chara.julia\packages\HTTP\aTjcj\src\Handlers.jl:277
│ [45] setup_http_streamer(http::HTTP.Streams.Stream{HTTP.Messages.Request, HTTP.ConnectionPool.Transaction{Sockets.TCPSocket}})
│ @ Genie.Server C:\Users\chara.julia\packages\Genie\mMGS8\src\Server.jl:285
│ [46] (::Genie.Server.var"#7#14"{Int64})(http::HTTP.Streams.Stream{HTTP.Messages.Request, HTTP.ConnectionPool.Transaction{Sockets.TCPSocket}})
│ @ Genie.Server C:\Users\chara.julia\packages\Genie\mMGS8\src\Server.jl:117
│ [47] macro expansion
│ @ C:\Users\chara.julia\packages\HTTP\aTjcj\src\Servers.jl:415 [inlined]
│ [48] (::HTTP.Servers.var"#13#14"{Genie.Server.var"#7#14"{Int64}, HTTP.ConnectionPool.Transaction{Sockets.TCPSocket}, HTTP.Servers.Server{Nothing, Sockets.TCPServer}, HTTP.Streams.Stream{HTTP.Messages.Request, HTTP.ConnectionPool.Transaction{Sockets.TCPSocket}}})()
│ @ HTTP.Servers .\task.jl:429
│
└ @ Genie.Server C:\Users\chara.julia\packages\Genie\mMGS8\src\Server.jl:308
The text was updated successfully, but these errors were encountered: