Skip to content

Staging only: main with the hr regime and the hr-eracun-v1 approval (do not merge) - #1045

Draft
XiaoY-X wants to merge 18 commits into
mainfrom
eu3-hr-staging
Draft

XiaoY-X wants to merge 18 commits into
mainfrom
eu3-hr-staging

Conversation

@XiaoY-X

@XiaoY-X XiaoY-X commented Nov 19, 2026

Copy link
Copy Markdown

Part of EU3-18

Staging only. Do not merge, do not review as a change. This branch exists so that a staging build of the platform can run the Croatian eRačun flow before the release chain lands. It is closed once the releases below exist.

What it is

main (0487f2f6, v0.512.0 plus #1035) with two open pull requests merged in, nothing else:

Merged Head What
#724 d8b87c99 the hr regime
#1044 f4320550 hr-eracun-v1 on the approved external addon list

Both merged without conflicts. Head 3643129, pseudo-version v0.512.1-0.20261118235559-364312914fee.

Who pins it

The eu3-hr-staging branches of gobl.hr.eracun, gobl.dev and silo. Please don't delete, rebase or force-push this branch while they pin it: the commit would become unreachable and their builds would fail.

Checks on the head

  • go generate .: no changes.
  • go test -race ./...: pass (Go 1.25.0).
  • golangci-lint run ./...: 0 issues.

How it goes away

#724 and #1044 merge to main and a GOBL release includes them. The dependents then pin that release and this pull request is closed without merging.

🤖 Generated with Claude Code

migueltorresvalls and others added 18 commits October 19, 2026 18:03
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Replace the Validator and Normalizer callbacks with registered rule sets
for tax.Identity and org.Identity (11-digit format and ISO 7064 MOD 11,10
checksum), add the regime description, sources and invoice scenarios, date
the rates from the VAT Act's commencement on 1 July 2013 with the reduced
rate's rise from 10% to 13% on 1 January 2014, drop the local zero rate in
favour of the global key, and regenerate the schema, rules and example data.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Suppliers that apply the cash accounting scheme (Article 125.i of the
VAT Act) must state "obračun prema naplaćenim naknadama" on the invoice.
The new `cash-basis` tag adds that text as a VAT note. The regime's
invoice scenarios now extend the shared defaults instead of using them
directly, so the reverse-charge note is unchanged.

Part of EU3-18.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Part of EU3-18.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Drop separators and the HR prefix of the VAT number from OIB identity
codes, so an OIB given as "HR 1234-5678-903" validates as 12345678903.
Other letters are kept so that the checksum rule still flags them.

Part of EU3-18.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Consumption tax (porez na potrošnju) is a local tax on drinks served in
catering establishments, under the Local Taxes Act. Each municipality
sets its rate, up to 3%, so the category has no fixed rates and each tax
line gives its percent. The code PP is the one the Croatian eRačun
specification uses (HR-TB-2).
The Croatian eRačun specification lists the packaging return fee
(POVNAK), the special tax on motor vehicles (PPMV) and any other
non-taxable fee (N) as pass-through items: amounts charged together with
taxable items that are left out of the VAT base. Each is a money amount,
not a rate on the price, so it is a line or charge of its own whose
exempt VAT combo carries the new hr-pass-through extension. Declaring
them in the regime instead of a format addon lets invoices to businesses
and to consumers describe them the same way.

The consumption tax is a pass-through item too, but it is a percentage
of the items it applies to, so it keeps its own PP tax category.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Brings in v0.512.0, whose extension tests ask every regime extension for
an issuer-prefixed name and a usage.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
GOBL 0.512 asks every regime extension for a name prefixed with its
issuer and a usage that names the regime. The codes come from the Tax
Administration's eRačun specification, and the extension goes on tax
combos of Croatian invoices.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
POVNAK, PPMV and N are codes of the eRačun HR tax category table
(HR-TB-2), and B2C fiscalization reports them differently, so the
addons declare them instead of the regime. The PP tax category stays.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Staging only: do not merge.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…uild

Staging only: do not merge.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
@codecov

codecov Bot commented Nov 19, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 96.95%. Comparing base (0487f2f) to head (3643129).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1045      +/-   ##
==========================================
+ Coverage   96.93%   96.95%   +0.02%     
==========================================
  Files         336      339       +3     
  Lines       15422    15526     +104     
==========================================
+ Hits        14949    15053     +104     
  Misses        472      472              
  Partials        1        1              

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants