{"id":19096810,"url":"https://github.com/makerdao/osm","last_synced_at":"2025-04-18T16:31:15.201Z","repository":{"id":46990407,"uuid":"122663029","full_name":"makerdao/osm","owner":"makerdao","description":"Feed with 1 hour delay","archived":false,"fork":false,"pushed_at":"2023-03-16T02:28:47.000Z","size":48,"stargazers_count":21,"open_issues_count":2,"forks_count":26,"subscribers_count":21,"default_branch":"master","last_synced_at":"2023-04-05T23:40:54.205Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Solidity","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"agpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/makerdao.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-02-23T19:20:08.000Z","updated_at":"2023-03-23T03:32:03.000Z","dependencies_parsed_at":"2022-09-10T18:51:21.075Z","dependency_job_id":null,"html_url":"https://github.com/makerdao/osm","commit_stats":null,"previous_names":[],"tags_count":null,"template":null,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/makerdao%2Fosm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/makerdao%2Fosm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/makerdao%2Fosm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/makerdao%2Fosm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/makerdao","download_url":"https://codeload.github.com/makerdao/osm/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":223783307,"owners_count":17201901,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-09T03:37:51.891Z","updated_at":"2024-11-09T03:37:52.409Z","avatar_url":"https://github.com/makerdao.png","language":"Solidity","readme":"# Oracle Security Module\n![Build Status](https://github.com/makerdao/osm/actions/workflows/.github/workflows/tests.yaml/badge.svg?branch=master)\n\nThis contract is given a `DSValue` as a source to read from. You set a time interval with `step`. Whenever that `step` time has passed, it will let you `poke`. When you `poke` it reads the value from the source and stores it. The previous stored value becomes the current value. \n\nThis contracts implements `read` and `peek` from DSValue, but it is not one. It also has a new function `peep` to read what the next value will be after a `poke`.\n\n```\n// create\nOSM osm = new OSM(DSValue(src));\n\n// can be poked every hour, on the hour\nosm.step(3600);\n\n(val, ok) = osm.peek() // get current value\n(val, ok) = osm.peep() // get upcoming value\nval       = osm.read() // get current value, or fail\n\n```\n\nIf this `DSValue` has a valid value on creation, the OSM with start with that same value.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmakerdao%2Fosm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmakerdao%2Fosm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmakerdao%2Fosm/lists"}