Skip to content

Conversation

@PierreJeanjacquot
Copy link
Member

@PierreJeanjacquot PierreJeanjacquot commented Sep 29, 2025

overloaded fetchAppOrderbook and fetchDatasetOrderbook methods:

  • the first mandatory param (asset address) should be substituted by the option object; either the asset address (previous first param) or the owner address must be specified.
  • previous API is deprecated but still works for backward compatibility

@github-actions
Copy link

github-actions bot commented Sep 29, 2025

🐳 Hadolint Dockerfile Lint Results

Click to expand detailed results
Dockerfile:17 DL3016 warning: Pin versions in npm. Instead of `npm install <package>` use `npm install <package>@<version>`

@PierreJeanjacquot PierreJeanjacquot force-pushed the feat/fetch-user-orderbook branch 2 times, most recently from 6ece1e4 to 937517e Compare September 30, 2025 09:56
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR refactors the orderbook API to allow searching by asset owner while maintaining backward compatibility. The API changes from passing the asset address as the first parameter to accepting an options object that can contain either the asset address or the owner address.

  • Added support for searching app/dataset orders by owner address (appOwner/datasetOwner parameters)
  • Refactored function signatures to accept options object as first parameter instead of asset address
  • Maintained backward compatibility with deprecation warnings for the old API

Reviewed Changes

Copilot reviewed 6 out of 7 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
src/common/market/orderbook.js Core implementation refactoring to support new options object parameter and owner-based searching
src/lib/IExecOrderbookModule.js Updated method signatures to match new parameter structure
src/cli/cmd/iexec-orderbook.js Updated CLI commands to use new options object format
src/cli/cmd/iexec-app.js Updated app CLI commands to use new options object format
test/lib/e2e/IExecOrderbookModule.test.js Updated tests to use new API and added tests for owner-based searching
docs/classes/IExecOrderbookModule.md Updated documentation to reflect new API signature and deprecation notices

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@sonarqubecloud
Copy link

sonarqubecloud bot commented Oct 2, 2025

Quality Gate Failed Quality Gate failed

Failed conditions
43.0% Coverage on New Code (required ≥ 80%)
12.4% Duplication on New Code (required ≤ 3%)

See analysis details on SonarQube Cloud

Copy link
Contributor

@Le-Caignec Le-Caignec left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some comments for consistency between function signatures.

@PierreJeanjacquot PierreJeanjacquot merged commit 5e1c880 into master Oct 2, 2025
9 of 10 checks passed
@PierreJeanjacquot PierreJeanjacquot deleted the feat/fetch-user-orderbook branch October 2, 2025 12:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants