market icon indicating copy to clipboard operation
market copied to clipboard

V4 barge

Open rogargon opened this issue 3 years ago • 8 comments

This PR tries to address some issues when trying to use the market just over locally deployed infrastructure (aquarius, ganache, contracts, thegraph, provider,...), similar to those described in #1567.

Changes proposed in this PR:

  • Example .env to use with barge
  • Add local barge to networks-metadata.json
  • Use dev config with locally deployed contracts for network 8996
  • start-local script triggering local ocean-subgraph codegen

Altogether, they should make it easier to use the market locally. Tested and able to publish both a dataset and an algorithm. I also bought and downloaded the dataset.

rogargon avatar Jul 19 '22 07:07 rogargon

@rogargon is attempting to deploy a commit to the Ocean Protocol Team on Vercel.

A member of the Team first needs to authorize it.

vercel[bot] avatar Jul 19 '22 07:07 vercel[bot]

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated
market ❌ Failed (Inspect) Jul 28, 2022 at 1:59PM (UTC)

vercel[bot] avatar Jul 28 '22 13:07 vercel[bot]

All the builds seem to fail.

mihaisc avatar Jul 28 '22 13:07 mihaisc

this affects too much running the app against remote networks, like always adding dev network to network selection at all times. And unnecessary duplication with added scrips which only change 1 line.

So this would need some more thinking and a better strategy, like:

  • read out the chainIdsSupported & chainIds arrays from .env vars
  • read out subgraph URI for pre-generation from .env vars
  • then pretty sure we need some signal from user that they want to run against barge, as we need to conditionally load or not load contract artifacts, like another env var, or loading a specific .env.barge file. Or use a new npm run start:local command. Ideas welcome
  • once we have this user intention, it's trivial to keep single scripts and have conditions in them rather than duplicating them all
  • local barge network info and a mechanism to get contract addresses via env vars is part of ocean.js, so worth looking into its ConfigHelper

kremalicious avatar Jul 28 '22 14:07 kremalicious

I'm glad to see someone trying to get some traction on this. The docs don't paint an accurate picture on how to make barge/market stack work locally, and has made onboarding our team slow and developing on ocean difficult. There are errors if you don't include an infura project id, errors when trying to connect to local ganache, and various development configs (ocean.ts) are commented out without any mention in the docs. We would be happy to help develop a friendlier local dev environment. Can you help clear up what are the known local development issues?

htcarr3 avatar Aug 03 '22 23:08 htcarr3

I'm glad to see someone trying to get some traction on this. The docs don't paint an accurate picture on how to make barge/market stack work locally, and has made onboarding our team slow and developing on ocean difficult. There are errors if you don't include an infura project id, errors when trying to connect to local ganache, and various development configs (ocean.ts) are commented out without any mention in the docs. We would be happy to help develop a friendlier local dev environment. Can you help clear up what are the known local development issues?

Agreed on this sentiment, we would also like to contribute back to the documentation on the missing gaps. Solving this lack of good documentation is key in getting adoption and also will help more teams build on ocean quickly and efficiently.

shadmoney avatar Aug 04 '22 01:08 shadmoney

The same for us, not being able to run the Market on a local Barge was complicating our development efforts. These changes are just a quick and dirty successful test as we have been able to make it work. We will continue elaborating on them, so the tests pass and it integrates smoothly into the main branch. Additionally, we can add a section to the README about the steps to get it working

rogargon avatar Aug 04 '22 07:08 rogargon

Thank you, yes at the very least the README should make it clear that, while barge can be run locally, market does not work with it out of the box. The docs currently read as if it should work out of the box.

htcarr3 avatar Aug 04 '22 11:08 htcarr3

This will be taken over by #1729 and all solutions to this incorporated there

kremalicious avatar Oct 10 '22 13:10 kremalicious