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

[BUG] Running quarkus:dev fails with date format error #7

Closed
ksilz opened this issue Jan 24, 2023 · 14 comments · Fixed by #8
Closed

[BUG] Running quarkus:dev fails with date format error #7

ksilz opened this issue Jan 24, 2023 · 14 comments · Fixed by #8

Comments

@ksilz
Copy link

ksilz commented Jan 24, 2023

The latest commit on master gives me this error when running mvn clean compile quarkus:dev:

$ mvn clean compile quarkus:dev
[INFO] Scanning for projects...
[INFO]
[INFO] ----------< org.quarkus.samples.petclinic:quarkus-petclinic >-----------
[INFO] Building quarkus-petclinic 1.0.0-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]

[...]

2023-01-24 13:28:48,494 INFO  [io.qua.dat.dep.dev.DevServicesDatasourceProcessor] (build-40) Dev Services for the default datasource (postgresql) started - container ID is 98678c40453e
2023-01-24 13:28:52,317 INFO  [io.qua.kub.cli.dep.DevServicesKubernetesProcessor] (build-52) Dev Services for Kubernetes started. Other Quarkus applications in dev mode will find the cluster automatically.
2023-01-24 13:28:52,319 INFO  [io.qua.dep.dev.IsolatedDevModeMain] (main) Attempting to start live reload endpoint to recover from previous Quarkus startup failure
2023-01-24 13:28:52,497 ERROR [io.qua.dep.dev.IsolatedDevModeMain] (main) Failed to start quarkus: java.lang.RuntimeException: io.quarkus.builder.BuildException: Build failure: Build failed due to errors
	[error]: Build step io.quarkus.qute.deployment.QuteProcessor#processTemplateErrors threw an exception: io.quarkus.qute.TemplateException: Found incorrect expressions (4):
	[1] ownerDetails.html:45:17 - {pet.birthDate.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method
	[2] ownerDetails.html:65:19 - {visit.date.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method
	[3] createOrUpdateVisitForm.html:20:13 - {pet.birthDate.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method
	[4] createOrUpdateVisitForm.html:77:13 - {v.date.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method

	at io.quarkus.qute.deployment.QuteProcessor.processTemplateErrors(QuteProcessor.java:238)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
	at io.quarkus.deployment.ExtensionLoader$3.execute(ExtensionLoader.java:909)
	at io.quarkus.builder.BuildContext.run(BuildContext.java:281)
	at org.jboss.threads.ContextHandler$1.runWith(ContextHandler.java:18)
	at org.jboss.threads.EnhancedQueueExecutor$Task.run(EnhancedQueueExecutor.java:2449)
	at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1478)
	at java.base/java.lang.Thread.run(Thread.java:833)
	at org.jboss.threads.JBossThread.run(JBossThread.java:501)
	Suppressed: io.quarkus.qute.TemplateException: ownerDetails.html:45:17 - {pet.birthDate.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method
		at io.quarkus.qute.TemplateException$Builder.build(TemplateException.java:169)
		at io.quarkus.qute.deployment.QuteProcessor.processTemplateErrors(QuteProcessor.java:215)
		... 11 more
	Suppressed: io.quarkus.qute.TemplateException: ownerDetails.html:65:19 - {visit.date.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method
		at io.quarkus.qute.TemplateException$Builder.build(TemplateException.java:169)
		at io.quarkus.qute.deployment.QuteProcessor.processTemplateErrors(QuteProcessor.java:215)
		... 11 more
	Suppressed: io.quarkus.qute.TemplateException: createOrUpdateVisitForm.html:20:13 - {pet.birthDate.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method
		at io.quarkus.qute.TemplateException$Builder.build(TemplateException.java:169)
		at io.quarkus.qute.deployment.QuteProcessor.processTemplateErrors(QuteProcessor.java:215)
		... 11 more
	Suppressed: io.quarkus.qute.TemplateException: createOrUpdateVisitForm.html:77:13 - {v.date.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method
		at io.quarkus.qute.TemplateException$Builder.build(TemplateException.java:169)
		at io.quarkus.qute.deployment.QuteProcessor.processTemplateErrors(QuteProcessor.java:215)
		... 11 more

	at io.quarkus.runner.bootstrap.AugmentActionImpl.runAugment(AugmentActionImpl.java:335)
	at io.quarkus.runner.bootstrap.AugmentActionImpl.createInitialRuntimeApplication(AugmentActionImpl.java:252)
	at io.quarkus.runner.bootstrap.AugmentActionImpl.createInitialRuntimeApplication(AugmentActionImpl.java:60)
	at io.quarkus.deployment.dev.IsolatedDevModeMain.firstStart(IsolatedDevModeMain.java:86)
	at io.quarkus.deployment.dev.IsolatedDevModeMain.accept(IsolatedDevModeMain.java:447)
	at io.quarkus.deployment.dev.IsolatedDevModeMain.accept(IsolatedDevModeMain.java:59)
	at io.quarkus.bootstrap.app.CuratedApplication.runInCl(CuratedApplication.java:149)
	at io.quarkus.bootstrap.app.CuratedApplication.runInAugmentClassLoader(CuratedApplication.java:104)
	at io.quarkus.deployment.dev.DevModeMain.start(DevModeMain.java:131)
	at io.quarkus.deployment.dev.DevModeMain.main(DevModeMain.java:62)
Caused by: io.quarkus.builder.BuildException: Build failure: Build failed due to errors
	[error]: Build step io.quarkus.qute.deployment.QuteProcessor#processTemplateErrors threw an exception: io.quarkus.qute.TemplateException: Found incorrect expressions (4):
	[1] ownerDetails.html:45:17 - {pet.birthDate.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method
	[2] ownerDetails.html:65:19 - {visit.date.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method
	[3] createOrUpdateVisitForm.html:20:13 - {pet.birthDate.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method
	[4] createOrUpdateVisitForm.html:77:13 - {v.date.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method

	at io.quarkus.qute.deployment.QuteProcessor.processTemplateErrors(QuteProcessor.java:238)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
	at io.quarkus.deployment.ExtensionLoader$3.execute(ExtensionLoader.java:909)
	at io.quarkus.builder.BuildContext.run(BuildContext.java:281)
	at org.jboss.threads.ContextHandler$1.runWith(ContextHandler.java:18)
	at org.jboss.threads.EnhancedQueueExecutor$Task.run(EnhancedQueueExecutor.java:2449)
	at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1478)
	at java.base/java.lang.Thread.run(Thread.java:833)
	at org.jboss.threads.JBossThread.run(JBossThread.java:501)
	Suppressed: io.quarkus.qute.TemplateException: ownerDetails.html:45:17 - {pet.birthDate.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method
		at io.quarkus.qute.TemplateException$Builder.build(TemplateException.java:169)
		at io.quarkus.qute.deployment.QuteProcessor.processTemplateErrors(QuteProcessor.java:215)
		... 11 more
	Suppressed: io.quarkus.qute.TemplateException: ownerDetails.html:65:19 - {visit.date.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method
		at io.quarkus.qute.TemplateException$Builder.build(TemplateException.java:169)
		at io.quarkus.qute.deployment.QuteProcessor.processTemplateErrors(QuteProcessor.java:215)
		... 11 more
	Suppressed: io.quarkus.qute.TemplateException: createOrUpdateVisitForm.html:20:13 - {pet.birthDate.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method
		at io.quarkus.qute.TemplateException$Builder.build(TemplateException.java:169)
		at io.quarkus.qute.deployment.QuteProcessor.processTemplateErrors(QuteProcessor.java:215)
		... 11 more
	Suppressed: io.quarkus.qute.TemplateException: createOrUpdateVisitForm.html:77:13 - {v.date.format('yyyy-MM-ddoperty/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method
		at io.quarkus.qute.TemplateException$Builder.build(TemplateException.java:169)
		at io.quarkus.qute.deployment.QuteProcessor.processTemplateErrors(QuteProcessor.java:215)
		... 11 more

	at io.quarkus.builder.Execution.run(Execution.java:123)
	at io.quarkus.builder.BuildExecutionBuilder.execute(BuildExecutionBuilder.java:79)
	at io.quarkus.deployment.QuarkusAugmentor.run(QuarkusAugmentor.java:160)
	at io.quarkus.runner.bootstrap.AugmentActionImpl.runAugment(AugmentActionImpl.java:331)
	... 9 more
Caused by: io.quarkus.qute.TemplateException: Found incorrect expressions (4):
	[1] ownerDetails.html:45:17 - {pet.birthDate.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method
	[2] ownerDetails.html:65:19 - {visit.date.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method
	[3] createOrUpdateVisitForm.html:20:13 - {pet.birthDate.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method
	[4] createOrUpdateVisitForm.html:77:13 - {v.date.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method

	at io.quarkus.qute.deployment.QuteProcessor.processTemplateErrors(QuteProcessor.java:238)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
	at io.quarkus.deployment.ExtensionLoader$3.execute(ExtensionLoader.java:909)
	at io.quarkus.builder.BuildContext.run(BuildContext.java:281)
	at org.jboss.threads.ContextHandler$1.runWith(ContextHandler.java:18)
	at org.jboss.threads.EnhancedQueueExecutor$Task.run(EnhancedQueueExecutor.java:2449)
	at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1478)
	at java.base/java.lang.Thread.run(Thread.java:833)
	at org.jboss.threads.JBossThread.run(JBossThread.java:501)
	Suppressed: io.quarkus.qute.TemplateException: ownerDetails.html:45:17 - {pet.birthDate.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method
		at io.quarkus.qute.TemplateException$Builder.build(TemplateException.java:169)
		at io.quarkus.qute.deployment.QuteProcessor.processTemplateErrors(QuteProcessor.java:215)
		... 11 more
	Suppressed: io.quarkus.qute.TemplateException: ownerDetails.html:65:19 - {visit.date.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method
		at io.quarkus.qute.TemplateException$Builder.build(TemplateException.java:169)
		at io.quarkus.qute.deployment.QuteProcessor.processTemplateErrors(QuteProcessor.java:215)
		... 11 more
	Suppressed: io.quarkus.qute.TemplateException: createOrUpdateVisitForm.html:20:13 - {pet.birthDate.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method
		at io.quarkus.qute.TemplateException$Builder.build(TemplateException.java:169)
		at io.quarkus.qute.deployment.QuteProcessor.processTemplateErrors(QuteProcessor.java:215)
		... 11 more
	Suppressed: io.quarkus.qute.TemplateException: createOrUpdateVisitForm.html:77:13 - {v.date.format('yyyy-MM-dd')}: Property/method [format('yyyy-MM-dd')] not found on class [java.time.LocalDate] nor handled by an extension method
		at io.quarkus.qute.TemplateException$Builder.build(TemplateException.java:169)
		at io.quarkus.qute.deployment.QuteProcessor.processTemplateErrors(QuteProcessor.java:215)
		... 11 more



--
Tests paused
Press [r] to resume testing, [o] Toggle test output, [:] for the terminal, [h] for more options>
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  14.640 s
[INFO] Finished at: 2023-01-24T13:28:56Z
[INFO] ------------------------------------------------------------------------
%
@ksilz
Copy link
Author

ksilz commented Jan 24, 2023

I'm running macOS Ventura 13.2 on an M1 Max 2021 MacBook Pro 16 with the Temurin OpenJDK 17.0.5 and Docker Desktop 4.16.2.

@geoand
Copy link
Collaborator

geoand commented Jan 24, 2023

Thanks for reporting.

I'll have a look

geoand added a commit to geoand/quarkus-petclinic that referenced this issue Jan 24, 2023
@geoand
Copy link
Collaborator

geoand commented Jan 24, 2023

#8 should take care of it

@geoand
Copy link
Collaborator

geoand commented Jan 24, 2023

After talking with @mkouba, my fix should not be needed because Qute already provides such an extension method. However we are trying to see why you are getting the error.

@ksilz
Copy link
Author

ksilz commented Jan 24, 2023

@geoand Please wait while I install the tooling so I can download the PR to my local repo.

@geoand
Copy link
Collaborator

geoand commented Jan 24, 2023

👍🏼

This might an M1 issue, we are waiting to confirm

@mkouba
Copy link
Contributor

mkouba commented Jan 24, 2023

Yes, the fix is not correct and should not be merged until we know what the real problem is.

@geoand
Copy link
Collaborator

geoand commented Jan 24, 2023

Right, I have converted the PR to draft

@geoand
Copy link
Collaborator

geoand commented Jan 24, 2023

But @mkouba we will likely need the fix until we have a Quarkus version that fixes the issue

@geoand
Copy link
Collaborator

geoand commented Jan 24, 2023

@gastaldi ran this on his M1 and experience the same issue. So it is M1 specific and we'll have to fix it.
But in the meantime @mkouba I propose we merge #8

@ksilz
Copy link
Author

ksilz commented Jan 24, 2023

@geoand Yep, works for me with #8. Thank you!#8

One question: This is how the application looks like this on my Mac (Safari & Firefox). Could it be that the nav bar button doesn't show properly?
image

@geoand
Copy link
Collaborator

geoand commented Jan 24, 2023

@ksilz thanks for checking!

As for the UI, I am totally the wrong person to be able to answer that :) My UI skills is totally non-existent :(, but I can say that it did work properly for me on Chrome on a Linux box.

@mkouba
Copy link
Contributor

mkouba commented Jan 24, 2023

But in the meantime @mkouba I propose we merge #8

Feel free to merge #8 but (1) pls add some comment to the Temporals class and (2) file a new issue to revert this commit once we find/fix the real cause.

geoand added a commit to geoand/quarkus-petclinic that referenced this issue Jan 24, 2023
@geoand
Copy link
Collaborator

geoand commented Jan 24, 2023

I added some comments to the code.

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

Successfully merging a pull request may close this issue.

3 participants