Commit Graph

15652 Commits

Author SHA1 Message Date
Raoul Snyman ec479e589b Fix a bunch of linting issues (which should also help resolve other circular dependencies) 2018-10-26 16:15:31 -07:00
Raoul Snyman 4bed8eabed Attempt to remove/reduce circular imports 2018-10-26 11:26:12 -07:00
Phill 891f1dc397 Migrate bibles to use the centeral proxy settings. Upgrade settings and bible meta data accordingly.
bzr-revno: 2837
2018-10-24 20:35:22 +01:00
Bastian Germann cd5939eb3b This fixes setuptools' dependencies according to scripts/check_dependencies.py.
The minimum Python version is set to 3.6 because this was agreed to on the mailing list.
Some packages which are optional in the source are declared as optional (uno, pyenchant, pyodbc).

To overcome a module conflict, openlp.py is replaced with run_openlp.py which setuptools installs as /usr/bin/openlp (or openlp.exe on Windows).

Additionally, pyxdg is replaced with appdirs (see License violations issue).

bzr-revno: 2836
2018-10-24 20:22:28 +02:00
Ken Roberts 67a4100bc1 PJLink2 Update T
bzr-revno: 2835
2018-10-24 20:02:07 +02:00
Philip Ridout aa744e0d99 PEP fixes 2018-10-22 21:42:25 +01:00
Philip Ridout bdec3f407b Remove proxy settings from individual bibles and use the centeral OpenLP proxy server settings. 2018-10-22 21:17:55 +01:00
Ken Roberts a3f2030349 PJLink2 Update T and pep8 2018-10-19 21:33:32 -07:00
Bastian Germann e458622fcc Revert the mediainfo upstreaming
Keep the pymediainfo dependency for later
2018-10-16 22:58:39 +02:00
Bastian Germann 0484d0bf23 Move the openlp.__main__ module to run_openlp 2018-10-16 22:07:00 +02:00
Bastian Germann 3104ca78c3 Document pytest as a test runner 2018-10-16 21:57:43 +02:00
Kyle Russell f325f8d6da Improve usability of image plugin choosegroupform
bzr-revno: 2834
2018-10-16 21:32:21 +02:00
Bastian Germann b11079526d Decode byte string for MediaInfo 2018-10-16 21:24:47 +02:00
Bastian Germann 45a1c3d3f1 Find macOS problem 2018-10-16 21:07:31 +02:00
Bastian Germann 2e39304a1b Find macOS problem 2018-10-16 20:58:51 +02:00
Bastian Germann dd346487f5 Find macOS problem 2018-10-16 20:55:25 +02:00
Bastian Germann ddc66fcd2f Try to fix macOS tests 2018-10-16 20:32:30 +02:00
Bastian Germann 62636c5b27 Update dependencies for appveyor tests 2018-10-16 09:39:42 +02:00
Bastian Germann 7eafbac68d Make Code-Analysis happy 2018-10-16 09:29:58 +02:00
Bastian Germann b5e717a0bd Make Code-Analysis happy 2018-10-16 09:18:48 +02:00
Bastian Germann f0fb9e773d no mandatory icu for tests 2018-10-16 09:09:18 +02:00
Bastian Germann 035bd08a9a pylint3 2018-10-13 11:12:00 +02:00
Bastian Germann ba01cd35e1 Optionally depend on launchpadlib 2018-10-13 00:11:04 +02:00
Bastian Germann e124229040 Try to fix CI 2018-10-11 20:25:53 +02:00
Bastian Germann 0e61b22a10 Add OFL for FontAwesome 2018-10-11 00:05:02 +02:00
Bastian Germann cbb5afa049 Unify module checks with package checks 2018-10-08 10:10:02 +02:00
Bastian Germann 5f23d3adea Use appdirs instead of pyxdg
appdirs is used for all systems except Windows.
It has Windows support, so it could be used there as well.
2018-10-08 01:34:00 +02:00
Bastian Germann bd3015babf Media plugin checks for libmediainfo 2018-10-08 00:05:04 +02:00
Bastian Germann 79e7ea487f Correct the help message 2018-10-07 23:40:36 +02:00
Bastian Germann ce6cb838da pymediainfo's version 2.2 supports new XML 2018-10-07 18:53:10 +02:00
Bastian Germann d1e1975394 Use upstream pymediainfo
Current pymediainfo versions load a DLL/so. Use a very thin
wrapper to make sure that the executable is used if the DLL
is not available.
2018-10-07 02:24:29 +02:00
Bastian Germann 4784cdf152 Reapply OpenLP's changes to pymediainfo 2018-10-07 01:00:18 +02:00
Bastian Germann 7fb3ad4e9e Reimport pymediainfo with its correct license
The mediainfoWrapper.py file was taken from
https://github.com/sbraz/pymediainfo/blob/a24c4b79c5/pymediainfo/__init__.py
and slightly modified.

It is licensed undre MIT but the license information was not copied.
Instead it was relicensed as GPLv2 with OpenLP's default copyright.

This is the original version.
2018-10-07 00:44:01 +02:00
Bastian Germann 9f6b03047b Support running ./setup.py test
setuptools can run tests. Use nose2 to run the tests.
If it is not installed on your system, it is downloaded
and temporarily used.
2018-10-06 22:49:13 +02:00
Bastian Germann 6edd85146d test_get_locale_key needs PyICU 2018-10-06 21:04:09 +02:00
Bastian Germann 1574ecd4f3 Add the optional pyxdg module 2018-10-05 09:26:18 +02:00
Bastian Germann 41bd1d9bb8 Raise minimum Python version to 3.6 2018-10-05 09:24:47 +02:00
Bastian Germann 0b1ba4ba6d Fix setup's requirements
Move the startup script so that its name does not
conflict with the openlp namespace.
Codify scripts/check_dependencies.py in setup.py.
The name on PyPI is used to declare the dependencies.
This is a first step to enable OpenLP distribution via
PyPI.

The differences are:
* pyenchant and pyodbc are declared optional because
  they are optional in the code and pyenchant is not
  maintained anymore.
* pyenchant's required version is set to 1.6 not only
  for windows. This version is quite old.
* The 5.0 version checks for PyQt5 are left out because
  this is the first version anyway.
* LibreOffice's uno does not exist on PyPI
* sqlite3, asyncio and mock are available in Python
  >= 3.4 anyway and not noted as dependencies.
* six is not defined as dependency because the code
  should be py3 only.

The situation with regards to platform wheels being
published looks quite promising.
As Linux users typically install via their package
manager wheel availability is not as import for them
as for Win or Mac users.
Both of them are available for most dependencies with
native extensions.
The few exceptions:
* PyICU does not publish any platform wheels.
  More info: https://github.com/ovalhub/pyicu/issues/79
* mysql-connector-python does not publish win32 wheels.
* pyenchant does not publish win64 wheels.

The wheels are typically available for Py=2.7 and Py>=3.4,
although some (mysql-connector-python, PyQt5, pywin32)
need Py>=3.5
2018-10-03 01:19:49 +02:00
Bastian Germann 5c4ae0a9e6 replace nose with nose2 2018-10-03 00:32:11 +02:00
Kyle Russell 8a5a2628dc Fix pycodestyle line spacing warnings 2018-08-31 20:27:53 -04:00
Kyle Russell 6dc1c37d59 Merge lp:openlp for manifest test resources and font fix 2018-08-31 13:35:30 -04:00
Raoul Snyman c2a60fb0e9 Make our version number PEP 440 compliant and add a script for Jenkins to report back to a merge proposal.
bzr-revno: 2833
2018-08-31 16:46:54 +01:00
Raoul Snyman 8d379e6785 Add some tests, we're up to 52% coverage now! 2018-08-30 22:49:26 -07:00
Kyle Russell c366e58683 Improve usability of image plugin choosegroupform
In order to add an image to an existing group when no group was preselected,
the user must currently choose the existing group name from the comboxbox
and also select the Existing Group radio button.  It should be assumed that
by selecting a group name from the combobox, the user intendeds to add the
image to an existing group, and the accompanying radio button should
automatically be selected.  This reduces the number of required clicks, and
the likelihood of not actually adding the image to the correct group.

Likewise, if a user enters text into the New Group field, the dialog
should assume that the user's intent is to create a new group and auto
select the appropriate radio button.

Also removes some choosegroupdialog specific component logic from mediaitem,
since it's now covered by the choosegroupdialog implementation.  Better
encapsulation, and improves testability. (Testing that the existing group
radio button was selected when choosedialogform was initialized with a
preselected group requires much more effort when the radio button selection
logic spanned two components.)

Adds simple test cases for the scenarios described above.
2018-08-29 23:11:30 -04:00
thelinuxguy 2f465a9dd9 fix warning in reges
bzr-revno: 2832
2018-08-29 19:01:27 +01:00
Tim Bentley c1d09c71c9 fix typo
bzr-revno: 2831
2018-08-29 18:59:17 +01:00
Raoul Snyman 42523cfa86 Fix a problem with the subject in the LP comment; Include test resources and fonts. 2018-08-27 10:48:47 -07:00
Simon Hanna 7321810e78 Improve the regex, removing the displayed warning 2018-08-27 16:16:26 +02:00
Simon Hanna aa4a57a2bf Fix typo 2018-08-26 09:28:43 +02:00
Simon Hanna 9bde7c5fdc Rework a couple of imports. Now a subset of tests can be run again, which previously failed due to circular imports (at least that's what I guess)
bzr-revno: 2830
2018-08-25 17:20:41 -07:00