Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: Add Filecoin Solidity Library FAQ #67

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Conversation

snissn
Copy link
Collaborator

@snissn snissn commented Feb 7, 2025

PR: Add Filecoin Solidity Library FAQ

Overview

This PR introduces a comprehensive FAQ (FAQ.md) to the repository, addressing common questions and clarifications about the Filecoin Solidity Library. The goal is to provide developers with clear guidance on integrating the library, reducing confusion, and improving usability.

Key Topics Covered

Serialization and Address Handling – Differences between serializeAddress implementations and best practices for buffer allocation.
BigInt Handling – Explanation of zero representations, serialization optimizations, and consistent handling.
Allowance and Token Transfers – How transferFrom, withdrawBalance, and addBalance behave in different scenarios.
Filecoin Actor Calls – Expected return behaviors for missing data, handling of publishStorageDeals, and large data responses.
Miner API – Clarification on slashed/terminated miners and ownership rules for CreateMiner.
Power API – Explanation of minerCount and its inclusion/exclusion of terminated miners.
Security and Error Handling – Best practices for using require vs. assert, and guidance on Filecoin precompiles.

Why This Is Needed

  • Provides clear, structured documentation based on developer discussions and audit insights.
  • Helps reduce onboarding friction for developers integrating Filecoin Solidity contracts.
  • Ensures best practices are well-documented for contract interactions and actor calls.

Implementation Details

  • The FAQ is included as FAQ.md in the root of the repository.
  • Content is designed to be self-contained, ensuring that developers do not need to reference external discussions to understand key concepts.
  • Formatting follows developer-friendly markdown standards, making it easy to read and navigate.

This commit adds a comprehensive FAQ (`FAQ.md`) to clarify common questions about the Filecoin Solidity Library.
The FAQ provides guidance on serialization, BigInt handling, allowances, actor calls, miner interactions, and security best practices, helping developers integrate the library more effectively.

For more details, visit the official repository documentation.
This update adds a reference to the newly created FAQ (`FAQ.md`) in the README,
helping developers find answers to common questions about the Filecoin Solidity Library.
The FAQ link is placed after the "How to Use It" section for better visibility.
@snissn snissn requested a review from trruckerfling February 7, 2025 20:30
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.

1 participant