Commit Graph

93 Commits

Author SHA1 Message Date
Eero af Heurlin df5b2c16d5
Add pre-commit.com framework hooks (#7176)
* Add pre-commit hooks for basic standards conformity checking

* These should not be marked as executable

* These lack shebangs so marking them executable did not do anyone any good

* add pre-commit to dev requirements

* use pre-commit framework for the hook

* Move the pre-commit config outside of root

As discusses in https://github.com/kivy/kivy/pull/7176#discussion_r511240059

* Document that pre-commit is used and how to skip checks if needed

* Mark the old hook script as deprecated
2020-12-09 22:48:48 -05:00
matham f031f2a679
Try python3 first as python may point to python2. (#7157) 2020-10-16 12:44:30 -04:00
Akshay Arora 20a0641b76
fail on anything less than 3.0 2020-09-27 22:12:47 +05:30
akshauaurora 56c4447ffb Detect python verion and gracefully fail on unsupported ver. 2020-09-27 15:53:40 +05:30
Matthew Einhorn 6607506953 Move flake8 config to setup.cfg, be more error spcific. 2020-01-05 02:36:21 -05:00
Matthew Einhorn 0b6b8930e6 Switch to flake8 and fix PEP8 issues. 2020-01-03 17:17:09 -05:00
matham cbcefeee34
ifneq cannot be indented. 2019-05-15 15:39:35 -04:00
matham 4c684148c7 Only delete files in kivy, properly detect git. 2019-05-15 13:43:54 -04:00
Matthew Einhorn d862144cb8 On windows compiled binaries are .pyd files. 2019-05-02 14:59:45 -04:00
Mathieu Virbel 821c1e67ca Makefile: opt for a smaller view by default, better for CI 2019-03-05 00:28:23 +01:00
Mathieu Virbel edc22b82d8 enforce KIVY_NO_ARGS when using pytest 2019-03-05 00:28:23 +01:00
Mathieu Virbel 82c8d2f981 move the test suite to pytest 2019-03-05 00:28:23 +01:00
Akshay Arora 565b6f54bb
Merge pull request #5304 from bionoid/test_imageloader
Add ImageLoader test case
2018-07-11 06:00:39 +05:30
Dominik Lang 2fc258b966 Improve Makefile debug configuration
--cython-gdb  enables the `cygdb` command
-Og           recommended optimisation flag for debugging

see:
http://docs.cython.org/en/latest/src/userguide/debugging.html
https://gcc.gnu.org/onlinedocs/gcc/Optimize-Options.html#index-Ofast
2018-06-09 14:00:51 +02:00
Terje Skjaeveland 021b0507c1 test_imageloader: Squashed lots of updates 2017-07-30 22:59:20 +02:00
Terje Skjaeveland 5d5097d675 ImageLoader test case
Initial commit
2017-07-26 12:24:54 +02:00
Mathieu Virbel 3b350be139 Windows: add support for ANGLE as an alternative for GL rendering
This can be achieve by asking a ES profile implementation to SDL2, and compile then copy ANGLE libEGL.dll and libGLESv2.dll to c:\Python27\share\sdl2\bin.
Support in kivy for ANGLE must be activated at compilation: USE_ANGLE=1 make

The changes intruduce a "dynamic" opengl backend, that uses SDL2 GetProcAddress to gather all the GL pointers that we need for opengl, and expose them in "cgl" context.
All the graphics implementation now use cgl (either a module or the new context for dynamic gl) as a base for accessing GL functions. The GL definitions are extracted and shared in c_opengl_def.

ANGLE give us:
- ability to execute Kivy application with default driver (at least for Virtualbox and intel, no need to install specific vendor graphics)
- works starting Direct3d 9 support (use dxdiag to find out)
- works on older computer (intel drop opengl support older graphics card (< 2011, according to a customer) on Windows 10 while there where no issue on Windows 7)

Known issues:
- stencil doesn't work on Windows 7 on Virtual BOX, but even their samples doesn't work, while firefox and chrome that uses angle (according to http://www.browserleaks.com/webgl)
- line doesn't show on Windows 10

TODO:
- continue to separate fully the GL context in order to dynamically switch to another implementation at runtime
  - be able to use MOCK without recompilation
  - be able to use DEBUG opengl (check glGetError after every command) without recompilation
  - be able to either use DESKTOP opengl or ANGLE opengl without recompilation
- stencil fixes or alternative
- line fixes or alternative

Suggestions:
- if stencil is really an issue, there is a possibility to use scissor. It might be faster, but doesn't support stack, and have addional limitation, such as: scissor must be aligned to the windows while stencil can be rotated + position of the scissor must be in windows coordinate. They may have a possibility to make "hybrid" instructions that either use scissor or stencil depending the current matrix. On standard ui (without any scatter/rotation), only scissor would be used.
2016-12-18 16:36:14 -05:00
dessant aa8d66ffc9 remove stylereport from phony targets 2016-12-17 19:12:14 +02:00
dessant 53697fe0ed remove stylereport target from Makefile 2016-12-17 18:04:22 +02:00
dessant 1a7208f01c ignore errors from the first call of make pdf 2016-02-24 23:53:48 +02:00
dessant 1fcec99af5 ignore the exit code of the first pdf build 2016-02-24 23:10:51 +02:00
akshayaurora a06e325cf2 pdf: call make pdf twice 2015-12-01 15:52:13 +05:30
Ryan Pessa 4af4298a7f respect PYTHON var when running make test 2015-04-01 22:53:05 -05:00
dessant 5e19d3b564 keep make build the default proxy for make 2015-02-08 16:41:33 +02:00
Charles Merriam a2fdd3f30b Modify Makefile's 'make style' to check entire tree
The makefile targets 'style' and 'stylereport' had only checked
the kivy/ directory.  This allowed style errors to creep into
the examples/ directory.   Now 'style' will check all python
files from the kivy root directory, excluding those
explicitly ignored in kivy/tools/pep8checker/pep8kivy.py.
2015-02-01 13:09:53 -08:00
Charles Merriam 88d8bea74f minor extra line. 2015-01-27 15:37:07 -08:00
Charles Merriam dc9130d1b1 Add a 'help' target to Makefile
‘make help’ now describes the targets that can be made.
2015-01-27 15:34:56 -08:00
Thomas-Karl Pietrowski 9612a08e27 Will rebuild cython code to build the latest docs
* fixes https://github.com/kivy/kivy/issues/2917
2015-01-27 11:58:03 +01:00
Thomas-Karl Pietrowski b974bb8e8a Merge branch 'make-doc-build-failsave' 2015-01-25 16:30:16 +01:00
Thomas-Karl Pietrowski e12c5226d1 missed one python -> $(PYTHON) 2015-01-25 16:28:55 +01:00
Thomas-Karl Pietrowski 420f7b54b1 Merge pull request #7 from thopiekar/make-doc-build-failsave
Make doc build failsave
2015-01-25 16:04:38 +01:00
Thomas-Karl Pietrowski 0ac77a8708 Quick fix 2015-01-25 16:02:28 +01:00
Thomas-Karl Pietrowski e5ecee89a5 Merge remote-tracking branch 'upstream/master' 2015-01-25 14:51:38 +01:00
Thomas-Karl Pietrowski 12eec7398b Caring about which python executable was used for the build 2015-01-25 14:22:26 +01:00
Thomas-Karl Pietrowski 4a056be7bf Making install target flexible 2015-01-25 13:09:36 +01:00
Thomas-Karl Pietrowski 70322ed45c Looks like there is a true difference between "make -c foo" and "cd foo && make" 2015-01-25 12:58:14 +01:00
Thomas-Karl Pietrowski dd6f2ac78e Replacing command with target in doc/Makefile
* The rm command is the same as in ./doc, so in case there has something changed we just need to modify the clean target in ./doc
2015-01-25 11:25:44 +01:00
Thomas-Karl Pietrowski 2cb4d4de21 Building docs with kivy prebuilt
* Adding for that prebuild target which just runs when kivy has not been already built
* Using kivy-already-built stamp for that (seen that method often in debian packaging "in the old days")
* Moving html target to html-embedded (don't know what it is for)
* .. and adding a new html target which builds the html docs like the pdf target
2015-01-25 11:21:51 +01:00
Mathieu Virbel 3fceaac6a9 Merge pull request #2894 from thopiekar/make-doc-build-failsave
Make doc build failsave
2015-01-25 11:11:30 +01:00
Thomas-Karl Pietrowski fcb49997da Don't raise errors on non-created files / dirs which have to be removed 2015-01-24 17:29:43 +01:00
Thomas-Karl Pietrowski d79fd599ba Using pdf target in doc/Makefile directly 2015-01-24 16:50:00 +01:00
Thomas-Karl Pietrowski 6bbe984504 Quick fix: Run git if it is available of course!
Just fixing ifeq to ifneq - makes sense isn't it? ;)
2015-01-24 14:22:31 +01:00
Thomas-Karl Pietrowski 8e6f6220f9 Adding lookup for GIT executable
-> removes the ugly message command not found
-> distclean won't fail now on missing git for distclean

* https://github.com/kivy/kivy/issues/2884
2015-01-24 12:09:09 +01:00
Mathieu Virbel 07e405b9aa doc: fix some versionadded to versionchanged.
Signed-off-by: Mathieu Virbel <mat@kivy.org>
2014-05-23 17:27:18 +02:00
Bastian Venthur 8b93f0362a Don't remove debian subdirectory if it exists on git cleanup.
This doesn't harm if you don't build a Debian package as `git cleanup` will work
just fine if the `debian` directory does not exist. Without this patch the
`distclean` rule will also remove the `debian` directory which make it
impossible to correctly build a debian package.
2014-02-26 17:56:57 +01:00
Mathieu Virbel c84e051a0f graphics: batch deletion of framebuffers/renderbuffers/buffers in one call, using python array module and cython array pointers. Need cython 0.17 minimum, and full recompilation. 2013-04-19 11:18:18 +02:00
Ryan Pessa 95aa4a84a3 * fix `make clean` to remove cythoned .c files 2013-04-03 13:50:09 -05:00
Mathieu Virbel e342fe62af doc: fix signature generation for all methods/functions in a cythonized module. 2013-02-25 16:42:24 +01:00
geojeff 4476b33260 Added KIVY_USE_DEFAULTCONFIG = 1 so that Kivy tests are not affected by local configuration. 2013-02-12 13:31:10 -06:00
Mathieu Virbel de4998be7f ios: fix invalid grep -E 2013-01-04 17:41:13 +01:00