]> git.ipfire.org Git - thirdparty/python-drafthorse.git/log
thirdparty/python-drafthorse.git
8 months agoUse https for ferd-net.de (#44)
Kh3nsu [Tue, 19 Nov 2024 14:05:31 +0000 (15:05 +0100)] 
Use https for ferd-net.de (#44)

Changed http://www.ferd-net.de/ to https://www.ferd-net.de.
You will be redirected to https anyway, but it is nicer to specify https directly

10 months agoAdded type hints (#36)
Robin Gohmert [Fri, 4 Oct 2024 13:54:23 +0000 (15:54 +0200)] 
Added type hints (#36)

* Added type hints

* Run black

---------

Co-authored-by: Raphael Michel <michel@rami.io>
10 months agoFix #33 -- Fix order of EffectiveSpecifiedPeriod
Raphael Michel [Fri, 4 Oct 2024 13:17:18 +0000 (15:17 +0200)] 
Fix #33 -- Fix order of EffectiveSpecifiedPeriod

10 months agoFix #32 -- Parsing of amount without currency
Raphael Michel [Fri, 4 Oct 2024 13:12:12 +0000 (15:12 +0200)] 
Fix #32 -- Parsing of amount without currency

17 months agoUpdate version to 2.4.0 2.4.0
Raphael Michel [Sun, 10 Mar 2024 15:55:16 +0000 (16:55 +0100)] 
Update version to 2.4.0

17 months agoAdd statement to README
Raphael Michel [Sun, 10 Mar 2024 15:53:57 +0000 (16:53 +0100)] 
Add statement to README

17 months agoFix missing imports in README
Raphael Michel [Sun, 10 Mar 2024 15:49:22 +0000 (16:49 +0100)] 
Fix missing imports in README

17 months agoAdd xml info to pdf metadata2 (#15)
Marko Luther [Sun, 10 Mar 2024 15:47:25 +0000 (16:47 +0100)] 
Add xml info to pdf metadata2 (#15)

* Bump to 2.3.0

* PR #7 Include XML information in PDF metadata (cmcproject)

* update mustang validator

* fixes fx:DocumentFileName / fx:DocumentType order

* remove `schemas/ZUGFeRD2p2_extension_schema.xmp` (replaced by `xmp_schema.py` generator)

* removes date and seller from pdf metadata subject to simplify the code and remove hard coded English language

* removes doc type date and seller from pdf metadata subject (incl. the restriction to documents of type 380) to simplify the code and remove hard coded English language

* remove unused (now) unused constant INVOICE_TYPE_CODE and avoid the use of use bare `except`

* removes failing "Invalid doc type! XML value for TypeCode shall be 380 for an invoice." test

* allows to supply explicit profile level and extends profile auto detection to cover XRECHNUNG

* minor code style improvements like lazy % formatting in logging functions (logging-fstring-interpolation)

* fixes style (black)

* tests of auto detecting a XRechnung v2 and v3 profiles

* blacking again

* tests for en16931 auto profile recognition and auto profile recognition failure

* black again

* typo

* allow users to set custom pdf metadata and the PDF language identifier used by PDF readers for blind people

* black

* spelling

* Update drafthorse/pdf.py

* Run black

---------

Co-authored-by: Raphael Michel <michel@rami.io>
Co-authored-by: Raphael Michel <mail@raphaelmichel.de>
17 months agoAdd SpecifiedLegalOrganization (#28)
Marko Luther [Sun, 10 Mar 2024 15:33:29 +0000 (16:33 +0100)] 
Add SpecifiedLegalOrganization (#28)

* adds SpecifiedLegalOrganization

* fixes typo

* adjusted the documentation of LegalOrganization fit for sellers and buyers

* LegalOrganization.id needs to be an IDField

* black

* updates descriptions

* fixes sequence order

* Update drafthorse/models/party.py

* Update drafthorse/models/party.py

---------

Co-authored-by: Raphael Michel <mail@raphaelmichel.de>
17 months agofixes Issue #20, Issue #22, Issue #26 and Issue #29. It replaces PR #21 and PR #23...
Marko Luther [Sun, 10 Mar 2024 15:28:48 +0000 (16:28 +0100)] 
fixes Issue #20, Issue #22, Issue #26 and Issue #29. It replaces PR #21 and PR #23 and contains alignments to the v2.2 specification (#27)

* - corrects the NS_QDT name according to the zugferd22 specification
- extends elements.py:DateTimeElement to allow the adjustment of the inner DateTimes namespace
- updates references.py:ReferencedDocument to use NS_QDT for its DateTimeElement
- corrects profiles in reference.py for various attributes according to the zugferd22 schemata
- adds test zugferd_2p2_EN16931_ElektronischeAdresse2.xml as a variation of the official zugferd22 sample EN16931_ElektronischeAdresse.xml adding a FormattedIssueDateTime to the BuyerOrderReferencedDocument
- moves SellerOrderReferencedDocument from trade.py to references.py
- fixes DateTimeField namespace of AdvancePayment.received_date

* This commit also adds the class ProductInstance (IndividualTradeProductInstance) to product.py and adds the missing fields "id" (IDField) and "instance" (ProductInstance) to product.py:TradeProduct.

This commit also adds class PayerTradeParty (PayerTradeParty) to party.py and adds the missing field "payer" (PayerTradeParty) to trade.py:TradeSettlement.

This commit also removes the unused (and not needed) party.py:LineApplicableTradeTax class.

This commit also corrects profile and required tags according to the v2.2 specification as follows:

- references.py:LineAdditionalReferencedDocument
  .name profile COMFORT => BASIC (was COMFORT)
- tradelines.py:LineSettlement
  .trade_tax profile COMFORT => BASIC
  .period profile COMFORT => BASIC
  .allowance_charge profile COMFORT => BASIC
  .monetary_summation profile COMFORT => BASIC
  .additional_referenced_document profile EXTENDED => COMFORT
  .accounting_account profile EXTENDED => COMFORT
- product.py:ProductCharacteristic
  .type_code  required => optional
  .description profile EXTENDED => COMFORT
  .value profile EXTENDED => COMFORT
- product.py:ProductClassification
  .class_code required => optional; profile EXTENDED => COMFORT
  .value required => optional
- product.py:TradeProduct
  .name profile COMFORT => BASIC
  .characteristics EXTENDED => COMFORT
  .classifications EXTENDED => COMFORT
  .origins EXTENDED => COMFORT
- trade.py:TradeSettlement
  .tax_currency_code profile COMFORT => BASIC
  .invoicer profile COMFORT => EXTENDED
  .invoicee profile COMFORT => EXTENDED
  .payee profile COMFORT => BASIC
  .allowance_charge profile COMFORT => BASIC
  .service_charge profile COMFORT => EXTENDED
  .terms profile COMFORT => BASIC
  .accounting_account EXTENDED => BASIC
- accounting.py:ApplicableTradeTax
  .exemption_reason COMFORT => BASIC
  .category_code COMFORT => BASIC
  .exemption_reason_code EXTENDED => BASIC

* fixes profile annotations in TradeAllowanceCharge

* SpecifiedTradeAllowanceCharge:ReasonCode in COMFORT

18 months agoCorrects the attribute order of ApplicableTradeTax (#19)
Marko Luther [Fri, 19 Jan 2024 17:12:14 +0000 (18:12 +0100)] 
Corrects the attribute order of ApplicableTradeTax (#19)

* aligns the attribute order of the ApplicableTradeTax class to the TradeTaxType in FACTUR-X_EXTENDED_urn_un_unece_uncefact_data_standard_ReusableAggregateBusinessInformationEntity_100.xsd to fix https://github.com/pretix/python-drafthorse/issues/18

* adds test case

* fix formatting

* sync readme with test_minimal

18 months agoFix country_subdivision field (#25)
Marko Luther [Fri, 19 Jan 2024 15:53:23 +0000 (16:53 +0100)] 
Fix country_subdivision field (#25)

* fixes PostalTradeAddress
- corrects order of elements
- makes country_id required
- downgrades country_subdivision to profile BASIC

* black formatting

23 months agoFixes some typos (Issue #10) (#11)
Marko Luther [Mon, 4 Sep 2023 11:43:32 +0000 (13:43 +0200)] 
Fixes some typos (Issue #10) (#11)

* Fixes some typos (Issue #10)

* Apply suggestions from code review

---------

Co-authored-by: Raphael Michel <mail@raphaelmichel.de>
2 years agoFix #9 -- Encoding of Subtype with pypdf
Raphael Michel [Thu, 15 Jun 2023 20:30:09 +0000 (22:30 +0200)] 
Fix #9 -- Encoding of Subtype with pypdf

2 years agoUpdate ZUGFeRD XML generation (#8)
Marius Crisan [Thu, 15 Jun 2023 20:02:20 +0000 (23:02 +0300)] 
Update ZUGFeRD XML generation (#8)

Co-authored-by: Raphael Michel <mail@raphaelmichel.de>
2 years agoUpgrade pypdf lib and fix generation issues (#6)
cmcproject [Tue, 2 May 2023 08:07:52 +0000 (11:07 +0300)] 
Upgrade pypdf lib and fix generation issues (#6)

2 years agoBump to 2.2.1 2.2.1
Raphael Michel [Wed, 1 Feb 2023 15:38:06 +0000 (16:38 +0100)] 
Bump to 2.2.1

2 years agoFix PyPDF2 deprecation errors
Raphael Michel [Wed, 1 Feb 2023 15:37:53 +0000 (16:37 +0100)] 
Fix PyPDF2 deprecation errors

3 years agoUpdate GitLab CI script
Raphael Michel [Fri, 5 Aug 2022 08:46:10 +0000 (10:46 +0200)] 
Update GitLab CI script

3 years agoBump to 2.2.0 2.2.0
Raphael Michel [Fri, 5 Aug 2022 08:45:01 +0000 (10:45 +0200)] 
Bump to 2.2.0

3 years agoMerge pull request #5 from pretix/2
Raphael Michel [Fri, 5 Aug 2022 08:44:14 +0000 (10:44 +0200)] 
Merge pull request #5 from pretix/2

3 years agoRun black 2 5/head
Raphael Michel [Wed, 3 Aug 2022 15:56:26 +0000 (17:56 +0200)] 
Run black

3 years agoAdd GitHub Actions
Raphael Michel [Wed, 3 Aug 2022 15:36:04 +0000 (17:36 +0200)] 
Add GitHub Actions

3 years agoRun black and isort
Raphael Michel [Wed, 3 Aug 2022 15:33:20 +0000 (17:33 +0200)] 
Run black and isort

3 years agoIncorporate more data model changes
Raphael Michel [Wed, 3 Aug 2022 15:32:41 +0000 (17:32 +0200)] 
Incorporate more data model changes

3 years agoFix PDF embedding
Raphael Michel [Wed, 3 Aug 2022 12:44:56 +0000 (14:44 +0200)] 
Fix PDF embedding

3 years agoAdd instructions on how to validate with Mustang
Raphael Michel [Wed, 3 Aug 2022 12:42:51 +0000 (14:42 +0200)] 
Add instructions on how to validate with Mustang

3 years agoMake samples in README work
Raphael Michel [Wed, 3 Aug 2022 10:55:27 +0000 (12:55 +0200)] 
Make samples in README work

3 years agoAdjust for new PyPDF version
Raphael Michel [Wed, 3 Aug 2022 10:51:54 +0000 (12:51 +0200)] 
Adjust for new PyPDF version

3 years agoDeclare internal attributes as internal and prevent adding new attributes
Raphael Michel [Wed, 3 Aug 2022 10:30:53 +0000 (12:30 +0200)] 
Declare internal attributes as internal and prevent adding new attributes

3 years agoFix imports
Raphael Michel [Wed, 3 Aug 2022 10:28:33 +0000 (12:28 +0200)] 
Fix imports

3 years agoRemove unused imports
Raphael Michel [Wed, 3 Aug 2022 10:27:06 +0000 (12:27 +0200)] 
Remove unused imports

3 years agoFix incorrect import in tests
Raphael Michel [Wed, 3 Aug 2022 10:26:21 +0000 (12:26 +0200)] 
Fix incorrect import in tests

3 years agoFix usage of CurrencyField vs DecimalField
Raphael Michel [Wed, 3 Aug 2022 10:26:04 +0000 (12:26 +0200)] 
Fix usage of CurrencyField vs DecimalField

3 years agoUpdated xmp files to zugferd2.2 requirements
Ben Dangelmayr [Tue, 19 Jul 2022 12:33:32 +0000 (14:33 +0200)] 
Updated xmp files to zugferd2.2 requirements

3 years agoField correction and updated pdf.py to zugferd2.2
Ben Dangelmayr [Tue, 19 Jul 2022 12:11:17 +0000 (14:11 +0200)] 
Field correction and updated pdf.py to zugferd2.2

3 years agoCorrected field properties
Ben Dangelmayr [Tue, 5 Jul 2022 13:57:24 +0000 (15:57 +0200)] 
Corrected field properties

3 years agoAdded minimum and basic-wl schema,tests completing
Ben Dangelmayr [Fri, 3 Jun 2022 11:38:42 +0000 (13:38 +0200)] 
Added minimum and basic-wl schema,tests completing

3 years agoAll tests passing for zugferd2.2, code style
Ben Dangelmayr [Fri, 3 Jun 2022 11:03:07 +0000 (13:03 +0200)] 
All tests passing for zugferd2.2, code style

3 years agoKeep empty fields in parse/generate roundtrip
Raphael Michel [Tue, 31 May 2022 10:24:59 +0000 (12:24 +0200)] 
Keep empty fields in parse/generate roundtrip

3 years agoAdded new fields, added XRECHNUNG samples
Ben Dangelmayr [Tue, 31 May 2022 09:41:48 +0000 (11:41 +0200)] 
Added new fields, added XRECHNUNG samples

3 years agoAdd diff output to test_roundtip
Raphael Michel [Wed, 18 May 2022 14:30:13 +0000 (16:30 +0200)] 
Add diff output to test_roundtip

3 years agoAllow to disable validation
Raphael Michel [Wed, 18 May 2022 14:30:03 +0000 (16:30 +0200)] 
Allow to disable validation

3 years agozugferd v2.2 partial update
Ben Dangelmayr [Wed, 18 May 2022 13:08:39 +0000 (15:08 +0200)] 
zugferd v2.2 partial update

4 years agoFix more tests
Raphael Michel [Mon, 30 Nov 2020 21:59:27 +0000 (22:59 +0100)] 
Fix more tests

4 years agobasic passing
Raphael Michel [Mon, 30 Nov 2020 21:49:57 +0000 (22:49 +0100)] 
basic passing

4 years agoClose to first tests passing
Raphael Michel [Mon, 30 Nov 2020 17:54:10 +0000 (18:54 +0100)] 
Close to first tests passing

4 years agoValidate against new schema
Raphael Michel [Mon, 30 Nov 2020 17:39:42 +0000 (18:39 +0100)] 
Validate against new schema

4 years agoCommit non working tests
Raphael Michel [Mon, 30 Nov 2020 17:29:53 +0000 (18:29 +0100)] 
Commit non working tests

4 years agoFirst version 2 changes
Raphael Michel [Mon, 30 Nov 2020 16:55:00 +0000 (17:55 +0100)] 
First version 2 changes

6 years agoMore linting issues
Raphael Michel [Wed, 12 Dec 2018 15:10:27 +0000 (16:10 +0100)] 
More linting issues

6 years agoFix code style issues
Raphael Michel [Wed, 12 Dec 2018 15:04:37 +0000 (16:04 +0100)] 
Fix code style issues

6 years agoBump version to 1.1.1 1.1.1
Raphael Michel [Wed, 12 Dec 2018 15:02:44 +0000 (16:02 +0100)] 
Bump version to 1.1.1

6 years agoFix validation errors in for PDF/A-3
Raphael Michel [Wed, 12 Dec 2018 15:00:30 +0000 (16:00 +0100)] 
Fix validation errors in for PDF/A-3

6 years agoBump version 1.1.0
Raphael Michel [Tue, 6 Nov 2018 17:43:13 +0000 (18:43 +0100)] 
Bump version

6 years agoChange differences to other ZUGFerd files
Raphael Michel [Mon, 5 Nov 2018 14:20:09 +0000 (15:20 +0100)] 
Change differences to other ZUGFerd files

6 years agoAdd schema
Raphael Michel [Fri, 2 Nov 2018 11:35:11 +0000 (12:35 +0100)] 
Add schema

6 years agoBump version
Raphael Michel [Tue, 30 Oct 2018 13:37:27 +0000 (14:37 +0100)] 
Bump version

6 years agoReturn a proper bytestring
Raphael Michel [Tue, 30 Oct 2018 13:37:10 +0000 (14:37 +0100)] 
Return a proper bytestring

6 years agoMerge pull request #1 from olf42/master
Raphael Michel [Tue, 30 Oct 2018 12:55:51 +0000 (13:55 +0100)] 
Merge pull request #1 from olf42/master

fix: url in setup.py

6 years agofix: url in setup.py 1/head
olf [Tue, 30 Oct 2018 12:45:34 +0000 (13:45 +0100)] 
fix: url in setup.py

* Fixes broken link from PyPI to github

6 years agoAdd credits
Raphael Michel [Tue, 30 Oct 2018 10:06:05 +0000 (11:06 +0100)] 
Add credits

6 years agoisort fixes
Raphael Michel [Tue, 30 Oct 2018 10:01:16 +0000 (11:01 +0100)] 
isort fixes

6 years agoStyle fixes
Raphael Michel [Sun, 28 Oct 2018 14:03:16 +0000 (15:03 +0100)] 
Style fixes

6 years agoBump version number 1.0.0
Raphael Michel [Sat, 27 Oct 2018 21:25:01 +0000 (23:25 +0200)] 
Bump version number

6 years agoAdd PDF generation
Raphael Michel [Sat, 27 Oct 2018 21:23:56 +0000 (23:23 +0200)] 
Add PDF generation

6 years agoFix missing UTF-8 header
Raphael Michel [Thu, 25 Oct 2018 23:24:02 +0000 (01:24 +0200)] 
Fix missing UTF-8 header

6 years agoFix bugs in generation
Raphael Michel [Thu, 25 Oct 2018 21:49:12 +0000 (23:49 +0200)] 
Fix bugs in generation

6 years agoFix flake8 warning
Raphael Michel [Thu, 25 Oct 2018 21:28:27 +0000 (23:28 +0200)] 
Fix flake8 warning

6 years agosetup.py: include_package_data
Raphael Michel [Thu, 25 Oct 2018 19:27:17 +0000 (21:27 +0200)] 
setup.py: include_package_data

6 years agoFix missing setter
Raphael Michel [Thu, 25 Oct 2018 19:26:58 +0000 (21:26 +0200)] 
Fix missing setter

6 years agoAdd Manifest
Raphael Michel [Tue, 16 Oct 2018 19:04:42 +0000 (21:04 +0200)] 
Add Manifest

6 years agoBuild lives on travis.com, not org
Raphael Michel [Tue, 16 Oct 2018 19:03:34 +0000 (21:03 +0200)] 
Build lives on travis.com, not org

6 years agoFix typos
Raphael Michel [Tue, 16 Oct 2018 05:56:35 +0000 (07:56 +0200)] 
Fix typos

6 years agoAdd a README
Raphael Michel [Tue, 16 Oct 2018 05:49:33 +0000 (07:49 +0200)] 
Add a README

6 years agoFix name in setup.py
Raphael Michel [Tue, 16 Oct 2018 05:30:58 +0000 (07:30 +0200)] 
Fix name in setup.py

6 years agoFix import in setup.py
Raphael Michel [Tue, 16 Oct 2018 05:25:44 +0000 (07:25 +0200)] 
Fix import in setup.py

6 years agoInstall dependencies on Travis
Raphael Michel [Tue, 16 Oct 2018 05:22:01 +0000 (07:22 +0200)] 
Install dependencies on Travis

6 years agoCompat for Python 3.5
Raphael Michel [Tue, 16 Oct 2018 05:18:57 +0000 (07:18 +0200)] 
Compat for Python 3.5

6 years agoEnsure object order on Python 3.5
Raphael Michel [Tue, 16 Oct 2018 05:02:44 +0000 (07:02 +0200)] 
Ensure object order on Python 3.5

6 years agoFix style errors
Raphael Michel [Tue, 16 Oct 2018 05:02:08 +0000 (07:02 +0200)] 
Fix style errors

6 years agoMake all official samples pass
Raphael Michel [Mon, 15 Oct 2018 22:55:39 +0000 (00:55 +0200)] 
Make all official samples pass

6 years agoFix style errors
Raphael Michel [Mon, 15 Oct 2018 21:51:27 +0000 (23:51 +0200)] 
Fix style errors

6 years agoSImple roundtrip test
Raphael Michel [Mon, 15 Oct 2018 21:50:42 +0000 (23:50 +0200)] 
SImple roundtrip test

6 years agoAdd simple parser
Raphael Michel [Mon, 15 Oct 2018 20:20:24 +0000 (22:20 +0200)] 
Add simple parser

6 years agoMake demo.py pass validation
Raphael Michel [Mon, 15 Oct 2018 18:54:31 +0000 (20:54 +0200)] 
Make demo.py pass validation

6 years agoFix lint errors
Raphael Michel [Mon, 15 Oct 2018 18:52:56 +0000 (20:52 +0200)] 
Fix lint errors

6 years agoFix wrong namespaces
Raphael Michel [Mon, 15 Oct 2018 18:51:43 +0000 (20:51 +0200)] 
Fix wrong namespaces

6 years agoResolve TODOs
Raphael Michel [Mon, 15 Oct 2018 18:36:29 +0000 (20:36 +0200)] 
Resolve TODOs

6 years agoAdd all models
Raphael Michel [Mon, 15 Oct 2018 18:22:12 +0000 (20:22 +0200)] 
Add all models

6 years agoConstruct schema by sample
Raphael Michel [Sun, 14 Oct 2018 11:05:29 +0000 (13:05 +0200)] 
Construct schema by sample

6 years agoInitial commit
Raphael Michel [Thu, 11 Oct 2018 07:51:51 +0000 (09:51 +0200)] 
Initial commit