Skip to content
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

Unexpected "endspaceless" tag (expecting closing tag for the "apply" tag defined near line 24). #159

Open
picks44 opened this issue Jan 13, 2020 · 9 comments

Comments

@picks44
Copy link

picks44 commented Jan 13, 2020

Hi, since upgrade to v2.1.32, I get this error :

Unexpected "endspaceless" tag (expecting closing tag for the "apply" tag defined near line 24).

Twig\Error\
SyntaxError
in app\Resources\views\jquery.collection.html.twig (line 32)
        {% endif %}        {% set attr = attr|merge({'data-allow-add': allow_add ? 1 : 0}) %}        {% set attr = attr|merge({'data-allow-remove': allow_delete ? 1 : 0 }) %}        {% set attr = attr|merge({'data-name-prefix': full_name}) %}        {{ block('form_widget') }}    {% endspaceless %}{% endblock collection_widget %}

I guess jquery.collection.html.twig should be updated to

{% block collection_widget %}
    {% apply spaceless %}
        {% if prototype is defined %}
            {% set attr = attr|merge({'data-prototype': form_row(prototype)}) %}
            {% set attr = attr|merge({'data-prototype-name': prototype.vars.name}) %}
        {% endif %}
        {% set attr = attr|merge({'data-allow-add': allow_add ? 1 : 0}) %}
        {% set attr = attr|merge({'data-allow-remove': allow_delete ? 1 : 0 }) %}
        {% set attr = attr|merge({'data-name-prefix': full_name}) %}
        {{ block('form_widget') }}
    {% endapply %} #Update this line
{% endblock collection_widget %}
@ninsuo
Copy link
Owner

ninsuo commented Jan 13, 2020

Hello,

2.1.32 should be fixing the issue:
2.1.32...master

Have a good day
Alain

@picks44
Copy link
Author

picks44 commented Jan 13, 2020

Hi @ninsuo and thanks. Could you merge it to the master branch? Otherwise I'll have to specify this particular branch '2.1.32' to have the fix.
Thanks!

@ninsuo
Copy link
Owner

ninsuo commented Jan 13, 2020

Sure, having a look right now

@ninsuo
Copy link
Owner

ninsuo commented Jan 13, 2020

Could you please try using 2.1.33 ?
Thanks

@picks44
Copy link
Author

picks44 commented Jan 13, 2020

For some reason I can't install it...

I'm declaring the package like this in my composer,json "ninsuo/symfony-collection": "^2.1",

and a composer update doesn't update to 2.1.33, and if I try to "force the version "ninsuo/symfony-collection": "2.1.33", I get the following error

 The requested package ninsuo/symfony-collection 2.1.33 exists as ninsuo/symfony-collection[2.0.0, 2.0.1, 2.0.2, 2.0.3, 2.0.4, 2.0.5, 2.1.0, 2.1.1, 2.1.10, 2.1.11, 2.1.12, 2.1.13, 2.1.14, 2.1.15, 2.1.16, 2.1.17, 2.1.18, 2.1.19, 2.1.2, 2.1.20, 2.1.21, 2.1.22, 2
.1.23, 2.1.24, 2.1.25, 2.1.26, 2.1.27, 2.1.28, 2.1.29, 2.1.3, 2.1.30, 2.1.31, 2.1.32, 2.1.4, 2.1.5, 2.1.6, 2.1.7, 2.1.8, 2.1.9, dev-master, dev-preparing-3.0] but these are rejected by your constraint.

@picks44
Copy link
Author

picks44 commented Jan 14, 2020

And composer require ninsuo/symfony-collection 2.1.33 gives me

  [InvalidArgumentException]                                                     
  Could not find package ninsuo/symfony-collection in a version matching 2.1.33 

@ninsuo
Copy link
Owner

ninsuo commented Jan 14, 2020

Hello,

Please try again.

Sorry for the inconvenience, it seems that my git hook stopped working on Packagist.

Cheers

@picks44
Copy link
Author

picks44 commented Jan 14, 2020

OK, looks like I finally manged to install it using the dev-master tag.
Working like a charm again now, you can safely release 2.1.33 IMO :)

@bastien70
Copy link

Hello, some news about this release ? I can't install it properly with npm update, same error

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants