Build failure when trying to watch a module on an SDK instance.

I successfully setup an SDK distribution server version 2.10.0. However, when I clone the latest version of the openmrs-module-appointmentschedulingui and run mvn openmrs-sdk:watch to watch the module, followed by mvn openmrs-sdk:run command to start the server , I get this error in the command line. Kindly how do I go about it?

Hello friends, am trying to fix RA-1716 and I can’t watch the openmrs-module-appointmentschedulingui When I run openmrs-sdk:watch followed by mvn openmrs-sdk:run command I get this out put on the command line. Kindly how do I go about it?

@mogoodrich, @bistenes, @ibacher @cioan, @dkayiwa

When I run mvn openmrs-sdk:unwatch ‘artifactId’: appointmentschedulingui followed by mvn openmrs-sdk:run command, the server builds successfully.

Could you try installing bower and see if that makes things work?

1 Like

Thank you so much! let me do it right away.

@ibacher sorry for the late response but I have tried it out but I haven’t succeeded using bower. most likely the problem is on my side being the first to try it out.

@jwnasambu try to first un-watch the module with mvn openmrs-sdk:unwatch -DserverId=myserverId -DartifactId=mymodule

Then do a mvn clean install build, then watch the module again with mvn openmrs-sdk: watch -DserverId=myserver and finally run your server again with mvn openmrs-sdk:run -DserverId=myserver

Thanks @gcliff I tried all that but still I get the same error I shared in the pastebin above.

For the start are you able to successfully do a mvn clean install in the root folder of the module minus your changes ?

I haven’t made any changes and when I run mvn clean install command the build is successful as reflected on this pastebin

cool :+1:

you can set up a reff app server of the recently released reff app and then run mvn openmrs-sdk: watch -DserverId=myserver in the root folder of the Appointment Scheduling UI Module

Thanks so much for the guide. The issue am trying to fix is for sdk version 2.10 and 2.11. and apparently am running version 2.10 of which am able to watch a registration module and and not appointmentschedulingui which makes me believe it could be a bug that is making this module not to be watched and needs to be fixed. Though I stand to be corrected.

are you talking about the sdk version here? because the current sdk version is 3.13.6

Am sorry its RefApp 2.10

@jwnasambu u can use 2.11 which has just been released and we see how it goes

@gcliff and @ibacher thanks for coming to my rescue. Am glad I can watch the module on RefApp 2.11.0

1 Like

So what was the problem?

Well, I can’t a firm why am failing to watch appointmentschedulingui module on RefApp 2.10 though I can watch other modules. I tried installing bower though I suspected bower failed because the components directory was stale and being the first timer I abandoned it and instead installed RefApp 2.11 which is working perfectly well. That makes conclude the is a bug(which needs quality time to be identified) to be fixed for one to be able to watch appointmentschedulingui on RefApp 2.10.

@dkayiwa, @gcliff and @gcliff I have confirmed appointmentschedulingui module can be watched on RefApp 2.10. The prior build failure was my mistake. After fixing a bug on registration module, I forgot to unwatch this module by running mvn openmrs-sdk:unwatch. This incidence leaves me with a question: Does it mean 2 or more modules cannot be watched at the same time?

i dont think its possible because you were trying to watch two modules on the same server , it might be possible(though not sure coz i have never tried it out in a particular usecase) if its on different servers