cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Localhost preview error using CAP tutorial

mpredolim
Participant
0 Likes
2,458

Tutorials: https://developers.sap.com/tutorials/btp-app-create-cap-application.html
--------------------------

Hi Gurus,

I´m following the steps from tutorial above and when i try to load the local server for CAP i can´t see the screen below:



Just this error:


I´ve checked my firewall and i can´t see any process being blocked from this test.

Previous steps from current tutorial were done with success until this one...

Any ideas please?

Thanks in advance,
Mauricio Predolim

Accepted Solutions (0)

Answers (1)

Answers (1)

martinstenzig
Contributor
0 Likes

Are you running it in the Business Application Studio?

mpredolim
Participant
0 Likes

Hi Martin.

No, i´m using VSCode according to the tutorial.

Txs,
Mauricio

martinstenzig
Contributor
0 Likes

Can you share what you see in the terminal after you execute `cds watch`?

mpredolim
Participant
0 Likes

Sure!

Txs,

Mauricio

martinstenzig
Contributor

What this tells you is either one of two things. As long as you don't have a file in your `srv` directory that defines what Service you want to expose, CAP does not have enough information. If you have a file in there with the service definition and you still get the error, you are probably not in the CAP root directory of the project when you run `cds watch`.

mpredolim
Participant
0 Likes

Martin,

The file for 'srv' directory i already have it as you can see below

It´s described into step 4 from tutorial:

But when i check into terminal, there is no information about localhost:4004, just "No models found in /db,/srv/,app..."

mpredolim
Participant

martin.stenzig3 It´s working!

When you mentioned "you are probably not in the CAP root directory of the project when you run `cds watch`." I tried again runs CDS WATCH into CPAPP directory and now it´s working! 😛

Thanks for your support!
Mauricio Predolim