Skip to content

Commit

Permalink
Merge pull request #1732 from CartoDB/release/1.2.1
Browse files Browse the repository at this point in the history
Release/1.2.1
  • Loading branch information
Mmoncadaisla authored Apr 28, 2021
2 parents bf35d2f + 0189152 commit 98e0dae
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 9 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@ 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.1] - 2021-04-28

### Changed

- Avoid batch api to carto create table (#1731)

## [1.2.0] - 2021-03-26

### Changed
Expand Down
8 changes: 4 additions & 4 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ CARTOframes

.. image:: https://travis-ci.org/CartoDB/cartoframes.svg?branch=develop
:target: https://travis-ci.org/CartoDB/cartoframes
.. image:: https://img.shields.io/badge/pypi-v1.2.0-orange
:target: https://pypi.org/project/cartoframes/1.2.0
.. image:: https://img.shields.io/badge/pypi-v1.2.1-orange
:target: https://pypi.org/project/cartoframes/1.2.1

A Python package for integrating `CARTO <https://carto.com/>`__ maps, analysis, and data services into data science workflows.

Expand All @@ -14,11 +14,11 @@ Python data analysis workflows often rely on the de facto standards `pandas <htt
Try it Out
==========

* Stable (1.2.0): |stable|
* Stable (1.2.1): |stable|
* Latest (develop branch): |develop|

.. |stable| image:: https://mybinder.org/badge_logo.svg
:target: https://mybinder.org/v2/gh/cartodb/cartoframes/v1.2.0?filepath=examples
:target: https://mybinder.org/v2/gh/cartodb/cartoframes/v1.2.1?filepath=examples

.. |develop| image:: https://mybinder.org/badge_logo.svg
:target: https://mybinder.org/v2/gh/cartodb/cartoframes/develop?filepath=examples
Expand Down
2 changes: 1 addition & 1 deletion cartoframes/_version.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = '1.2.0'
__version__ = '1.2.1'
4 changes: 2 additions & 2 deletions cartoframes/io/managers/context_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -283,14 +283,14 @@ def _create_table_from_columns(self, table_name, schema, columns, cartodbfy):
query = 'BEGIN; {create}; {cartodbfy}; COMMIT;'.format(
create=_create_table_from_columns_query(table_name, columns),
cartodbfy=_cartodbfy_query(table_name, schema) if cartodbfy else '')
self.execute_long_running_query(query)
self.execute_query(query)

def _truncate_table(self, table_name, schema, cartodbfy):
log.debug('TRUNCATE table "{}"'.format(table_name))
query = 'BEGIN; {truncate}; {cartodbfy}; COMMIT;'.format(
truncate=_truncate_table_query(table_name),
cartodbfy=_cartodbfy_query(table_name, schema) if cartodbfy else '')
self.execute_long_running_query(query)
self.execute_query(query)

def _truncate_and_drop_add_columns(self, table_name, schema, df_columns, table_columns, cartodbfy):
log.debug('TRUNCATE AND DROP + ADD columns table "{}"'.format(table_name))
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ def get_version():
include_package_data=True,

install_requires=REQUIRES,
extras_requires={
extras_require={
'tests': EXTRAS_REQUIRES_TESTS
},
python_requires='>=3.5'
Expand Down
2 changes: 1 addition & 1 deletion tests/unit/io/managers/test_context_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ def test_copy_from(self, mocker):
mocker.patch('cartoframes.io.managers.context_manager._create_auth_client')
mocker.patch.object(ContextManager, 'has_table', return_value=False)
mocker.patch.object(ContextManager, 'get_schema', return_value='schema')
mock_create_table = mocker.patch.object(ContextManager, 'execute_long_running_query')
mock_create_table = mocker.patch.object(ContextManager, 'execute_query')
mock = mocker.patch.object(ContextManager, '_copy_from')
df = DataFrame({'A': [1]})
columns = [ColumnInfo('A', 'a', 'bigint', False)]
Expand Down

0 comments on commit 98e0dae

Please sign in to comment.