View Source Changelog
0-16-0-2023-03-21
[0.16.0] - 2023-03-21
added
Added
- Convert
Ecto.Query.CastError
inRepo.fetch_by/3
& friends to:not_found
errors. Opt-out viaraise_cast_error
option.
0-15-0-2023-02-13
[0.15.0] - 2023-02-13
added-1
Added
- Give
Repo.fetch_by/2
,Repo.count/1
, andAssertions.assert_count_difference/4
an optionalopts
parameter that is forwarded to the underlying Ecto function. Useful to pass query options like:prefix
.
0-14-0-2023-01-03
[0.14.0] - 2023-01-03
added-2
Added
- Changed
Repo.fetch/2
andRepo.fetch/3
to work with primary key with name other thanid
.
0-13-2-2022-12-19
[0.13.2] - 2022-12-19
- Add
error_tag
option toBitcrowdEcto.Repo.fetch_by/3
and friends to allow overriding the queryable in the error result.
0-13-1-2022-09-21
[0.13.1] - 2022-09-21
fixed
Fixed
- Fix dependency specifications by restoring the
:only
options and explicitly listing conflicting packages. See https://github.com/kipcole9/money/issues/142 for explanation.
0-13-0-2022-09-14
[0.13.0] - 2022-09-14
NOTE: 0.13.0 needed to be retired due to a corrupt dependency tree listing all dev/test dependencies as prod dependencies.
- Add
BitcrowdEcto.Changeset.validate_money/3
for validatingMoney
values fromex_money
, which is introduced as an optional dependency.
0-12-0-2022-06-21
[0.12.0] - 2022-06-21
added-3
Added
- Add
BitcrowdEcto.DateTime.beginning_of_month/1
. - Add
BitcrowdEcto.DateTime.beginning_of_last_month/1
. - Add
BitcrowdEcto.DateTime.beginning_of_next_month/1
. - Add
BitcrowdEcto.DateTime.beginning_of_yesterday/1
. - Add
BitcrowdEcto.DateTime.beginning_of_tomorrow/1
.
0-11-0-2022-06-09
[0.11.0] - 2022-06-09
- Add
BitcrowdEcto.Changeset.validate_date_after/3
Validates a date field in the changeset is after the given reference date. - Add
BitcrowdEcto.Changeset.validate_hex_color/2
validates a changeset field has hexadecimal color format. - Add
BitcrowdEcto.Assertions.assert_changeset_valid/1
. - Add
BitcrowdEcto.Assertions.refute_changeset_valid/1
.
0-10-0-2022-04-28
[0.10.0] - 2022-04-28
added-4
Added
- New
BitcrowdEcto.Assertions.assert_*_constraint_on/2
matchers assert on constraints on changesets without going to the database. - Add
BitcrowdEcto.DateTime.shift/2
andBitcrowdEcto.DateTime.beginning_of_day/1
.
changed
Changed
- BREAKING: Stopped
inspect
ing thefrom
/to
fields invalidate_transition/3
error details. Previously atom columns (e.g. fromEcto.Enum
) would result in[from: ":foo", to: ":bar"]
error details, now these atoms are inserted unchanged as[from: :foo, to: :bar]
- BREAKING: Removed
:field
fromvalidate_transition/3
error details as it is redundant with the error field. - Deprecated
BitcrowdEcto.Assertions.assert_foreign_constraint_error_on/2
in favour of newassert_foreign_key_constraint_error_on/2
. Constraint assert functions are all called after theEcto.Changeset.*_constraint
functions now, not after internal error type names.
0-9-0-2022-03-25
[0.9.0] - 2022-03-25
added-5
Added
Add
BitcrowdEcto.Assertions.assert_change_to_almost_now/2
to assert that the value of a datetime field changed to the present time.Add
BitcrowdEcto.Schema.to_enum_member/3
andBitcrowdEcto.Schema.to_enum_member!/3
, functions that safely convert a string to the member of an enum based on reflection on the given schema.
changed-1
Changed
- BREAKING: Add
:only_web
option toBitcrowdEcto.Changeset.validate_email/3
that enforces a dot in the host part of the email address (e.g.foo@example.net
is valid,foo@example
is not). Defaults to true.
0-8-0-2022-03-03
[0.8.0] - 2022-03-03
changed-2
Changed
- BREAKING: Drop the
BitcrowdEcto.Migration.grant_dml_privileges_on_schema/2
variant that reads from a configuration variable. However, the keyword list ongrant_dml_privileges_on_schema/3
has become optional, so effectively there is a different/2
now.
0-7-0-2022-03-02
[0.7.0] - 2022-03-02
added-6
Added
- Add
BitcrowdEcto.Migration
for migration utilities, first util isgrant_dml_privileges_on_schema/2
thatGRANT
s certain privileges to a Postgres role.
0-6-0-2022-02-10
[0.6.0] - 2022-02-10
added-7
Added
- Add
BitcrowdEcto.Random
containing various random token generators. - Add
validate_past_datetime/3
,validate_future_datetime/3
,validate_datetime_after/4
,validate_date_order/4
,validate_datetime_order/4
andvalidate_order/5
toBitcrowdEcto.Changeset
.
0-5-0-2022-02-04
[0.5.0] - 2022-02-04
added-8
Added
- Add
Migrator.ensure_up!/0
to check whether all migrations are up.
0-4-0-2022-01-28
[0.4.0] - 2022-01-28
added-9
Added
- Add
handle_migrator_exception/2
callback toMigrator
to allow exception reporting.
0-3-1-2022-01-17
[0.3.1] - 2022-01-17
added-10
Added
- Add missing
assert_sorted_equal/3
.
0-3-0-2022-01-17
[0.3.0] - 2022-01-17
added-11
Added
- Add
assert_almost_now/1
,assert_almost_coincide/3
andassert_sorted_equal/2
toBitcrowdEcto.Assertions
.
0-2-0-2022-01-17
[0.2.0] - 2022-01-17
added-12
Added
0-1-0-2022-01-07
[0.1.0] - 2022-01-07
Initial release to the public 🎉