Error When setup the home assistant

this is error message:-1:

 (homeassistant_venv) homeassistant@raspberrypi:/home/pi$ hass --script check_config
Testing configuration at /home/homeassistant/.homeassistant
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setting up http
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setting up recorder
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setup of domain http took 0.0 seconds.
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setup of domain recorder took 0.0 seconds.
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setting up websocket_api
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setting up api
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setting up history
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setup of domain websocket_api took 0.0 seconds.
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setup of domain api took 0.0 seconds.
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setup of domain history took 0.0 seconds.
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setting up frontend
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setup of domain frontend took 0.0 seconds.
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setting up sun
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setting up discovery
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setting up updater
2017-10-10 07:43:55 ERROR (MainThread) [homeassistant.config] Invalid config for [switch.rpi_gpio]: required key not provided @ data['ports']. Got None. (See ?, line ?). Please check the docs at https://home-assistant.io/components/switch.rpi_gpio/
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setting up sensor
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setting up group
2017-10-10 07:43:55 ERROR (MainThread) [homeassistant.loader] Unable to find component ports
2017-10-10 07:43:55 ERROR (MainThread) [homeassistant.setup] Setup failed for ports: Component not found.
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setup of domain sun took 0.1 seconds.
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setup of domain discovery took 0.1 seconds.
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setup of domain updater took 0.1 seconds.
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setup of domain sensor took 0.1 seconds.
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setup of domain group took 0.1 seconds.
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setting up tts
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setting up config
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setting up logbook
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setting up conversation
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setting up automation
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setting up switch
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setting up script
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setup of domain tts took 0.0 seconds.
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setup of domain config took 0.0 seconds.
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setup of domain logbook took 0.0 seconds.
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setup of domain conversation took 0.0 seconds.
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setup of domain automation took 0.0 seconds.
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setup of domain switch took 0.0 seconds.
2017-10-10 07:43:55 INFO (MainThread) [homeassistant.setup] Setup of domain script took 0.0 seconds.
Failed config
  switch.rpi_gpio: 
platform: rpi_gpio

  General Errors: 
- Component not found: ports
- Setup failed for ports: Component not found.

Successful config (partial)
  switch.rpi_gpio:

You are probably missing some spacing in your config file.

Read this: https://home-assistant.io/docs/configuration/yaml/
Post you config if can not solve your problem

Hi Danialhiversen,

thanks for respond. I try to use the switch in config file. But i dont which part need to space.