Justin Li
ffb0ace303
Update changelog for 4.0.0
2016-12-16 13:11:22 -05:00
Florian Weingarten
ad00998ef8
bump to v4
v4.0.0
2016-12-14 11:58:42 -05:00
Dylan Thacker-Smith
869dbc7ebf
feature: Allow a default exception renderer to be specified ( #837 )
...
This could be used to preserve the old default of rendering
non-Liquid::Error messages or for providing default behaviour like error
reporting which could be missed if the exception renderer needed to be
specified on each render.
2016-12-12 10:29:09 -05:00
Dylan Thacker-Smith
fae3a2de7b
Add version constraint to rake to fix CI ( #836 )
2016-12-09 14:01:15 -05:00
Dylan Thacker-Smith
f27bd619b9
change: Render an opaque internal error by default for non-Liquid::Error ( #835 )
...
These errors may contain sensitive information, so is safer to
render a more vague message by default.
This is done by replacing non-Liquid::Error exceptions with a
Liquid::InternalError exception with the non-Liquid::Error accessible on
through the cause method. This also allows the template name and line
number to be attached to the template errors.
The exception_handler render option has been changed to exception_renderer
since now it should raise an exception to re-raise on a liquid rendering
error or return a string to be rendered where the error occurred.
2016-12-07 17:34:29 -05:00
Dylan Thacker-Smith
a9b84b7806
test: Use ruby 2.1 in Circle CI
2016-12-05 15:36:42 -05:00
Dylan Thacker-Smith
6cc2c567c5
Merge pull request #832 from Shopify/drop-ruby-2.0
...
Drop support for ruby 2.0
2016-12-05 13:56:15 -05:00
Dylan Thacker-Smith
812e3c51b9
test: Add ruby 2.3.3 to CI
...
Travis doesn't have a ruby 2.3 alias, so the latest 2.3.x version is
specified instead.
2016-12-05 13:53:02 -05:00
Dylan Thacker-Smith
9dd0801f5c
Drop support for ruby 2.0
...
It is no longer maintained upstream
2016-12-05 13:51:49 -05:00
Dylan Thacker-Smith
b146b49f46
fix: Clear the strainer cache when a global filter is added ( #826 )
2016-11-24 10:32:11 -05:00
Richard Monette
86944fe7b7
Merge pull request #809 from Shopify/introduce-unhandled-liquid-exception
...
introduce unhandled liquid exception
2016-10-31 10:20:06 -04:00
Richard Monette
a549d289d7
introduce unhandled liquid exception
...
check arity
2016-10-28 09:40:44 -04:00
Richard Monette
b2feeacbce
Merge pull request #812 from Shopify/allow-split-to-accept-numeric
...
allow split to accept numeric
2016-10-26 10:59:44 -04:00
Richard Monette
143ba39a08
allow split to accept numeric
2016-10-26 10:43:04 -04:00
Richard Monette
43e59796f6
Merge pull request #805 from Shopify/dont-explode-when-sorting-nil-property
...
dont explode when sorting nil property
2016-10-05 10:18:16 -04:00
Richard Monette
bb3624b799
dont explode when sorting nil property
2016-10-04 13:22:29 -04:00
Konstantin Tennhard
64fca66ef5
Merge pull request #797 from Shopify/truncatewords-resiliency
...
Standard filter truncate / truncatewords: force truncate_string to string
2016-09-13 10:43:55 -04:00
Florian Weingarten
e9d7486758
4.0.0.rc3
v4.0.0.rc3
2016-09-13 06:33:20 -04:00
Philibert Dugas
2bb98c1431
Merge pull request #798 from PhilibertDugas/bugfix-#697
...
Fixing #697 with better exception
2016-09-12 13:53:22 -04:00
Konstantin Tennhard
95d5c24bfc
Standard filter truncate: truncate_string string coercion
...
The argument `truncate_string` is now coerced into a string to avoid
`NoMethodError`s. This is mostly for added resiliency. It is doubtful
that someone would actually intent to use a number as truncate string,
but accidentally supplying one is entirely possible.
2016-09-12 12:13:12 -04:00
Philibert Dugas
b7ee1a2176
Fixing #697 with better exception
...
When including a template which is not defined, the exception raised is
*undefined method `split` for nil:NilClass*
This occurs for a scenario like the following:
`{% include nil %}`
or
`{% include undefined-var %}`
Making the code raise an argument error to allow better understanding of
the include error
2016-09-12 09:31:59 -04:00
Florian Weingarten
0eca61a977
Merge pull request #799 from kainjow/patch-1
...
Update liquid-c
2016-09-12 08:12:14 -04:00
Kevin Wojniak
9bfd04da2d
Update liquid-c
2016-09-10 09:23:15 -07:00
Konstantin Tennhard
302185a7fc
Standard filter truncatewords: force truncate_string to string
...
Currently, `truncatewords` raises a TypeError when the argument
`truncate_string` is an interger. This PR forces string coercion for any
value provided for this argument. Thus,
```ruby
assert_equal 'one two1', @filters.truncatewords("one two three", 2, 1)
```
holds true. Another option would be to raise a `Liquid::ArgumentError`.
What is preferred?
2016-09-09 16:50:50 -04:00
Florian Weingarten
50c85afc35
Merge pull request #786 from Shopify/bump-liquid-c
...
Bump LiquidC for whitespace changes
2016-08-11 13:38:42 -04:00
Florian Weingarten
5876dff326
Bump LiquidC for whitespace changes
2016-08-11 13:21:39 -04:00
Florian Weingarten
f25185631d
Merge pull request #773 from evulse/whitespace-trim
...
Add whitespace control character and associated tests
2016-08-11 13:20:12 -04:00
Michael Angell
283f1bad18
Use .last instead of pop push method for updating last node in nodelist
2016-07-08 20:49:30 +10:00
Michael Angell
e1d40c7d89
Add whitespace control character and associated tests
2016-06-28 09:15:45 +10:00
Justin Li
19c6eb426a
Merge pull request #769 from zacstewart/patch-1
...
Fix doc formatting of code examples in file_system
2016-06-15 17:10:11 -04:00
Zac Stewart
f87b06095d
Fix doc formatting of code examples in file_system
...
These code examples are being rendered as paragraph text in the docs.
2016-06-15 15:34:14 -04:00
Gaurav Chande
b81d54e789
Merge pull request #761 from Shopify/range-to_liquid
...
Support Range Type
2016-06-02 16:48:30 -04:00
Gaurav Chande
00f53b16e8
Prevent Range usage in templates from blowing up
2016-06-02 16:38:44 -04:00
Gaurav Chande
e4cf55b112
Merge pull request #748 from Shopify/expose-tags
...
Make Template.tags loop-able
2016-04-25 11:59:37 -04:00
Gaurav Chande
5bb211d933
Ensure no tag leakage since registry is global
2016-04-25 11:50:46 -04:00
Gaurav Chande
6adc431a19
Make tag registry enumerable
2016-04-25 11:38:42 -04:00
Justin Li
23d2beed41
Merge pull request #744 from Shopify/raw-syntax-method
...
Make markup validation a method on Liquid::Raw
2016-04-13 17:08:02 -04:00
Drew Martin
a80ecb7678
make markup validation a method on Liquid::Raw
2016-04-13 14:52:30 -04:00
Florian Weingarten
361c695264
Merge pull request #736 from Shopify/abs-filter
...
Abs filter
2016-04-05 09:13:56 -04:00
Florian Weingarten
f93243cc1a
abs filter
2016-04-04 09:32:31 -04:00
Florian Weingarten
1e533a52e7
Merge pull request #735 from Shopify/fix-to-number-for-negative-float-strings
...
Fix to_number filter for negative float strings
v4.0.0.rc2
2016-03-31 15:52:51 -04:00
Dylan Thacker-Smith
3ea84f095f
Merge pull request #734 from Shopify/concat-liquid-error
...
Raise a Liquid::Error when a non-array is passed into the concat filter.
2016-03-31 15:47:43 -04:00
Dylan Thacker-Smith
4239c899a4
Raise a Liquid::Error when a non-array is passed into the concat filter.
2016-03-31 15:47:06 -04:00
Florian Weingarten
1597f8859f
Fix to_number filter for negative float strings
2016-03-31 09:18:55 -04:00
Florian Weingarten
b3dda384c9
Merge pull request #733 from Shopify/fix-some-ruby-warnings
...
Fix a bunch of Ruby warnings
2016-03-30 17:09:00 -04:00
Florian Weingarten
6828670bfe
Merge pull request #732 from Shopify/v400rc2
...
Release v4.0.0rc2
2016-03-30 17:02:34 -04:00
Florian Weingarten
d2f16d92d6
Fix a bunch of Ruby warnings
2016-03-30 20:42:30 +00:00
Justin Li
d233acb483
Update history to reflect merge of #731
2016-03-30 16:36:57 -04:00
Florian Weingarten
8920e2a2a2
Release v4.0.0rc2
2016-03-30 20:13:21 +00:00
Justin Li
bfee507005
Merge pull request #731 from ismasan/duck_typed_maths_filters
...
Duck typed maths filters
2016-03-30 16:09:16 -04:00