Errata CH 13 Circularly references itself as a goto

Problem

Remember to start the backend before running this test — or it will fail! This test requires live responses. You have not broken its dependency on the real backend implementation yet. For instructions on setting up and starting the MyBiz backend, see Chapter 13, Legacy Problems.

Discussion

Chapter 13 is title “Chapter 13: Breaking Up Dependencies” and not the proper chapter referenced inside Ch 13. “Legacy Problems” is Chapter 11.

This chapter is full of errata and invalid references to other chapters.

Example 2:

Build and test — and the test passes! This example short-circuits the discovery part of characterization tests, as described in Chapter 12, Legacy Problems. It’s an important part of the process but out of the scope of this chapter.

Chapter 12 is “Dependency Maps”

Solution

Ignore what the book says for now.

Installing Vapor

Follow the official documentation instructions here - https://docs.vapor.codes/3.0/install/macos/

Running Vapor Backend

Follow instructions in Chapter 12 after the “once vapor is installed…”

  • Not mentioned in book: Xcode may have two Schemas defined for the vapor backend project once it has been generated, one called “MyBiz-Package” and another called “Run”. Select Run schema and press Play to actually start the server from Xcode.

Ancillary Issue

Ch 11: Legacy Problems introduces the concept of a “backend” which is based on Vapor. It states to reference Ch 8: Networking Client in order to setup the backend code.

Problem 1 - No backend code Provided in Ch 8

Problem 2 - No setup instructions provided in Ch 8 for Vapor

@jrg.developer @mkatz Do you have any feedback about this? Thank you - much appreciated! :]

Thanks for reporting this, @liltimtim :]

@mkatz Hmm, this sounds like it may be an error in the text.

As you wrote this chapter, can you confirm if this indeed in error, and if so, we can look into fixing this in next update to the book?