Comments (7)
I've published the new version 0.4.2 that includes this fix.
from filtrex.
Do you have a stack trace that you can post here that includes the error no with clause matching...
?
from filtrex.
@rcdilorenzo Thanks for the prompt response.
If I remove the handling of
{:error, error} -> render_error(conn, error, privileged_candidate_path(conn, :index, access_id: access_id))
following error shows up:
[debug] Processing with MyApp.Privileged.CandidateController.index/2
Parameters: %{"access_id" => "1ae51ba3-ee00-70b9-bc4a-57e99aaaf05b", "page" => "3", "status_equals" => "2"}
Pipelines: [:browser, :privileged]
[debug] QUERY OK source="batches" db=6.8ms
...query...
[info] Sent 500 in 1518ms
[error] #PID<0.2676.0> running MyApp.Endpoint (cowboy_protocol) terminated
Server: localhost:5000 (http)
Request: GET /privileged/candidates?access_id=1ae51ba3-ee00-70b9-bc4a-57e99aaaf05b&page=3&status_equals=2
** (exit) an exception was raised:
** (WithClauseError) no with clause matching: {:error, "Invalid number value for '2'"}
(pcms) lib/pcms_web/controllers/privileged/candidate_controller.ex:17: MyApp.Privileged.CandidateController.index/3
(pcms) lib/pcms_web/controllers/privileged/candidate_controller.ex:1: MyApp.Privileged.CandidateController.action/2
(pcms) lib/pcms_web/controllers/privileged/candidate_controller.ex:1: MyApp.Privileged.CandidateController.phoenix_controller_pipeline/2
(pcms) lib/pcms_web/endpoint.ex:1: MyApp.Endpoint.instrument/4
(phoenix) lib/phoenix/router.ex:278: Phoenix.Router.__call__/1
(pcms) lib/plug/error_handler.ex:64: MyApp.Router.call/2
(pcms) lib/pcms_web/endpoint.ex:1: MyApp.Endpoint.plug_builder_call/2
(pcms) lib/plug/debugger.ex:102: MyApp.Endpoint."call (overridable 3)"/2
(pcms) lib/pcms_web/endpoint.ex:1: MyApp.Endpoint.call/2
(plug) lib/plug/adapters/cowboy/handler.ex:16: Plug.Adapters.Cowboy.Handler.upgrade/4
(cowboy) /Users/gorav/Work/Solutionize/projects/pcms/deps/cowboy/src/cowboy_protocol.erl:442: :cowboy_protocol.execute/4
If I retain handling of the error in the code, error message flashes on the page
Invalid number value for '2'
Let me know if you need any further details.
from filtrex.
looks like this is re-surfacing #49
from filtrex.
@rcdilorenzo just realized that above fix is not part of the latest release. using master branch seems to have fixed the issue. exploring further.
would it be possible to release a new version with the fix so that somebody else trying the library doesnt land up in same situation. I wasted couple of hours trying to figure out if there was an issue with my setup and then moving on to explore other libraries.
from filtrex.
Absolutely. I apologize for the inconvenience. I'll try to do a release on Monday if I can. I didn't have that PR in the GitHub Project tab so I thought everything was up-to-date.
from filtrex.
@rcdilorenzo thanks for the wonderful library and prompt responses. may be couple of url examples would help new users. I will try to raise a PR once I get better understanding.
from filtrex.
Related Issues (20)
- Ambiguous column error when filtering on query with joins HOT 1
- Rename methods like parse!/2 to be safe_parse/2
- Make error formats consistent
- Create dump/1 for saving filters HOT 3
- Upgrade hex release HOT 2
- Different ecto schema field name from the parameter name HOT 2
- Release v0.4.1
- Integer validation always fails
- ignore blank strings in numeric filters HOT 7
- join fields for filtering HOT 3
- make text search more flexible HOT 2
- Filter on associations? HOT 9
- Updating to ecto 3.0 HOT 1
- Create Filtrex Ecto Type
- Add support for nil on datetime fields HOT 2
- question: if you had considered double underscores HOT 2
- When a new release will be rolled out? HOT 2
- Error (Elixir 1.11.0) HOT 1
- DateTime not working with between condition
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 filtrex.