Giter VIP home page Giter VIP logo

civil's People

Contributors

am9u avatar dependabot-preview[bot] avatar dependabot-support avatar dependabot[bot] avatar godfreyhobbs avatar jorgelo avatar kimpers avatar nickhimmel avatar nickreynolds avatar petersng avatar ritave avatar sruddy avatar tobek avatar walfly avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

civil's Issues

Build Badge should only reflect status of last master build

  • Right now, if a branch is pushed that breaks something (or has no tests, such as the gh-pages branch), the badge shown in the README of the root of monorepo shows an error.
  • The badge should only reflect the status of the last master build, not any branch

Improve readabillity of automated tests

lerna run test is not a best way to run tests, as lerna has problem with printing them to CLI in a fashionable manner.

@walfly suggested using this code as a way around this.

echo */package.json | \
xargs -n1 dirname | \
xargs -n1 -I % \
sh -c "cd % && npm install && npm run lint && npm test || exit 255"

Introduce automated testing to monorepo

Multiple packages in the monorepo have .circleci rules from when they were seperate git repos. A way to build all packages, seperatly lint all packages and test all packages are needed.

When that's done, .circleci rules need to be written for testing all packages

Debug-UI has compiler errors when trying to use "fs"

  • on branch nickreynolds/tcr_wrapper I made some changed to debug-ui, separating functionality into different pages
  • When I try to use "fs" in any file in the code folder, I get the error Module not found: Error: Can't resolve 'fs' in '/Users/nickreynolds/Civil/Civil/packages/debug-ui/src/code' even though it has definitely been added, and that's reflected in package.json
  • I think this has something to do with the gulpfile, but I'm not sure how to fix it

Race condition in truffle test

There's a bug in truffle test that makes our tests fail randomly, fixing it is of utmost importance due to hugely increased rates of circleci tests failing.

Trying to call TCR transactions fails with "invalid number of arguments"

  • on branch nickreynolds/tcr_wrapper I've made changes to debug-ui to support testing TCR transactions.
  • After deploying a newsroom, you are taken to a page for that newsroom where you can attempt to apply to the TCR, but that fails (check console log).
  • Error message doesn't seem too helpful on debug-ui, but I first encountered issue on civil-web and got the Invalid number of arguments to Solidity function error. I've tried other functions as well (like deposit) but they also fail.
  • Adding some logging that leads me to believe the issue is related to estimate gas sync. Doesn't seem to get past that point.

Only run Code Coverage check when contracts package is updated

  • The code coverage test takes a long time and it can be annoying to wait for it when you know there will be no changes.
  • We should only run that check when there are changes in the contracts package, since that is the only way the code coverage could change.

Add Build Step to Keep Artifacts in Sync Between `core` and `contracts`

  • right now, before generating .ts wrappers in core, the artifacts must be copied over manually from contracts package. When we migrate contracts via truffle, the artifacts in core become outdated, and don't contain correct per-network deployed addresses.
  • modify build process so that artifacts are kept in sync between the 2 packages, so that when accessing deployed addresses via core we have the most recent deployed contracts.

Debug-ui needs to display an article

Currently debug-ui is not yet tested or functional, to make it work, it needs to be able to display an article.
Load newsroom, load a specific article from there and than parse it as a markdown and display it.

Newsroom-manager creates their own version of Civil library

Newsroom-manager has a Civil context, which creates a separate instance of Civil for it's own purposes. This is especially noticeable in the DApp, when both the Newsroom Manager and DApp listen for network and account updates duplicating calls

RPC Gas estimation is too low

Sometimes gas estimates from web3 are too low for the call to succeed which then throws a EVM error. Add a safe minimum to the estimated gas to avoid this problem, decide whether this should be a constant or a multiplier.

Make the ACL and Newsroom contracts Ownable instead of having superusers.

Right now ACL-based contracts have a lot of separate logic for maintaining superusers. By leveraging multi-sig wallets we can obtain the same functionality while still maintaining separation of concerns as well as having a singe contract acting as a Will of ACL-based contracts.

ACLs would have a single owner, god contract, that in most of the cases be a multi-sig wallet

Update DApp to use new Charter schema

In PR #484, two breaking changes were made regarding Newsroom Charters:

  • the schema for Newsroom Charters was changed
  • an update was made to @joincivil/core to parse the charter content from IPFS into a JS object directly in core. previously, this field was a string and the DApp was parsing that string into an object.

PR #500 was merged as a temporary fix for rendering legacy charter data, but the DApp needs to be updated to use the new Charter schema

Use abi-gen generated wrappers in contract tests

Right now contract tests (packages/contrats/test) use Truffle wrappers on all contracts we have, while our library (packages/civil.ts) has better support for compile time errors.

Using one wrapper in both places would decrease the amount of dependencies we have and increase security due to possible different behaviours of both. Using our own abi-generated contracts is a preferable option, so updating contract tests is better

Provide on-boarding through README

The main monorepo doesn't have a readable and one with core information needed readme. Stuff like explaining what's here, how is it useful, how to use it in your project, how to start contributing, licenses, stuff like this.

Things needed for new developers to become on-board and are able to use and contribute to our packages effectively

Updates Typescript to >=2.9

Typescript 2.9 and later changes on how the JSON files are imported. Due to lack of time we've decided to freeze the version to <2.9.0 but in the future we'd be happy to updated it to the newest version.

Work needed to be done:

  • Update all package.json
  • Add support for esModuleInterop
  • Update all packages to use esModuleInterop
  • Add support for resolveJsonModule
  • Update all imports to use esModuleInterop
  • Add support for declarationMap
  • Fix all dependencies

Add licenses to projects

Each open-source has either Apache 2.0 or LGPLv2.1 license in it. Add those licenses to the respective packages, package.json and explain in the main Monorepo README

Fix Solhint not linting smart-contracts

Solhint doesn't error-out on a glob usage.

We previously used glob src/contracts/**/*.sol which is not parsed properly, linting only contracts in subfolders, omitting main ones. Proper linting path is needed (src/contracts/*.sol src/contracts/test/*.sol).

This also introduces 500+ (!) linting errors and warnings into our codebase which all need to be fixed.

Allow Newsroom content to be loaded and saved from Github Gists

Currently the only way to store and load content is through InMemoryProvider, an abstraction of ContentProvider, which destroys the content on website refresh. We need a more permanent way to store content in a way that allows easy debugging and editing.

Using Gists for this scenario is pretty cheeky and a functional and easy to maintain way to achieve this goal. A new implementation of a ContentProvider is needed.

Remove the need of using custom type roots for end-developers

Currently to use our packages in Typescript projects, the end user has to include @joincivil/typescript-typings package in their typeRoots directive of Typescript.

This is not a standard step and might confuse users, removing it would greatly benefit on-boarding of new developers.

My own suggestion is to find a way on how to pack all the custom and used types from @joincivil/typescript-typings into one .d.ts file.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.