Skip to main content

france-naf

Python accessors to NAF/APE codes.

From https://www.insee.fr/fr/information/2406147

Installation

pip install france-naf

Usage

from naf import DB

# Get one NAF object
my_naf = DB["02.30Z"]
print(my_naf)

# "Récolte de produits forestiers non ligneux poussant à l'état sauvage"
"02.30Z" in DB
# True
print(my_naf.section) or print(my_naf.section.code)
# 'A'
print(my_naf.section.description)
# 'AGRICULTURE, SYLVICULTURE ET PÊCHE'

dict(my_naf)
# {'code': '02.30Z',
# 'description': "Récolte de produits forestiers non ligneux poussant à l'état sauvage",
# 'classe': {'code': '02.30',
#  'description': "Récolte de produits forestiers non ligneux poussant à l'état sauvage"},
# 'group': {'code': '02.3',
#  'description': "Récolte de produits forestiers non ligneux poussant à l'état sauvage"},
# 'division': {'code': '02',
#  'description': 'Sylviculture et exploitation forestière'},
# 'section': {'code': 'A', 'description': 'AGRICULTURE, SYLVICULTURE ET PÊCHE'}}

# Iter over NAF objects
for naf in DB:
    do_something_with(naf)
# Iter over code, description
for code, description in DB.pairs():
    pass
# Get the whole DB as a json string
str(DB)

Metadata

Release files for france-naf 20210301

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for france-naf 20210301
File Size Uploaded Provenance Actions
france-naf-20210301.tar.gz 28.8 kB Without provenance Details for france-naf-20210301.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for france-naf 20210301
File Interpreter ABI Platform Actions
france_naf-20210301-py3-none-any.whl Python 3 none any Details for france_naf-20210301-py3-none-any.whl

Total release size: 58.8 kB

Release files / france-naf-20210301.tar.gz

Download URL france-naf-20210301.tar.gz
Size 28.8 kB
Tags Source
SHA-256 checksum
How to use checksums
eeaa542abd498a6f97060f62793f1cfa18599cf0489cdc81d62cde35f5433c52
BLAKE2b-256 checksum
How to use checksums
dc5e43bf5d1fbd7904e3d9ccb1b79f7155dd4ff87673fb8e75452a60b7551815
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.9.2

Release files / france_naf-20210301-py3-none-any.whl

Download URL france_naf-20210301-py3-none-any.whl
Size 30.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
90caa5b6c33b728dacfee7be705935653cba70782933a1cbb7bfd409e8f13c99
BLAKE2b-256 checksum
How to use checksums
18aca15041dc0513188b611ffdd67066fff9a334d1e2dca8126227e1e9522160
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.9.2

Security for france-naf 20210301

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page