Skip to content

Commit 8cc4137

Browse files
committed
fixed Pandas 2.0 interpreting valid string "None" as NaN (NoneType)
1 parent be50356 commit 8cc4137

File tree

4 files changed

+42
-41
lines changed

4 files changed

+42
-41
lines changed

setup.cfg

Lines changed: 0 additions & 37 deletions
This file was deleted.

setup.py

Lines changed: 40 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,41 @@
1-
from setuptools import setup # type: ignore
1+
from setuptools import setup
2+
from setuptools import find_packages
3+
import re
4+
from pathlib import Path
25

3-
setup()
6+
7+
with Path("Readme.rst").open(encoding="utf-8") as fh:
8+
long_description = fh.read()
9+
10+
with (Path(__file__).resolve().parent / "src" / "DataDriver" / "DataDriver.py").open(encoding="utf-8") as f:
11+
VERSION = re.search('\n__version__ = "(.*)"', f.read()).group(1)
12+
13+
setup(
14+
name="robotframework-datadriver",
15+
version=VERSION,
16+
author="René Rohner(Snooz82)",
17+
author_email="snooz@posteo.de",
18+
description="A library for Data-Driven Testing.",
19+
long_description=long_description,
20+
long_description_content_type="text/x-rst",
21+
url="https://github.com/Snooz82/robotframework-datadriver",
22+
package_dir={"": "src"},
23+
packages=find_packages("src"),
24+
classifiers=[
25+
"Programming Language :: Python :: 3",
26+
"Programming Language :: Python :: 3.6",
27+
"Programming Language :: Python :: 3.7",
28+
"Programming Language :: Python :: 3.8",
29+
"Programming Language :: Python :: 3.9",
30+
"Programming Language :: Python :: 3.10",
31+
"Programming Language :: Python :: 3.11",
32+
"License :: OSI Approved :: Apache Software License",
33+
"Operating System :: OS Independent",
34+
"Topic :: Software Development :: Testing",
35+
"Topic :: Software Development :: Testing :: Acceptance",
36+
"Framework :: Robot Framework",
37+
],
38+
install_requires=["robotframework >= 4.0.2", "docutils", "Pygments"],
39+
extras_require={"xls": ["pandas", "xlrd >= 1.2.0", "openpyxl"]},
40+
python_requires=">=3.7.12",
41+
)

src/DataDriver/DataDriver.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949
warn,
5050
)
5151

52-
__version__ = "1.7.0"
52+
__version__ = "1.8.0"
5353

5454

5555
class DataDriver:

src/DataDriver/xlsx_reader.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,5 +41,5 @@ def get_data_from_source(self):
4141

4242
def read_data_frame_from_file(self, dtype):
4343
return pd.read_excel(
44-
self.file, sheet_name=self.sheet_name, dtype=dtype, engine="openpyxl"
44+
self.file, sheet_name=self.sheet_name, dtype=dtype, engine="openpyxl", na_filter=False
4545
).replace(nan, "", regex=True)

0 commit comments

Comments
 (0)