{"id":23651472,"url":"https://github.com/athanclark/purescript-symbiote","last_synced_at":"2026-01-31T19:02:10.198Z","repository":{"id":50785222,"uuid":"205294695","full_name":"athanclark/purescript-symbiote","owner":"athanclark","description":"Data serialization verification implementation","archived":false,"fork":false,"pushed_at":"2021-05-29T17:18:27.000Z","size":118,"stargazers_count":1,"open_issues_count":2,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-01-11T11:34:06.531Z","etag":null,"topics":["encoding","network","quickcheck","serialization","symbiote","testing"],"latest_commit_sha":null,"homepage":null,"language":"PureScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/athanclark.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":"2019-08-30T03:07:20.000Z","updated_at":"2024-02-27T11:20:48.000Z","dependencies_parsed_at":"2022-08-24T13:38:19.246Z","dependency_job_id":null,"html_url":"https://github.com/athanclark/purescript-symbiote","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/athanclark/purescript-symbiote","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/athanclark%2Fpurescript-symbiote","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/athanclark%2Fpurescript-symbiote/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/athanclark%2Fpurescript-symbiote/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/athanclark%2Fpurescript-symbiote/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/athanclark","download_url":"https://codeload.github.com/athanclark/purescript-symbiote/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/athanclark%2Fpurescript-symbiote/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28950279,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-31T18:30:42.805Z","status":"ssl_error","status_checked_at":"2026-01-31T18:30:19.593Z","response_time":128,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["encoding","network","quickcheck","serialization","symbiote","testing"],"created_at":"2024-12-28T16:37:53.545Z","updated_at":"2026-01-31T19:02:10.183Z","avatar_url":"https://github.com/athanclark.png","language":"PureScript","readme":"# PureScript-Symbiote\n\nThis project aims to be a network agnostic and data format agnostic serialization verifier - it's main\npurpose is to verify that _data_, _operations_ on that data, and _serialization_ of that data is\nall consistent for multiple platforms. This project defines a trivial protocol that can be re-implemented\nin any platform, over any network medium.\n\n## How the Protocol Works\n\nIt's a pretty simple idea:\n\n![](https://github.com/athanclark/symbiote/raw/master/images/drawing-rendered.png)\n\n### Setting\n\nBasically, the test suite envolves two peers - we'll call them Peer A and Peer B, and they're connected\nby some network. Likewise, they are both using (possibly different) systems, which we've denoted as Lang A\n(like Haskell) and Lang B (like PureScript / JavaScript).\n\nThe goal of this suite is to ensure that the _same idea_ defined on these different platforms have the\n_same representation_ - both operationally (i.e., QuickCheck laws) and through some encoding (like printing\nthe data to JSON or a ByteString).\n\nIn the diagram above, each system has some idea of what \"Type T\" looks and feels like, but could be completely\ndifferent implementations on each system. Again, though, we care about their _outcome_ being identical; so we\ndisambiguate the idea from the data.\n\n### Protocol\n\nThe first step in the protocol is for the generating party (Peer A) to generate an instance of Type T, and an operation\non that type - this operation, too, needs a serialization implementation (but for most intents and purposes,\nthe implementation will be only for the scope of use with this test suite).\n\nPeer A then does two things: it serializes both the operation and instance to the network-acceptable format, _and_\nit \"performs\" the operation on that instance to get an _expected result_. Basically, Peer A is using Peer B as a\nremote procedure call for that operation, and verifying that the result obtained remotely is identical to the\nresult obtained locally.\n\n### Remote Procedure Call\n\nAs just stated, Peer A then sends the serialized instance and operation to Peer B over that network, where Peer B\ndecodes the data, and performs the operation. Peer B then encodes the result, and sends it back to Peer A.\n\n### Verification\n\nPeer A now receives the performed data from Peer B, and can now decode it, and test to see if it is equal to the\nexpected result. If it is, it will tell Peer B that it's \"their turn\" to generate data.\n\n\nAll of this relies on QuickCheck to generate the data - with the size of the generated data increasing at each step,\nuntil a maximum is reached (which is clarified in the documentation).\n\n-------------\n\nFor an example, check out the tests - they are performed both locally in an asynchronous channel, and remotely\nwith its sister package - [symbiote for Haskell](https://hackage.haskell.org/package/symbiote).\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fathanclark%2Fpurescript-symbiote","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fathanclark%2Fpurescript-symbiote","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fathanclark%2Fpurescript-symbiote/lists"}