code: def add(self, resource, replace=False):
          
          uri = resource.uri
          for r in self:
              if (uri == r.uri):
                  if (replace):
                      r = resource
                      return
                  else:
                      raise ResourceListDupeError(
                          "Attempt to add resource already in resource_list")
          # didn't find it in list, add to end
          self.append(resource)
docs: Add a single resource, check for dupes.