pygazpar


Namepygazpar JSON
Version 1.2.0 PyPI version JSON
download
home_pagehttps://github.com/ssenart/pygazpar
SummaryRetrieve gas consumption from GrDF web site (French Gas Company)
upload_time2022-12-16 17:42:53
maintainer
docs_urlNone
authorStephane Senart
requires_python>=3.7
licenseMIT
keywords energy natural gas meter grdf gazpar
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # PyGazpar
PyGazpar is a Python library for getting natural gas consumption from GrDF French provider.

Their natural gas meter is called Gazpar. It is wireless and transmit the gas consumption once per day.

All consumption data is available on the client account at GrDF Web Site (https://monespace.grdf.fr).

PyGazpar automatically goes through the Web Site and download the consumption data, and make it available in a Python structure.

## Installation

### Requirements
PyGazpar does not require Selenium and corresponding geckodriver to work.

With the new GrDF web site, it is possible to load the consumption data far easily than before.

### Create your virtual environment
```bash
$ cd /path/to/my_project_folder/

$ python -m venv .venv
```

### PyGazpar installation
Activate your virtual environment.
```bash
source .venv/bin/activate
```

Use the package manager [pip](https://pip.pypa.io/en/stable/) to install PyGazpar.
```bash
pip install pygazpar
```

You can also download the source code and install it manually.
```bash
cd /path/to/pygazpar/
python setup.py install
```

## Usage

#### Command line:

1. Standard usage (using Json GrDF API).

```bash
$ pygazpar -u 'your login' -p 'your password' -c 'your PCE identifier' --datasource 'json'
```

2. Alternate usage (using Excel GrDF document).

```bash
$ pygazpar -u 'your login' -p 'your password' -c 'your PCE identifier' -t 'temporary directory where to store Excel file (ex: /tmp)' --datasource 'excel'
```

3. Test usage (using local static data files, do not connect to GrDF site).

```bash
$ pygazpar -u 'your login' -p 'your password' -c 'your PCE identifier' --datasource 'test'
```

#### Library:

1. Standard usage (using Json GrDF API).

```python
import pygazpar

client = pygazpar.Client(pygazpar.JsonWebDataSource(
    username='your login',
    password='your password')
)

data = client.loadSince(pceIdentifier='your PCE identifier',
                        lastNDays=60,
                        frequencies=[pygazpar.Frequency.DAILY, pygazpar.Frequency.MONTHLY])
```
See [samples/jsonSample.py](samples/jsonSample.py) file for the full example.

2. Alternate usage (using Excel GrDF document).

```python
import pygazpar

client = pygazpar.Client(pygazpar.ExcelWebDataSource(
    username='your login',
    password='your password')
)

data = client.loadSince(pceIdentifier='your PCE identifier',
                        lastNDays=60,
                        frequencies=[pygazpar.Frequency.DAILY, pygazpar.Frequency.MONTHLY])
```
See [samples/excelSample.py](samples/jsonSample.py) file for the full example.

3. Test usage (using local static data files, do not connect to GrDF site).

```python
import pygazpar

client = pygazpar.Client(pygazpar.TestDataSource())

data = client.loadSince(pceIdentifier='your PCE identifier',
                        lastNDays=10,
                        frequencies=[pygazpar.Frequency.DAILY, Frequency.MONTHLY])
```
See [samples/testSample.py](samples/jsonSample.py) file for the full example.

#### Output:

```json
data =>
{
  "daily": [
    {
      "time_period": "13/10/2022",
      "start_index_m3": 15724,
      "end_index_m3": 15725,
      "volume_m3": 2,
      "energy_kwh": 17,
      "converter_factor_kwh/m3": 11.16,
      "temperature_degC": null,
      "type": "Mesur\u00e9",
      "timestamp": "2022-12-13T23:58:35.606763"
    },
    ...
    {
      "time_period": "11/12/2022",
      "start_index_m3": 16081,
      "end_index_m3": 16098,
      "volume_m3": 18,
      "energy_kwh": 201,
      "converter_factor_kwh/m3": 11.27,
      "temperature_degC": -1.47,
      "type": "Mesur\u00e9",
      "timestamp": "2022-12-13T23:58:35.606763"
    }
  ],
  "monthly": [
    {
      "time_period": "Novembre 2022",
      "start_index_m3": 15750,
      "end_index_m3": 15950,
      "volume_m3": 204,
      "energy_kwh": 2227,
      "timestamp": "2022-12-13T23:58:35.606763"
    },
    {
      "time_period": "D\u00e9cembre 2022",
      "start_index_m3": 15950,
      "end_index_m3": 16098,
      "volume_m3": 148,
      "energy_kwh": 1664,
      "timestamp": "2022-12-13T23:58:35.606763"
    }
  ]
}
```

## Limitation
PyGazpar relies on how GrDF Web Site is built.

Any change in the Web site may break this library.

We expect in close Future that GrDF makes available an open API from which we can get safely their data.

## Contributing
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

## License
[MIT](https://choosealicense.com/licenses/mit/)

## Project status
PyGazpar has been initiated for integration with [Home Assistant](https://www.home-assistant.io/).

Corresponding Home Assistant integration custom component is available [here](https://github.com/ssenart/home-assistant-gazpar).
# Changelog
All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [1.2.0](https://github.com/ssenart/PyGazpar/compare/1.1.6...1.2.0) - 2022-12-16

### Changed
- [#59](https://github.com/ssenart/PyGazpar/issues/59): [Feature] Support both Excel and Json data source format from GrDF site.

- [#60](https://github.com/ssenart/PyGazpar/issues/60): [Feature] Permit to load data at multiple frequencies with one method call.

### Fixed
- [#47](https://github.com/ssenart/PyGazpar/issues/47): [Bug] No temperature field available.

- [#58](https://github.com/ssenart/PyGazpar/issues/58): [Issue] No data update - GrDF web site is half broken - Download button does not work anymore.

## [1.1.6](https://github.com/ssenart/PyGazpar/compare/1.1.5...1.1.6) - 2022-11-16
### Fixed
- [#55](https://github.com/ssenart/PyGazpar/issues/55): Problème de connexion.

## [1.1.5](https://github.com/ssenart/PyGazpar/compare/1.1.4...1.1.5) - 2022-07-11
### Fixed
- [#49](https://github.com/ssenart/PyGazpar/issues/49): Authentication failure.

## [1.1.4](https://github.com/ssenart/PyGazpar/compare/1.1.2...1.1.4) - 2022-01-18
### Changed
- [#43](https://github.com/ssenart/PyGazpar/issues/43): Downloaded Excel file name has changed from Donnees_informatives_PCE_$dateDebut_$dateFin.xlsx to Donnees_informatives_$numeroPCE_$dateDebut_$dateFin.xlsx.

## [1.1.2](https://github.com/ssenart/PyGazpar/compare/1.1.1...1.1.2) - 2022-01-08
### Fixed
- [#39](https://github.com/ssenart/PyGazpar/issues/39): NameError: name 'Frequency' is not defined (thanks [nicolas-r](https://github.com/nicolas-r)).
- Numéro PCE pas forcément un nombre: Le numéro PCE de mon compteur commence par un 0 et lorsque j'essaie de récupérer mes relevés avec PyGazpar, une erreur de l'API est renvoyée. Le numéro PCE ne doit donc pas être converti en int lorsque il est passé en paramètre mais doit être une string (thanks  [maelgangloff](https://github.com/maelgangloff)).

## [1.1.1](https://github.com/ssenart/PyGazpar/compare/1.1.0...1.1.1) - 2021-12-02
### Changed
- Exact same version as 1.1.0 except that 1.1.0 has not been published on Pypi repository.

## [1.1.0](https://github.com/ssenart/PyGazpar/compare/1.0.2...1.1.0) - 2021-12-02
### Changed
- Remove Selenium usage and use simple Web request for login and data retrieval.

## [1.0.2](https://github.com/ssenart/PyGazpar/compare/1.0.1...1.0.2) - 2021-11-25
### Fixed
- Fix broken command line pygazpar caused by adding the new lastNDays parameter.
- Fix the error : ValueError: could not convert string to float: 'Index de début de période (m3)'. It occurs because the records in the Excel file now starts at line 10 instead of line 8 before (thanks to [DEFAYArnaud](https://github.com/DEFAYArnaud) for having spotted the issue and bringing the fix).

### Changed
- In the Excel file, if a cell is empty, then no corresponding key will be inserted in the result dictionary (before we inserted a key with an empty string).

## [1.0.1](https://github.com/ssenart/PyGazpar/compare/1.0.0...1.0.1) - 2021-11-24
### Fixed
- Fix typo warning from Pylance preventing 1.0.0 to be published.

## [1.0.0](https://github.com/ssenart/PyGazpar/compare/0.2.0...1.0.0) - 2021-11-24
### Added
- New lastNDays parameter to query data only over the last N days period.

### Fixed
- [#18](https://github.com/ssenart/PyGazpar/issues/18): PyGazpar broken since GRDF Monespace has been upgraded to a new version.

## [0.2.0](https://github.com/ssenart/PyGazpar/compare/0.1.27...0.2.0) - 2021-04-21
### Added
- [#12](https://github.com/ssenart/PyGazpar/issues/10): Be able to retrieve consumption not only on a daily basis, but weekly and monthly:
    - API : Add a new parameter 'meterReadingFrequency' to Client that accepts enumeration: Frequency.DAILY, Frequency.WEEKLY or Frequency.MONTHLY.
    - Command line : Add a new argument '--frequency' that accepts values : DAILY, WEEKLY or MONTHLY.
- Be able to test using offline data :
    - API : Add a new parameter 'testMode' to Clients used to specify whether we want to get some live data (testMode=False) and static testing data (testMode=True).
    - Command line : Add a new argument '--testMode' (True if specified and False by default).

### Changed
- Some ouput energy property names have changed:
    - 'date' => 'time_period'.
    - 'converter_factor' => 'converter_factor_kwh/m3'.
    - 'local_temperature' => 'temperature_degC'.

## [0.1.27](https://github.com/ssenart/PyGazpar/compare/0.1.26...0.1.27) - 2021-04-20
### Fixed
- [#10](https://github.com/ssenart/PyGazpar/issues/10) : Does not download data file in tmpdir as expected (instead it is downloaded in the default user Download directory). The previous attempt in version 0.1.26 is a failure. The origin of the bug is that we send a relative tmp directory path to Webdriver. Additionally, this path has to be normalized to the runtime OS (using slash or backslash).

## [0.1.26](https://github.com/ssenart/PyGazpar/compare/0.1.25...0.1.26) - 2021-04-18
### Fixed
- [#10](https://github.com/ssenart/PyGazpar/issues/10) : Does not download data file in tmpdir as expected (instead it is downloaded in the default user Download directory).

### Added
- A new parameter to drive whether we want Selenium in headless mode or not (mainly for troubleshooting purpose).

## [0.1.25] - 2021-04-15
### Fixed
- Remove useless warning log messages (log message level has been decreased to debug).

## [0.1.24] - 2021-04-14
### Added
- README.md amendment (thanks to pbranly).

## [0.1.23] - 2021-04-09
### Changed
- Final release with CI/CD workflow improvement.

## [0.1.22] - 2021-04-09
### Changed
- Improve CI/CD workflow.

## [0.1.21] - 2021-04-07
### Changed
- Cleanup some codes managing Privacy Conditions popup.

## [0.1.20] - 2021-04-07
### Changed
- Close an eventual Privacy Conditions popup just before clicking the daily button (instead of Cookie banner).

## [0.1.19] - 2021-04-06
### Added
- Close an eventual Cookie popup just before clicking the daily button.
- Add log messages and screenshot capture around click() and send_keys() methods.

## [0.1.18] - 2021-04-05
### Fixed
- Typo in logger usage.

## [0.1.17] - 2021-04-05
### Fixed
- Logger name must be different in each instance. Using __name__ is a good practice, we can get the module hierarchy.

## [0.1.16] - 2021-04-05
### Fixed
- Logger 'pygazpar' initialization must be done inside the main program and not inside the library.

## [0.1.15] - 2021-04-05
### Added
- Many log message to help debugging if GrDF site changes something : pygazpar.log
- Take a screenshot of the corresponding page where a selenium command fails : error_screenshot.png.

## [0.1.14] - 2020-09-23
### Fixed
- GrDF survey popup has to be closed at the home page.
- GrDF Assistant popup may hide the Download button. We have to close it.
- GrDF bottom banner that invite to accept cookies may also hide the Download button. We have to accept it.

### Added
- A new parameter 'lastNRows' to get only the last N most recent records.

## [0.1.13] - 2020-06-30
### Fixed
- GrDF data retrieval from Excel file is not limited to the 1000 first rows any more.

## [0.1.12] - 2020-06-30
### Fixed
- The previous 0.1.11 is not sufficient. Hence, 2 new changes : First, make configurable the waiting time so the user can adapt to its context usage.
Second, the condition on clicking on Download button is now based on the corresponding event and not anymore on its identifier. 

## [0.1.11] - 2020-06-29
### Fixed
- When GrDF Web site is slower than usual, the client may not wait enough time for pages to load and miss to reach the data file.
It occurs with the page containing 'Jour' button which is very long to load (I increase the wait to load time from 5s to 30s).

## [0.1.10] - 2020-06-03
### Fixed
- Extract rows from Excel until line 1000 (instead of 365 as before).

## [0.1.9] - 2019-08-31
### Fixed
- WebDriver window size must be large enough to display all clickable components.

## [0.1.8] - 2019-08-31
### Changed
- Use PropertyNameEnum type to store all property names.

## [0.1.7] - 2019-08-29
### Added
- Add wait_time option to control how much time the library has to wait for Web page element to load (see https://selenium-python.readthedocs.io/waits.html for details).
- Add LoginError exception raised when PyGazpar is unable to sign in the GrDF Web site with the given username/password.
- Refactor all data property names.

## [0.1.6] - 2019-08-26
### Added
- Add README.md and CHANGELOG.md.
- Add Client.data() method to get the updated data.

### Removed
- Remove Client.data property to get the updated data. Replaced with Client.__data private property.

[0.1.25]: https://github.com/ssenart/PyGazpar/compare/0.1.24...0.1.25
[0.1.24]: https://github.com/ssenart/PyGazpar/compare/0.1.23...0.1.24
[0.1.23]: https://github.com/ssenart/PyGazpar/compare/0.1.22...0.1.23
[0.1.22]: https://github.com/ssenart/PyGazpar/compare/0.1.21...0.1.22
[0.1.21]: https://github.com/ssenart/PyGazpar/compare/0.1.20...0.1.21
[0.1.20]: https://github.com/ssenart/PyGazpar/compare/0.1.19...0.1.20
[0.1.19]: https://github.com/ssenart/PyGazpar/compare/0.1.17...0.1.19
[0.1.18]: https://github.com/ssenart/PyGazpar/compare/0.1.17...0.1.18
[0.1.17]: https://github.com/ssenart/PyGazpar/compare/0.1.16...0.1.17
[0.1.16]: https://github.com/ssenart/PyGazpar/compare/0.1.15...0.1.16
[0.1.15]: https://github.com/ssenart/PyGazpar/compare/0.1.14...0.1.15
[0.1.14]: https://github.com/ssenart/PyGazpar/compare/0.1.13...0.1.14
[0.1.13]: https://github.com/ssenart/PyGazpar/compare/0.1.12...0.1.13
[0.1.12]: https://github.com/ssenart/PyGazpar/compare/0.1.11...0.1.12
[0.1.11]: https://github.com/ssenart/PyGazpar/compare/0.1.10...0.1.11
[0.1.10]: https://github.com/ssenart/PyGazpar/compare/0.1.9...0.1.10
[0.1.9]: https://github.com/ssenart/PyGazpar/compare/0.1.7...0.1.9
[0.1.8]: https://github.com/ssenart/PyGazpar/compare/0.1.7...0.1.8
[0.1.7]: https://github.com/ssenart/PyGazpar/compare/0.1.6...0.1.7
[0.1.6]: https://github.com/ssenart/PyGazpar/compare/0.1.5...0.1.6

MIT License

Copyright (c) 2019 Stéphane Senart

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.



            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/ssenart/pygazpar",
    "name": "pygazpar",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.7",
    "maintainer_email": "",
    "keywords": "Energy,Natural Gas,Meter,GrDF,Gazpar",
    "author": "Stephane Senart",
    "author_email": "stephane.senart@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/6a/59/d14125a9befbd83753e61faa412c83190b79a5a364143240442f99d01723/pygazpar-1.2.0.tar.gz",
    "platform": "any",
    "description": "# PyGazpar\nPyGazpar is a Python library for getting natural gas consumption from GrDF French provider.\n\nTheir natural gas meter is called Gazpar. It is wireless and transmit the gas consumption once per day.\n\nAll consumption data is available on the client account at GrDF Web Site (https://monespace.grdf.fr).\n\nPyGazpar automatically goes through the Web Site and download the consumption data, and make it available in a Python structure.\n\n## Installation\n\n### Requirements\nPyGazpar does not require Selenium and corresponding geckodriver to work.\n\nWith the new GrDF web site, it is possible to load the consumption data far easily than before.\n\n### Create your virtual environment\n```bash\n$ cd /path/to/my_project_folder/\n\n$ python -m venv .venv\n```\n\n### PyGazpar installation\nActivate your virtual environment.\n```bash\nsource .venv/bin/activate\n```\n\nUse the package manager [pip](https://pip.pypa.io/en/stable/) to install PyGazpar.\n```bash\npip install pygazpar\n```\n\nYou can also download the source code and install it manually.\n```bash\ncd /path/to/pygazpar/\npython setup.py install\n```\n\n## Usage\n\n#### Command line:\n\n1. Standard usage (using Json GrDF API).\n\n```bash\n$ pygazpar -u 'your login' -p 'your password' -c 'your PCE identifier' --datasource 'json'\n```\n\n2. Alternate usage (using Excel GrDF document).\n\n```bash\n$ pygazpar -u 'your login' -p 'your password' -c 'your PCE identifier' -t 'temporary directory where to store Excel file (ex: /tmp)' --datasource 'excel'\n```\n\n3. Test usage (using local static data files, do not connect to GrDF site).\n\n```bash\n$ pygazpar -u 'your login' -p 'your password' -c 'your PCE identifier' --datasource 'test'\n```\n\n#### Library:\n\n1. Standard usage (using Json GrDF API).\n\n```python\nimport pygazpar\n\nclient = pygazpar.Client(pygazpar.JsonWebDataSource(\n    username='your login',\n    password='your password')\n)\n\ndata = client.loadSince(pceIdentifier='your PCE identifier',\n                        lastNDays=60,\n                        frequencies=[pygazpar.Frequency.DAILY, pygazpar.Frequency.MONTHLY])\n```\nSee [samples/jsonSample.py](samples/jsonSample.py) file for the full example.\n\n2. Alternate usage (using Excel GrDF document).\n\n```python\nimport pygazpar\n\nclient = pygazpar.Client(pygazpar.ExcelWebDataSource(\n    username='your login',\n    password='your password')\n)\n\ndata = client.loadSince(pceIdentifier='your PCE identifier',\n                        lastNDays=60,\n                        frequencies=[pygazpar.Frequency.DAILY, pygazpar.Frequency.MONTHLY])\n```\nSee [samples/excelSample.py](samples/jsonSample.py) file for the full example.\n\n3. Test usage (using local static data files, do not connect to GrDF site).\n\n```python\nimport pygazpar\n\nclient = pygazpar.Client(pygazpar.TestDataSource())\n\ndata = client.loadSince(pceIdentifier='your PCE identifier',\n                        lastNDays=10,\n                        frequencies=[pygazpar.Frequency.DAILY, Frequency.MONTHLY])\n```\nSee [samples/testSample.py](samples/jsonSample.py) file for the full example.\n\n#### Output:\n\n```json\ndata =>\n{\n  \"daily\": [\n    {\n      \"time_period\": \"13/10/2022\",\n      \"start_index_m3\": 15724,\n      \"end_index_m3\": 15725,\n      \"volume_m3\": 2,\n      \"energy_kwh\": 17,\n      \"converter_factor_kwh/m3\": 11.16,\n      \"temperature_degC\": null,\n      \"type\": \"Mesur\\u00e9\",\n      \"timestamp\": \"2022-12-13T23:58:35.606763\"\n    },\n    ...\n    {\n      \"time_period\": \"11/12/2022\",\n      \"start_index_m3\": 16081,\n      \"end_index_m3\": 16098,\n      \"volume_m3\": 18,\n      \"energy_kwh\": 201,\n      \"converter_factor_kwh/m3\": 11.27,\n      \"temperature_degC\": -1.47,\n      \"type\": \"Mesur\\u00e9\",\n      \"timestamp\": \"2022-12-13T23:58:35.606763\"\n    }\n  ],\n  \"monthly\": [\n    {\n      \"time_period\": \"Novembre 2022\",\n      \"start_index_m3\": 15750,\n      \"end_index_m3\": 15950,\n      \"volume_m3\": 204,\n      \"energy_kwh\": 2227,\n      \"timestamp\": \"2022-12-13T23:58:35.606763\"\n    },\n    {\n      \"time_period\": \"D\\u00e9cembre 2022\",\n      \"start_index_m3\": 15950,\n      \"end_index_m3\": 16098,\n      \"volume_m3\": 148,\n      \"energy_kwh\": 1664,\n      \"timestamp\": \"2022-12-13T23:58:35.606763\"\n    }\n  ]\n}\n```\n\n## Limitation\nPyGazpar relies on how GrDF Web Site is built.\n\nAny change in the Web site may break this library.\n\nWe expect in close Future that GrDF makes available an open API from which we can get safely their data.\n\n## Contributing\nPull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.\n\nPlease make sure to update tests as appropriate.\n\n## License\n[MIT](https://choosealicense.com/licenses/mit/)\n\n## Project status\nPyGazpar has been initiated for integration with [Home Assistant](https://www.home-assistant.io/).\n\nCorresponding Home Assistant integration custom component is available [here](https://github.com/ssenart/home-assistant-gazpar).\n# Changelog\nAll notable changes to this project will be documented in this file.\n\nThe format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),\nand this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).\n\n## [1.2.0](https://github.com/ssenart/PyGazpar/compare/1.1.6...1.2.0) - 2022-12-16\n\n### Changed\n- [#59](https://github.com/ssenart/PyGazpar/issues/59): [Feature] Support both Excel and Json data source format from GrDF site.\n\n- [#60](https://github.com/ssenart/PyGazpar/issues/60): [Feature] Permit to load data at multiple frequencies with one method call.\n\n### Fixed\n- [#47](https://github.com/ssenart/PyGazpar/issues/47): [Bug] No temperature field available.\n\n- [#58](https://github.com/ssenart/PyGazpar/issues/58): [Issue] No data update - GrDF web site is half broken - Download button does not work anymore.\n\n## [1.1.6](https://github.com/ssenart/PyGazpar/compare/1.1.5...1.1.6) - 2022-11-16\n### Fixed\n- [#55](https://github.com/ssenart/PyGazpar/issues/55): Probl\u00e8me de connexion.\n\n## [1.1.5](https://github.com/ssenart/PyGazpar/compare/1.1.4...1.1.5) - 2022-07-11\n### Fixed\n- [#49](https://github.com/ssenart/PyGazpar/issues/49): Authentication failure.\n\n## [1.1.4](https://github.com/ssenart/PyGazpar/compare/1.1.2...1.1.4) - 2022-01-18\n### Changed\n- [#43](https://github.com/ssenart/PyGazpar/issues/43): Downloaded Excel file name has changed from Donnees_informatives_PCE_$dateDebut_$dateFin.xlsx to Donnees_informatives_$numeroPCE_$dateDebut_$dateFin.xlsx.\n\n## [1.1.2](https://github.com/ssenart/PyGazpar/compare/1.1.1...1.1.2) - 2022-01-08\n### Fixed\n- [#39](https://github.com/ssenart/PyGazpar/issues/39): NameError: name 'Frequency' is not defined (thanks [nicolas-r](https://github.com/nicolas-r)).\n- Num\u00e9ro PCE pas forc\u00e9ment un nombre: Le num\u00e9ro PCE de mon compteur commence par un 0 et lorsque j'essaie de r\u00e9cup\u00e9rer mes relev\u00e9s avec PyGazpar, une erreur de l'API est renvoy\u00e9e. Le num\u00e9ro PCE ne doit donc pas \u00eatre converti en int lorsque il est pass\u00e9 en param\u00e8tre mais doit \u00eatre une string (thanks  [maelgangloff](https://github.com/maelgangloff)).\n\n## [1.1.1](https://github.com/ssenart/PyGazpar/compare/1.1.0...1.1.1) - 2021-12-02\n### Changed\n- Exact same version as 1.1.0 except that 1.1.0 has not been published on Pypi repository.\n\n## [1.1.0](https://github.com/ssenart/PyGazpar/compare/1.0.2...1.1.0) - 2021-12-02\n### Changed\n- Remove Selenium usage and use simple Web request for login and data retrieval.\n\n## [1.0.2](https://github.com/ssenart/PyGazpar/compare/1.0.1...1.0.2) - 2021-11-25\n### Fixed\n- Fix broken command line pygazpar caused by adding the new lastNDays parameter.\n- Fix the error : ValueError: could not convert string to float: 'Index de d\u00e9but de p\u00e9riode (m3)'. It occurs because the records in the Excel file now starts at line 10 instead of line 8 before (thanks to [DEFAYArnaud](https://github.com/DEFAYArnaud) for having spotted the issue and bringing the fix).\n\n### Changed\n- In the Excel file, if a cell is empty, then no corresponding key will be inserted in the result dictionary (before we inserted a key with an empty string).\n\n## [1.0.1](https://github.com/ssenart/PyGazpar/compare/1.0.0...1.0.1) - 2021-11-24\n### Fixed\n- Fix typo warning from Pylance preventing 1.0.0 to be published.\n\n## [1.0.0](https://github.com/ssenart/PyGazpar/compare/0.2.0...1.0.0) - 2021-11-24\n### Added\n- New lastNDays parameter to query data only over the last N days period.\n\n### Fixed\n- [#18](https://github.com/ssenart/PyGazpar/issues/18): PyGazpar broken since GRDF Monespace has been upgraded to a new version.\n\n## [0.2.0](https://github.com/ssenart/PyGazpar/compare/0.1.27...0.2.0) - 2021-04-21\n### Added\n- [#12](https://github.com/ssenart/PyGazpar/issues/10): Be able to retrieve consumption not only on a daily basis, but weekly and monthly:\n    - API : Add a new parameter 'meterReadingFrequency' to Client that accepts enumeration: Frequency.DAILY, Frequency.WEEKLY or Frequency.MONTHLY.\n    - Command line : Add a new argument '--frequency' that accepts values : DAILY, WEEKLY or MONTHLY.\n- Be able to test using offline data :\n    - API : Add a new parameter 'testMode' to Clients used to specify whether we want to get some live data (testMode=False) and static testing data (testMode=True).\n    - Command line : Add a new argument '--testMode' (True if specified and False by default).\n\n### Changed\n- Some ouput energy property names have changed:\n    - 'date' => 'time_period'.\n    - 'converter_factor' => 'converter_factor_kwh/m3'.\n    - 'local_temperature' => 'temperature_degC'.\n\n## [0.1.27](https://github.com/ssenart/PyGazpar/compare/0.1.26...0.1.27) - 2021-04-20\n### Fixed\n- [#10](https://github.com/ssenart/PyGazpar/issues/10) : Does not download data file in tmpdir as expected (instead it is downloaded in the default user Download directory). The previous attempt in version 0.1.26 is a failure. The origin of the bug is that we send a relative tmp directory path to Webdriver. Additionally, this path has to be normalized to the runtime OS (using slash or backslash).\n\n## [0.1.26](https://github.com/ssenart/PyGazpar/compare/0.1.25...0.1.26) - 2021-04-18\n### Fixed\n- [#10](https://github.com/ssenart/PyGazpar/issues/10) : Does not download data file in tmpdir as expected (instead it is downloaded in the default user Download directory).\n\n### Added\n- A new parameter to drive whether we want Selenium in headless mode or not (mainly for troubleshooting purpose).\n\n## [0.1.25] - 2021-04-15\n### Fixed\n- Remove useless warning log messages (log message level has been decreased to debug).\n\n## [0.1.24] - 2021-04-14\n### Added\n- README.md amendment (thanks to pbranly).\n\n## [0.1.23] - 2021-04-09\n### Changed\n- Final release with CI/CD workflow improvement.\n\n## [0.1.22] - 2021-04-09\n### Changed\n- Improve CI/CD workflow.\n\n## [0.1.21] - 2021-04-07\n### Changed\n- Cleanup some codes managing Privacy Conditions popup.\n\n## [0.1.20] - 2021-04-07\n### Changed\n- Close an eventual Privacy Conditions popup just before clicking the daily button (instead of Cookie banner).\n\n## [0.1.19] - 2021-04-06\n### Added\n- Close an eventual Cookie popup just before clicking the daily button.\n- Add log messages and screenshot capture around click() and send_keys() methods.\n\n## [0.1.18] - 2021-04-05\n### Fixed\n- Typo in logger usage.\n\n## [0.1.17] - 2021-04-05\n### Fixed\n- Logger name must be different in each instance. Using __name__ is a good practice, we can get the module hierarchy.\n\n## [0.1.16] - 2021-04-05\n### Fixed\n- Logger 'pygazpar' initialization must be done inside the main program and not inside the library.\n\n## [0.1.15] - 2021-04-05\n### Added\n- Many log message to help debugging if GrDF site changes something : pygazpar.log\n- Take a screenshot of the corresponding page where a selenium command fails : error_screenshot.png.\n\n## [0.1.14] - 2020-09-23\n### Fixed\n- GrDF survey popup has to be closed at the home page.\n- GrDF Assistant popup may hide the Download button. We have to close it.\n- GrDF bottom banner that invite to accept cookies may also hide the Download button. We have to accept it.\n\n### Added\n- A new parameter 'lastNRows' to get only the last N most recent records.\n\n## [0.1.13] - 2020-06-30\n### Fixed\n- GrDF data retrieval from Excel file is not limited to the 1000 first rows any more.\n\n## [0.1.12] - 2020-06-30\n### Fixed\n- The previous 0.1.11 is not sufficient. Hence, 2 new changes : First, make configurable the waiting time so the user can adapt to its context usage.\nSecond, the condition on clicking on Download button is now based on the corresponding event and not anymore on its identifier. \n\n## [0.1.11] - 2020-06-29\n### Fixed\n- When GrDF Web site is slower than usual, the client may not wait enough time for pages to load and miss to reach the data file.\nIt occurs with the page containing 'Jour' button which is very long to load (I increase the wait to load time from 5s to 30s).\n\n## [0.1.10] - 2020-06-03\n### Fixed\n- Extract rows from Excel until line 1000 (instead of 365 as before).\n\n## [0.1.9] - 2019-08-31\n### Fixed\n- WebDriver window size must be large enough to display all clickable components.\n\n## [0.1.8] - 2019-08-31\n### Changed\n- Use PropertyNameEnum type to store all property names.\n\n## [0.1.7] - 2019-08-29\n### Added\n- Add wait_time option to control how much time the library has to wait for Web page element to load (see https://selenium-python.readthedocs.io/waits.html for details).\n- Add LoginError exception raised when PyGazpar is unable to sign in the GrDF Web site with the given username/password.\n- Refactor all data property names.\n\n## [0.1.6] - 2019-08-26\n### Added\n- Add README.md and CHANGELOG.md.\n- Add Client.data() method to get the updated data.\n\n### Removed\n- Remove Client.data property to get the updated data. Replaced with Client.__data private property.\n\n[0.1.25]: https://github.com/ssenart/PyGazpar/compare/0.1.24...0.1.25\n[0.1.24]: https://github.com/ssenart/PyGazpar/compare/0.1.23...0.1.24\n[0.1.23]: https://github.com/ssenart/PyGazpar/compare/0.1.22...0.1.23\n[0.1.22]: https://github.com/ssenart/PyGazpar/compare/0.1.21...0.1.22\n[0.1.21]: https://github.com/ssenart/PyGazpar/compare/0.1.20...0.1.21\n[0.1.20]: https://github.com/ssenart/PyGazpar/compare/0.1.19...0.1.20\n[0.1.19]: https://github.com/ssenart/PyGazpar/compare/0.1.17...0.1.19\n[0.1.18]: https://github.com/ssenart/PyGazpar/compare/0.1.17...0.1.18\n[0.1.17]: https://github.com/ssenart/PyGazpar/compare/0.1.16...0.1.17\n[0.1.16]: https://github.com/ssenart/PyGazpar/compare/0.1.15...0.1.16\n[0.1.15]: https://github.com/ssenart/PyGazpar/compare/0.1.14...0.1.15\n[0.1.14]: https://github.com/ssenart/PyGazpar/compare/0.1.13...0.1.14\n[0.1.13]: https://github.com/ssenart/PyGazpar/compare/0.1.12...0.1.13\n[0.1.12]: https://github.com/ssenart/PyGazpar/compare/0.1.11...0.1.12\n[0.1.11]: https://github.com/ssenart/PyGazpar/compare/0.1.10...0.1.11\n[0.1.10]: https://github.com/ssenart/PyGazpar/compare/0.1.9...0.1.10\n[0.1.9]: https://github.com/ssenart/PyGazpar/compare/0.1.7...0.1.9\n[0.1.8]: https://github.com/ssenart/PyGazpar/compare/0.1.7...0.1.8\n[0.1.7]: https://github.com/ssenart/PyGazpar/compare/0.1.6...0.1.7\n[0.1.6]: https://github.com/ssenart/PyGazpar/compare/0.1.5...0.1.6\n\nMIT License\n\nCopyright (c) 2019 St\u00e9phane Senart\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n\n\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Retrieve gas consumption from GrDF web site (French Gas Company)",
    "version": "1.2.0",
    "project_urls": {
        "Changelog": "https://github.com/ssenart/PyGazpar/blob/master/CHANGELOG.md",
        "Download": "https://pypi.org/project/pygazpar",
        "Home": "https://github.com/ssenart/pygazpar",
        "Homepage": "https://github.com/ssenart/pygazpar",
        "Issues": "https://github.com/ssenart/PyGazpar/issues",
        "Source": "https://github.com/ssenart/pygazpar"
    },
    "split_keywords": [
        "energy",
        "natural gas",
        "meter",
        "grdf",
        "gazpar"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "1aa30bfc9ca531cec1806e6d0ca7989a8e63d408e3ed74da71987d979f843a85",
                "md5": "364dc5ee4de13a66122dcf3cd722f989",
                "sha256": "010996aab4ac7cd730341ed1f77ce9fcfd3725b0e03caf775424cb7df43cdc66"
            },
            "downloads": -1,
            "filename": "pygazpar-1.2.0-py310-none-any.whl",
            "has_sig": false,
            "md5_digest": "364dc5ee4de13a66122dcf3cd722f989",
            "packagetype": "bdist_wheel",
            "python_version": "py310",
            "requires_python": ">=3.7",
            "size": 36342,
            "upload_time": "2022-12-16T17:43:07",
            "upload_time_iso_8601": "2022-12-16T17:43:07.510117Z",
            "url": "https://files.pythonhosted.org/packages/1a/a3/0bfc9ca531cec1806e6d0ca7989a8e63d408e3ed74da71987d979f843a85/pygazpar-1.2.0-py310-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "859f407735d675c8d65412cc107c554b6e0286d1cc3a21d625a2660de3dfaf56",
                "md5": "b8fcb2a340afa503c2961fd068f54494",
                "sha256": "4d166c1ad3faf93478f4d25000d4c17fd43c73c0129125849a6f8cff3e155c59"
            },
            "downloads": -1,
            "filename": "pygazpar-1.2.0-py311-none-any.whl",
            "has_sig": false,
            "md5_digest": "b8fcb2a340afa503c2961fd068f54494",
            "packagetype": "bdist_wheel",
            "python_version": "py311",
            "requires_python": ">=3.7",
            "size": 36342,
            "upload_time": "2022-12-16T17:43:08",
            "upload_time_iso_8601": "2022-12-16T17:43:08.455869Z",
            "url": "https://files.pythonhosted.org/packages/85/9f/407735d675c8d65412cc107c554b6e0286d1cc3a21d625a2660de3dfaf56/pygazpar-1.2.0-py311-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "74579a79d2baebcfed21fce6f2eacc78b4a0469189a289918bf4fc25050e713b",
                "md5": "74cf495add53dc224de59f9ed3aa2886",
                "sha256": "8953f8ad8338396702eceb3b5e8feb2ee20b0b4a56fb0c80a3e9eb9c63254e0a"
            },
            "downloads": -1,
            "filename": "pygazpar-1.2.0-py37-none-any.whl",
            "has_sig": false,
            "md5_digest": "74cf495add53dc224de59f9ed3aa2886",
            "packagetype": "bdist_wheel",
            "python_version": "py37",
            "requires_python": ">=3.7",
            "size": 36326,
            "upload_time": "2022-12-16T17:42:51",
            "upload_time_iso_8601": "2022-12-16T17:42:51.990279Z",
            "url": "https://files.pythonhosted.org/packages/74/57/9a79d2baebcfed21fce6f2eacc78b4a0469189a289918bf4fc25050e713b/pygazpar-1.2.0-py37-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "0b8b6acdd71f7caed447d65c571e64e8d478141ded6606edf23993ad9308cbbb",
                "md5": "5492dfc0cb18dfd96634039090cafb37",
                "sha256": "891e93dbb29a063430517a8efb406959c3300b89c567d20a519e8886d1cf3f10"
            },
            "downloads": -1,
            "filename": "pygazpar-1.2.0-py38-none-any.whl",
            "has_sig": false,
            "md5_digest": "5492dfc0cb18dfd96634039090cafb37",
            "packagetype": "bdist_wheel",
            "python_version": "py38",
            "requires_python": ">=3.7",
            "size": 36326,
            "upload_time": "2022-12-16T17:42:54",
            "upload_time_iso_8601": "2022-12-16T17:42:54.570376Z",
            "url": "https://files.pythonhosted.org/packages/0b/8b/6acdd71f7caed447d65c571e64e8d478141ded6606edf23993ad9308cbbb/pygazpar-1.2.0-py38-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "3c974d4d4591365e86ce2cec44741233a30d009ed8fa0a3343025eb4ee8221e1",
                "md5": "45d7757ff2c39a8c83e796e94fe15c78",
                "sha256": "84f4ba6fdb7cd7533b3e6c8cc08d0136524dad243089087bae3489c064096f49"
            },
            "downloads": -1,
            "filename": "pygazpar-1.2.0-py39-none-any.whl",
            "has_sig": false,
            "md5_digest": "45d7757ff2c39a8c83e796e94fe15c78",
            "packagetype": "bdist_wheel",
            "python_version": "py39",
            "requires_python": ">=3.7",
            "size": 36341,
            "upload_time": "2022-12-16T17:43:07",
            "upload_time_iso_8601": "2022-12-16T17:43:07.315600Z",
            "url": "https://files.pythonhosted.org/packages/3c/97/4d4d4591365e86ce2cec44741233a30d009ed8fa0a3343025eb4ee8221e1/pygazpar-1.2.0-py39-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "6a59d14125a9befbd83753e61faa412c83190b79a5a364143240442f99d01723",
                "md5": "e74e5e4d6cd08bec6e68e0955cf82eff",
                "sha256": "089ef97c1caa0037f37cfb0fdad0beb3648ee5ae89cae800e04c09470dcd6bad"
            },
            "downloads": -1,
            "filename": "pygazpar-1.2.0.tar.gz",
            "has_sig": false,
            "md5_digest": "e74e5e4d6cd08bec6e68e0955cf82eff",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.7",
            "size": 35475,
            "upload_time": "2022-12-16T17:42:53",
            "upload_time_iso_8601": "2022-12-16T17:42:53.700286Z",
            "url": "https://files.pythonhosted.org/packages/6a/59/d14125a9befbd83753e61faa412c83190b79a5a364143240442f99d01723/pygazpar-1.2.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2022-12-16 17:42:53",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "ssenart",
    "github_project": "pygazpar",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "requirements": [],
    "lcname": "pygazpar"
}
        
Elapsed time: 0.26655s