-
Notifications
You must be signed in to change notification settings - Fork 156
Conversation
[Semantical Error] The annotation "@template" in method Acme\BasicCmsBundle\Controller\DefaultController::pageAction() was never imported. Did you maybe forget to add a "use" statement for this annotation? Yes we did :-) Also, running http://localhost:8000/page/home for the first time didn't work. I got an error about routes and the /Document/Page The error was on line 6 on the page.html.twig file, without {{ path( post) }} it worked. Very strange, suddenly it worked. Some caching stuff? (sorry, I don't have the exact error message, I can't reproduce it anymore)
If you had followed the complete tutorial from page 1, you had created the bundle using:
In this case, the format is defaulted to "annotation" and you'll get this use statement in your default controller automatically. However, now I don't think we can assume people are reading the complete tutorial. So +1 for this change. Could you please add a new line between the use statement and the controller, after that we can merge it imo. |
+1 for "redundancy" in this case. |
I've read the whole tutorial, but I prefer the yaml configuration, see: I've added the new line between the use statement and the controller |
@@ -97,8 +97,10 @@ Now create the action in the default controller - you can pass the ``Page`` | |||
object and all the ``Posts`` to the view:: | |||
|
|||
// src/Acme/BasicCmsBundle/Controller/DefaultController.php | |||
|
|||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sorry to say but this should not have unneeded blanks here. can you fix that and then squash your commits?
(i configure my editors to remove all trailing whitespace on save)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Eh, I'm confused: #577 (comment)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You've added spaces on an empty line. You should remove the spaces, but keep the blank line
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Aah ok, I wasn't aware, sorry
thanks a lot. i squashed the commits and removed another case of unnecessary blanks in 7ae794b, then merged manually. |
[Semantical Error] The annotation "@template" in method Acme\BasicCmsBundle\Controller\DefaultController::pageAction() was never imported. Did you maybe forget to add a "use" statement for this annotation?
Yes we did :-)
Also, running http://localhost:8000/page/home for the first time didn't work. I got an error about routes and the /Document/Page
The error was on line 6 on the page.html.twig file, without {{ path( post) }} it worked. Very strange, suddenly it worked. Some caching stuff?
(sorry, I don't have the exact error message, I can't reproduce it anymore)