code: func NewProject(context *ctx.Context, parseOptions *config.ParseOptions) (project.APIProject, error) {
  
  	if err := context.LookupConfig(); err != nil {
  		logrus.Errorf("Failed to load docker config: %v", err)
  	}
  
  	if context.AuthLookup == nil {
  		context.AuthLookup = auth.NewConfigLookup(context.ConfigFile)
  	}
  
  	if context.ServiceFactory == nil {
  		context.ServiceFactory = service.NewFactory(context)
  	}
  
  	if context.ClientFactory == nil {
  		factory, err := client.NewDefaultFactory(client.Options{})
  		if err != nil {
  			return nil, err
  		}
  		context.ClientFactory = factory
  	}
  
  	if context.NetworksFactory == nil {
  		networksFactory := &network.DockerFactory{
  			ClientFactory: context.ClientFactory,
  		}
  		context.NetworksFactory = networksFactory
  	}
  
  	if context.VolumesFactory == nil {
  		volumesFactory := &volume.DockerFactory{
  			ClientFactory: context.ClientFactory,
  		}
  		context.VolumesFactory = volumesFactory
  	}
  
  	// FIXME(vdemeester) Remove the context duplication ?
  	runtime := &Project{
  		clientFactory: context.ClientFactory,
  	}
  	p := project.NewProject(&context.Context, runtime, parseOptions)
  
  	err := p.Parse()
  	if err != nil {
  		return nil, err
  	}
  
  	return p, err
  }
docs: // NewProject creates a Project with the specified context.