Coder Social home page Coder Social logo

iloveitaly / dali-rp2 Goto Github PK

View Code? Open in Web Editor NEW

This project forked from eprbell/dali-rp2

0.0 2.0 0.0 1.61 MB

DaLI (Data Loader Interface) is a data loader and input generator for RP2 (https://pypi.org/project/rp2), the privacy-focused, free, open-source US cryptocurrency tax calculator: DaLI removes the need to manually prepare RP2 input files. Just like RP2, DaLI is also free, open-source and it prioritizes user privacy.

Home Page: https://pypi.org/project/dali-rp2/

License: Apache License 2.0

Python 99.21% Makefile 0.79%

dali-rp2's Introduction

DaLI for RP2 v0.4.12

Static Analysis / Main Branch Documentation Check / Main Branch Unix Unit Tests / Main Branch Windows Unit Tests / Main Branch CodeQL/Main Branch

Tweet

Table of Contents

Introduction

DaLI (Data Loader Interface) is a data loader and input generator for RP2, the privacy-focused, free, open-source US cryptocurrency tax calculator: DaLI removes the need to manually prepare RP2 input files. Just like RP2, DaLI is also free, open-source and it prioritizes user privacy by storing crypto transaction data on the user's computer and never sending it anywhere else.

It performs the following operations:

  • it reads in crypto transaction information from multiples native sources: CSV files and/or REST-based services;
  • it analyzes, processes and merges this data;
  • it uses the processed data to generate an ODS input file for RP2 and its respective JSON configuration file.

DaLI has a programmable plugin architecture for data loaders (both CSV and REST-based). While some exchanges and wallets are already supported out-of-the-box, more are needed: help us make DaLI a robust open-source, community-driven crypto data loader by contributing plugins for exchanges and wallets! Check data-loader-plugin open issues.

DaLI has unit test coverage to reduce the risk of regression.

Note that DaLI has RP2 as a dependency, so installing DaLI causes RP2 to be installed as well.

IMPORTANT DISCLAIMER:

  • DaLI offers no guarantee of correctness (read the license): always verify results with the help of a tax professional.

License

DaLI is released under the terms of Apache License Version 2.0. For more information see LICENSE or http://www.apache.org/licenses/LICENSE-2.0.

Download

The latest version of DaLI can be downloaded at: https://pypi.org/project/dali-rp2/

Installation

DaLI has been tested on Ubuntu Linux, macOS and Windows 10 but it should work on all systems that have Python version 3.7.0 or greater.

Installation on Ubuntu Linux

Open a terminal window and enter the following commands:

sudo apt-get update
sudo apt-get install python3 python3-pip

Then install DaLI:

pip install dali-rp2

Installation on macOS

First make sure Homebrew is installed, then open a terminal window and enter the following commands:

brew update
brew install python3

Then install DaLI:

pip install dali-rp2

Installation on Windows 10

First make sure Python 3.7 or greater is installed (in the Python installer window be sure to click on "Add Python to PATH"), then open a PowerShell window and enter the following:

pip install dali-rp2

Installation on Other Unix-like Systems

  • install python 3.7 or greater
  • install pip3
  • pip install dali-rp2

Running

DaLI reads in a user-prepared configuration file in INI format, which is used to initialize data loaders and configure DaLI's behavior. The format of the configuration file is described in detail in the configuration file documentation.

An example of a configuration file can be found in test_config.ini.

After processing the configuration file, DaLI reads crypto data from native sources and generates a RP2 input ODS file and a RP2 configuration file in the output directory or where specified with the -o CLI option.

Provided DaLI is installed, to generate RP2 input files from the example configuration, open a terminal window (or PowerShell if on Windows).

Create the directory structure and download the example input files using wget or manually.

mkdir -p input

If your system has wget:

wget https://raw.githubusercontent.com/eprbell/dali-rp2/main/config/test_config.ini
wget https://raw.githubusercontent.com/eprbell/dali-rp2/main/input/test_manual_in.csv -P input/
wget https://raw.githubusercontent.com/eprbell/dali-rp2/main/input/test_manual_intra.csv -P input/
wget https://raw.githubusercontent.com/eprbell/dali-rp2/main/input/test_trezor_alice_btc.csv -P input/
wget https://raw.githubusercontent.com/eprbell/dali-rp2/main/input/test_trezor_bob_btc.csv -P input/

If your system doesn't have wget, download the following files manually:

And move the csv files to the input directory:

mv *.csv input

Then generate the output files for rp2:

dali_us -s -o output -p test_ test_config.ini
  • -s option allows DaLI to retrieve spot price information from the Internet, when it's not available from the CSV files or REST services.
  • -o option specifies the directory where the ODS output file is generated.
  • -p is the prefix of the output file.
  • test_config.ini is the configuration that ties the inputs together.

To print command usage information for the dali_us command:

dali_us --help

Finally compute taxes with RP2 using the generated input files (using both FIFO and LIFO accounting methods):

rp2_us -m fifo -o output/ -p rp2_ output/test_crypto_data.config output/test_crypto_data.ods
rp2_us -m lifo -o output/ -p rp2_ output/test_crypto_data.config output/test_crypto_data.ods

Configuration File

Read the configuration file documentation.

Reporting Bugs

Read the Contributing document.

Contributing

Read the Contributing document.

Developer Documentation

Read the developer documentation.

Frequently Asked Questions

Read the user FAQ list and the developer FAQ list.

Change Log

Read the Change Log document.

dali-rp2's People

Contributors

eprbell avatar stevendavis avatar houqp avatar nitrocode avatar

Watchers

James Cloos avatar  avatar

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.