File tree 4 files changed +6
-35
lines changed
4 files changed +6
-35
lines changed Original file line number Diff line number Diff line change @@ -17,9 +17,12 @@ Unreleased
17
17
- Error handling: At two spots in cursor / value converter handling, where
18
18
``assert`` statements have been used, ``ValueError`` exceptions are raised
19
19
now.
20
+ - Python: Migrated to use "implicit namespace packages" instead of "declared
21
+ namespaces" for the ``crate`` namespace package, see `PEP 420`_.
20
22
21
23
22
24
.. _Migrate from crate.client to sqlalchemy-cratedb: https://cratedb.com/docs/sqlalchemy-cratedb/migrate-from-crate-client.html
25
+ .. _PEP 420: https://peps.python.org/pep-0420/
23
26
.. _sqlalchemy-cratedb: https://pypi.org/project/sqlalchemy-cratedb/
24
27
25
28
Original file line number Diff line number Diff line change 22
22
import os
23
23
import re
24
24
25
- from setuptools import find_packages , setup
25
+ from setuptools import find_namespace_packages , setup
26
26
27
27
28
28
def read (path ):
@@ -45,15 +45,14 @@ def read(path):
45
45
url = "https://github.com/crate/crate-python" ,
46
46
author = "Crate.io" ,
47
47
48
- package_dir = {"" : "src" },
49
48
description = "CrateDB Python Client" ,
50
49
long_description = long_description ,
51
50
long_description_content_type = "text/x-rst" ,
52
51
platforms = ["any" ],
53
52
license = "Apache License 2.0" ,
54
53
keywords = "cratedb db api dbapi database sql http rdbms olap" ,
55
- packages = find_packages ("src" ),
56
- namespace_packages = [ "crate" ] ,
54
+ packages = find_namespace_packages ("src" ),
55
+ package_dir = { "" : "src" } ,
57
56
install_requires = [
58
57
"urllib3" ,
59
58
"verlib2" ,
Original file line number Diff line number Diff line change 1
- # -*- coding: utf-8; -*-
2
- #
3
- # Licensed to CRATE Technology GmbH ("Crate") under one or more contributor
4
- # license agreements. See the NOTICE file distributed with this work for
5
- # additional information regarding copyright ownership. Crate licenses
6
- # this file to you under the Apache License, Version 2.0 (the "License");
7
- # you may not use this file except in compliance with the License. You may
8
- # obtain a copy of the License at
9
- #
10
- # http://www.apache.org/licenses/LICENSE-2.0
11
- #
12
- # Unless required by applicable law or agreed to in writing, software
13
- # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
14
- # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
15
- # License for the specific language governing permissions and limitations
16
- # under the License.
17
- #
18
- # However, if you have executed another commercial license agreement
19
- # with Crate these terms will supersede the license and you may use the
20
- # software solely pursuant to the terms of the relevant commercial agreement.
21
-
22
- # this is a namespace package
23
- try :
24
- import pkg_resources
25
-
26
- pkg_resources .declare_namespace (__name__ )
27
- except ImportError :
28
- import pkgutil
29
-
30
- __path__ = pkgutil .extend_path (__path__ , __name__ )
Original file line number Diff line number Diff line change 1
- # package
You can’t perform that action at this time.
0 commit comments