title: How to handle an AttributeError(key) using a automap_base in Sqlalchemy?
body: <p>Please, help how to solve this error -  AttributeError(key):</p>
  
  <pre><code>  File "pivot_table_measurements.py", line 1, in &lt;module&gt;
      from database import *
    File "/home/dedeco/Projetos/bigclima-project/database.py", line 24, in &lt;module&gt;
      MeasureRanges = Base.classes.measure_ranges
    File "/home/dedeco/craw/lib/python3.5/site-packages/sqlalchemy/util/_collections.py", line 212, in __getattr__
      raise AttributeError(key)
  AttributeError: measure_ranges
  </code></pre>
  
  <p>database.py: </p>
  
  <pre><code>from sqlalchemy.ext.automap import automap_base
  from sqlalchemy.orm import Session
  from sqlalchemy import create_engine
  from sqlalchemy.orm.exc import MultipleResultsFound, NoResultFound
  import string
  from decimal import Decimal
  
  ECHO = False
  AUTOFLUSH = False
  
  Base = automap_base()
  
  engine = create_engine('postgresql://user:pass@localhost:5432/clima', echo=ECHO)
  
  Base.prepare(engine, reflect=True)
  
  Country = Base.classes.countries
  State = Base.classes.states
  City = Base.classes.cities
  Measurement = Base.classes.measurements
  MeasurementHourly = Base.classes.measurements_hourly
  MeasureRanges = Base.classes.measure_ranges
  Parameter = Base.classes.parameters
  WeatherStation = Base.classes.weather_stations
  
  session = Session(engine, autoflush=AUTOFLUSH)
  </code></pre>
  
  <p>The table measure_ranges exits on the database but I don't known why I'm receiving this error. When I delete this line ( MeasureRanges = Base.classes.measure_ranges) works, so I believe that error it's related with some issue in this table.</p>