Skip to content

Commit

Permalink
Merge pull request #1168 from cvvergara/release/2.5
Browse files Browse the repository at this point in the history
Fixes for Release/2.5
  • Loading branch information
cvvergara authored Nov 30, 2018
2 parents 83b8d30 + fd1a594 commit 43fd89d
Show file tree
Hide file tree
Showing 14 changed files with 22,013 additions and 84 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ endif()

set(PGROUTING_VERSION_MAJOR "2")
set(PGROUTING_VERSION_MINOR "5")
set(PGROUTING_VERSION_PATCH "4")
set(PGROUTING_VERSION_PATCH "5")
set(PGROUTING_VERSION_DEV "")

set(PGROUTING_SHORT_VERSION "${PGROUTING_VERSION_MAJOR}.${PGROUTING_VERSION_MINOR}")
Expand Down
12 changes: 12 additions & 0 deletions NEWS
Original file line number Diff line number Diff line change
@@ -1,4 +1,16 @@

pgRouting 2.5.5 Release Notes
-------------------------------------------------------------------------------

To see the issues closed by this release see the [Git closed milestone for 2.5.5 ](https://github.com/pgRouting/pgrouting/issues?utf8=%E2%9C%93&q=milestone%3A%22Release%202.5.5%22%20) on Github.

*Bug fixes*

* Fixes driving distance when vertex is not part of the graph
* Fixes windows test
* Fixes build for python3 and perl5


pgRouting 2.5.4 Release Notes
-------------------------------------------------------------------------------

Expand Down
10 changes: 8 additions & 2 deletions cmake/FindSphinx.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@
# SPHINX_VERSION - the version of Sphinx which was found, e.g. "1.0.7"

#=============================================================================
#
# Copyright (C) 2018 Vicky Vergara
# Modification for python3
#
# Copyright (C) 2011 Marie Rognes and Johannes Ring
# All rights reserved.
#
Expand Down Expand Up @@ -52,10 +56,13 @@ find_program(SPHINX_EXECUTABLE sphinx-build
if (SPHINX_EXECUTABLE)
# Try to check Sphinx version by importing Sphinx
execute_process(
COMMAND ${PYTHON_EXECUTABLE} -c "import sphinx; print sphinx.__version__"
COMMAND ${SPHINX_EXECUTABLE} --version
OUTPUT_VARIABLE SPHINX_VERSION
OUTPUT_STRIP_TRAILING_WHITESPACE)

message(STATUS "SPHINX_VERSION ${SPHINX_VERSION}")
string(REGEX MATCH "[0-9]+\.[0-9]+.\[0-9]+" SPHINX_VERSION "${SPHINX_VERSION}")
message(STATUS "SPHINX_VERSION ${SPHINX_VERSION}")
if (Sphinx_FIND_VERSION)
# Check if version found is >= required version
if (NOT "${SPHINX_VERSION}" VERSION_LESS "${Sphinx_FIND_VERSION}")
Expand All @@ -76,4 +83,3 @@ mark_as_advanced(
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(Sphinx DEFAULT_MSG
SPHINX_EXECUTABLE SPHINX_VERSION_OK)

2 changes: 1 addition & 1 deletion doc/queries/doc-pgr_version.queries
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ SET
SELECT version FROM pgr_version();
version
---------
2.5.4
2.5.5
(1 row)

-- q2
Expand Down
14 changes: 14 additions & 0 deletions doc/src/release_notes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ To see the full list of changes check the list of `Git commits <https://github.c

.. changelog start
* :ref:`changelog_2_5_5`
* :ref:`changelog_2_5_4`
* :ref:`changelog_2_5_3`
* :ref:`changelog_2_5_2`
Expand All @@ -41,6 +42,19 @@ To see the full list of changes check the list of `Git commits <https://github.c

.. changelog end
.. _changelog_2_5_5:

pgRouting 2.5.5 Release Notes
-------------------------------------------------------------------------------

To see the issues closed by this release see the `Git closed milestone for 2.5.5 <https://github.com/pgRouting/pgrouting/issues?utf8=%E2%9C%93&q=milestone%3A%22Release%202.5.5%22%20>`_ on Github.

.. rubric:: Bug fixes

* Fixes driving distance when vertex is not part of the graph
* Fixes windows test
* Fixes build for python3 and perl5

.. _changelog_2_5_4:

pgRouting 2.5.4 Release Notes
Expand Down
2 changes: 1 addition & 1 deletion include/dijkstra/pgr_dijkstra.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -588,7 +588,7 @@ class Pgr_dijkstra {
/*
* The vertex does not exist on the graph
*/
if (pred[i - 1].empty()) {pgassert(false); continue;}
if (pred[i - 1].empty()) break;


/*
Expand Down
111 changes: 111 additions & 0 deletions pgtap/driving_distance/issue1152.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,111 @@
\i setup.sql
\i tmp_net.sql

SELECT plan(71);


CREATE or REPLACE FUNCTION issue1154()
RETURNS SETOF TEXT AS
$BODY$
DECLARE
dd_query TEXT;
dijkstra_sql TEXT;
astar_sql TEXT;
vids TEXT;
data INTEGER[];
cant INTEGER;
BEGIN
data := ARRAY[
28143,37447,43401,50409,91800,
98234,108908,1888,1897,85914,
1898,112714,11851,31406,
37961,43534,50994,57875,71749,
77860,4424,4641,35309,53002,
57762,75549,79856,80019,88626,
89435,116859,37736,51812,97808]::INTEGER[];

RETURN QUERY
SELECT is_empty($$
SELECT * FROM tmp_net WHERE target = 85930
UNION
SELECT * FROM tmp_net WHERE target = 85930
$$);

cant := array_length(data, 1);

FOR i IN 1.. cant LOOP

dd_query := format($$
SELECT
route.node AS node_id,
route.agg_cost
FROM pgr_drivingdistance(
'SELECT * FROM tmp_net',
ARRAY[%1$s, %2$s]::INTEGER[],
2680, equicost:=TRUE, directed:=TRUE) route;
$$, 85930, data[i]);


RETURN QUERY SELECT lives_ok(dd_query, 'i=' || data[i]);

dd_query := format($$
SELECT
route.node AS node_id,
route.agg_cost
FROM pgr_drivingdistance(
'SELECT * FROM tmp_net',
ARRAY[%1$s, %2$s]::INTEGER[],
2680, equicost:=TRUE, directed:=TRUE) route;
$$, data[i], 85930);


RETURN QUERY SELECT lives_ok(dd_query, 'i=' || data[i]);

END LOOP;

RETURN;
END
$BODY$
language plpgsql;

SELECT * FROM issue1154();

SELECT lives_ok($$
SELECT *
FROM pgr_drivingdistance(
'SELECT * FROM tmp_net',
ARRAY[
28143,37447,43401,50409,91800,
98234,108908,1888,1897,85914,
1898,85930,112714,11851,31406,
37961,43534,50994,57875,71749,
77860,4424,4641,35309,53002,
57762,75549,79856,80019,88626,
89435,116859,37736,51812,97808]::INTEGER[],
2680,
equicost:=TRUE,
directed:=TRUE
)
$$);

SELECT bag_has($$
SELECT *
FROM pgr_drivingdistance(
'SELECT * FROM tmp_net',
ARRAY[
28143,37447,43401,50409,91800,
98234,108908,1888,1897,85914,
1898,85930,112714,11851,31406,
37961,43534,50994,57875,71749,
77860,4424,4641,35309,53002,
57762,75549,79856,80019,88626,
89435,116859,37736,51812,97808]::INTEGER[],
2680,
equicost:=TRUE,
directed:=TRUE
)$$,
$$ VALUES (12, 85930, 85930, -1, 0, 0) $$
);

SELECT finish();
ROLLBACK;
1 change: 1 addition & 0 deletions sql/sigs/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
SET(OLD_SIGNATURES
2.5.4
2.5.3
2.5.2
2.5.1
Expand Down
Loading

0 comments on commit 43fd89d

Please sign in to comment.