Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
5c76810
[Tests] Added utility classes to setup the environment
Failxxx Nov 6, 2022
407c7ee
[Test] Added setup class for pytest
Failxxx Nov 6, 2022
c49c019
[Test] WIP: writing test script
Failxxx Nov 6, 2022
d06251d
[Test] WIP: test script is almost working
Failxxx Nov 11, 2022
492c04b
[Test] Fixed small issues
Failxxx Nov 11, 2022
711e11f
[Test] Fixed issues + added unit-testing script
Failxxx Nov 11, 2022
bd26009
[Test] Fixed missing 'matrix.os' definition
Failxxx Nov 11, 2022
bb173e0
[Test] Fixed wrong 'matrix.os' definition
Failxxx Nov 11, 2022
e3c772c
[Test] Fixed missing 'matrix.os' definition
Failxxx Nov 11, 2022
8c3124b
[Test] Fixed missing 'matrix.os' definition
Failxxx Nov 11, 2022
7906948
[Test] Fixed wrong test file name in python command
Failxxx Nov 11, 2022
e594eff
[Test] Fixed wrong test file name in python command
Failxxx Nov 11, 2022
cdfbfa4
[Doc] Added new tutorial for dev env linux
Failxxx Nov 12, 2022
d370917
[Test] Reduced number of unit tests
Failxxx Nov 12, 2022
e6634c6
[Test] Fixed wrong list of versions in get_python_version
Failxxx Nov 12, 2022
afdae53
[Test] Applied temporary fix to windows issue in unit tests
Failxxx Nov 27, 2022
2b3344e
[Test] Fixed small issues
Failxxx Nov 27, 2022
4deda53
[Test] Fiixed small issue
Failxxx Nov 27, 2022
6e8aa50
[Test] Added 'local_addon' in .gitignore
Failxxx Nov 27, 2022
db8816a
[Doc] Updated make.bat script. Now can build doc on windows.
Failxxx Feb 12, 2023
aaff2b6
[CI/CD] Updated actions plugins versions
Failxxx Feb 12, 2023
4df9cdf
[Tests] Try to fix python modules not found unit test env install
Failxxx Feb 12, 2023
2c14349
[Test] Add user scripts and site-packages folder to sys.path
Failxxx Feb 12, 2023
1fba4b0
[Tests] Reload list of available python modules during setup tests suite
Failxxx Feb 12, 2023
204501b
[Docs] Updated instructions developers manual
Failxxx Feb 19, 2023
5729948
[Docs] New tutorials to setup dev-env (add-on + manual)
Failxxx Feb 19, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@ jobs:
name: Build documentation
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2.5.0
- uses: actions/checkout@v3.3.0

- uses: actions/setup-python@v4.3.0
- uses: actions/setup-python@v4.5.0
with:
python-version: "3.10"

- uses: syphar/restore-virtualenv@v1.2
- uses: syphar/restore-virtualenv@v1.3
id: cache-virtualenv
with:
requirement_files: requirements.txt
Expand All @@ -45,15 +45,15 @@ jobs:
run: pip install -r requirements.txt

- name: Cache docs build directory
uses: actions/cache@v3.0.11
uses: actions/cache@v3.2.5
if: env.USE_CACHE == 'true'
with:
path: docs/build/
key: docs-build-${{ hashFiles('docs/source/conf.py') }}

- name: Cache animation nodes source code
id: animation-nodes-source-code
uses: actions/cache@v3.0.11
uses: actions/cache@v3.2.5
if: env.USE_CACHE == 'true'
with:
path: animation_nodes/
Expand Down Expand Up @@ -94,7 +94,7 @@ jobs:
cp -r docs/build/html build_docs
zip -r build_docs build_docs

- uses: actions/upload-artifact@v3.1.1
- uses: actions/upload-artifact@v3.1.2
if: env.DEPLOY == 'true'
with:
name: build_docs
Expand All @@ -106,9 +106,9 @@ jobs:
needs: build
if: github.ref == 'refs/heads/master' || startsWith(github.ref, 'refs/tags')
steps:
- uses: actions/checkout@v2.5.0
- uses: actions/checkout@v3.3.0

- uses: actions/download-artifact@v3.0.1
- uses: actions/download-artifact@v3.0.2
with:
name: build_docs
path: .
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/style.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ jobs:
stylecheck:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2.5.0
- uses: actions/checkout@v3.3.0

- uses: actions/setup-python@v4.3.0
- uses: actions/setup-python@v4.5.0
with:
python-version: "3.10"

Expand Down
46 changes: 46 additions & 0 deletions .github/workflows/unit-testing.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: Unit testing
on:
pull_request: # Run in pull requests

workflow_dispatch: # Allow to run this workflow manually

push:
branches: # Run when there is a push to master
- "master"

jobs:
Unit-testing:
runs-on: ${{ matrix.os }}
strategy:
max-parallel: 4
fail-fast: false
matrix:
blender-version: ["2.93.11", "3.4.1",]
os: ["ubuntu-latest", "windows-latest",]
env:
BLENDER_CACHE: ${{ github.workspace }}/cache # The place where blender releases are downloaded
BLENDER_VERSION: ${{ matrix.blender-version }}
steps:
- uses: actions/checkout@v3.3.0

- uses: actions/setup-python@v4.5.0
with:
python-version: "3.10"

- uses: syphar/restore-virtualenv@v1.3
id: cache-virtualenv
with:
requirement_files: requirements.txt

- name: Cache Blender release download
uses: actions/cache@v3.2.5
with:
path: ${{ env.BLENDER_CACHE }}
key: ${{ matrix.os }}-blender-${{ matrix.blender-version }}

- name: Install dependencies
if: steps.cache-virtualenv.outputs.cache-hit != 'true'
run: pip install -r requirements.txt

- name: Run test suite (Blender ${{ matrix.blender-version }}, ${{ matrix.os }})
run: python -m scripts.test -b ${{ matrix.blender-version }} -os ${{ matrix.os }}
7 changes: 6 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,13 @@ docs/source/developers_manual/code/
animation_nodes/

# Cache
.pytest_cache/
**/__pycache__
cache/

# Blender
*.pyc
*.blend[1-9]
*.blend[1-9]

# Tests
local_addon/
4 changes: 2 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ repos:
hooks:
- id: flake8
additional_dependencies: [
"flake8-quotes==3.3.1",
"flake8-quotes==3.3.2",
]

- repo: https://github.com/codespell-project/codespell
Expand All @@ -16,7 +16,7 @@ repos:
]

- repo: https://github.com/pycqa/pydocstyle
rev: 6.1.1
rev: 6.3.0
hooks:
- id: pydocstyle
exclude: quantum_nodes/lib/quantumblur.py
Expand Down
2 changes: 1 addition & 1 deletion docs/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Minimal makefile for Sphinx documentation
# Makefile for Sphinx documentation

# You can set these variables from the command line, and also
# from the environment for the first two.
Expand Down
23 changes: 10 additions & 13 deletions docs/make.bat
Original file line number Diff line number Diff line change
Expand Up @@ -4,28 +4,25 @@ pushd %~dp0

REM Command file for Sphinx documentation

if "%SPHINXBUILD%" == "" (
if "%2" == "" (
set SPHINXBUILD=sphinx-build
) else (
set SPHINXBUILD=%2
)

set SOURCEDIR=source
set BUILDDIR=build
set MODULE=quantum_nodes

if "%1" == "" goto help

%SPHINXBUILD% >NUL 2>NUL
if errorlevel 9009 (
echo.
echo.The 'sphinx-build' command was not found. Make sure you have Sphinx
echo.installed, then set the SPHINXBUILD environment variable to point
echo.to the full path of the 'sphinx-build' executable. Alternatively you
echo.may add the Sphinx directory to PATH.
echo.
echo.If you don't have Sphinx installed, grab it from
echo.http://sphinx-doc.org/
exit /b 1
)
move "../%MODULE%/__init__.py" "../%MODULE%/___init__.py"
powershell -ExecutionPolicy ByPass -command ". replace_matching_string_in_files.ps1 -find '@persistent' -replace '#@persistent';"

%SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%

powershell -ExecutionPolicy ByPass -command ". replace_matching_string_in_files.ps1 -find '#@persistent' -replace '@persistent';"
move "../%MODULE%/___init__.py" "../%MODULE%/__init__.py"
goto end

:help
Expand Down
23 changes: 23 additions & 0 deletions docs/replace_matching_string_in_files.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Replace matching strings with another string in the given list of files
param(
[string]$folder = "../quantum_nodes/",
[string]$find = "@persistent",
[string]$replace = "#@persistent"
)

[array]$files = Get-ChildItem -Path $folder -Include *.py -Recurse -Force | select -expand fullname

function Find-And-Replace-Strings {

param(
[array]$files,
[string]$find,
[string]$replace
)

ForEach ($file in $files) {
(Get-Content -Path $file -Raw) -replace $find, $replace | Set-Content -Path $file -NoNewLine
}
}

Find-And-Replace-Strings $files $find $replace
48 changes: 0 additions & 48 deletions docs/source/developers_manual/addon/index.rst

This file was deleted.

26 changes: 0 additions & 26 deletions docs/source/developers_manual/addon/linux.rst

This file was deleted.

6 changes: 0 additions & 6 deletions docs/source/developers_manual/addon/mac.rst

This file was deleted.

28 changes: 0 additions & 28 deletions docs/source/developers_manual/addon/tools.rst

This file was deleted.

6 changes: 0 additions & 6 deletions docs/source/developers_manual/addon/windows.rst

This file was deleted.

47 changes: 42 additions & 5 deletions docs/source/developers_manual/index.rst
Original file line number Diff line number Diff line change
@@ -1,9 +1,46 @@
Developers manual
=================
Contribute to Quantum Nodes
===========================


.. _dev-env-contrib-addon:

Development environment
#######################


.. toctree::
:maxdepth: 1
:glob:

instructions
tools


.. _contribute-contrib-addon:

Contribute
##########


.. note::
Click `here <https://docs.github.com/en/get-started/quickstart/fork-a-repo>`_ to learn about the forking workflow on Github.


* Fork our `git repository <https://github.com/Quantum-Creative-Group/quantum_nodes>`_
* Do your modifications
* Open a new `pull request <https://github.com/Quantum-Creative-Group/quantum_nodes/pulls>`_
* Wait for your modifications to be reviewed and accepted


.. _git-workflow-contrib-addon:

Git workflow
############

.. image:: https://miro.medium.com/max/560/1*UH5ozOBwkaFhWA1mrJkVIQ.png
:alt: Git workflow
:align: center
:width: 80%
:class: img-rounded

addon/index
manual/index
code/quantum_nodes
|
Loading