Fix date matching failure
(cherry picked from commit cf168259b87f15bbfe6588041eb836da65cdc7d3)
This commit is contained in:
parent
cb2078769d
commit
f061cd0256
25
Fix-date-matching-failure.patch
Normal file
25
Fix-date-matching-failure.patch
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
From 1cbfc4beddfb0d89ce8e8ce17a64a3c85194f302 Mon Sep 17 00:00:00 2001
|
||||||
|
From: jxy_git <jiangxinyu@kylinos.cn>
|
||||||
|
Date: Tue, 2 Aug 2022 14:48:05 +0800
|
||||||
|
Subject: [PATCH] Fix date matching failure
|
||||||
|
|
||||||
|
---
|
||||||
|
spec/pg/basic_type_mapping_spec.rb | 2 +-
|
||||||
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/spec/pg/basic_type_mapping_spec.rb b/spec/pg/basic_type_mapping_spec.rb
|
||||||
|
index be9c7c5..9720d86 100644
|
||||||
|
--- a/spec/pg/basic_type_mapping_spec.rb
|
||||||
|
+++ b/spec/pg/basic_type_mapping_spec.rb
|
||||||
|
@@ -99,7 +99,7 @@ describe 'Basic type mapping' do
|
||||||
|
[Time.new(2019, 12, 8, 20, 38, 12.123, "-01:00")], # Time -> timestamptz[]
|
||||||
|
], nil, basic_type_mapping )
|
||||||
|
|
||||||
|
- expect( res.values[0][0] ).to match( /\{\"2019-12-08 \d\d:38:12.123[+-]\d\d\"\}/ )
|
||||||
|
+ expect( res.values[0][0] ).to match( /\{\"2019-12-0\d \d\d:38:12.123[+-]\d\d\"\}/ )
|
||||||
|
expect( result_typenames(res) ).to eq( ['timestamp with time zone[]'] )
|
||||||
|
end
|
||||||
|
|
||||||
|
--
|
||||||
|
2.34.1.windows.1
|
||||||
|
|
||||||
@ -1,51 +1,54 @@
|
|||||||
# Generated from pg-0.11.0.gem by gem2rpm -*- rpm-spec -*-
|
# Generated from pg-0.11.0.gem by gem2rpm -*- rpm-spec -*-
|
||||||
%global gem_name pg
|
%global gem_name pg
|
||||||
|
|
||||||
Name: rubygem-%{gem_name}
|
Name: rubygem-%{gem_name}
|
||||||
Version: 1.2.3
|
Version: 1.2.3
|
||||||
Release: 1
|
Release: 2
|
||||||
Summary: A Ruby interface to the PostgreSQL RDBMS
|
Summary: A Ruby interface to the PostgreSQL RDBMS
|
||||||
# Upstream license clarification (https://bitbucket.org/ged/ruby-pg/issue/72/)
|
# Upstream license clarification (https://bitbucket.org/ged/ruby-pg/issue/72/)
|
||||||
#
|
#
|
||||||
# The portions of the code that are BSD-licensed are licensed under
|
# The portions of the code that are BSD-licensed are licensed under
|
||||||
# the BSD 3-Clause license; the contents of the BSD file are incorrect.
|
# the BSD 3-Clause license; the contents of the BSD file are incorrect.
|
||||||
#
|
#
|
||||||
License: (BSD or Ruby) and PostgreSQL
|
License: (BSD or Ruby) and PostgreSQL
|
||||||
URL: https://github.com/ged/ruby-pg
|
URL: https://github.com/ged/ruby-pg
|
||||||
Source0: https://rubygems.org/gems/%{gem_name}-%{version}.gem
|
Source0: https://rubygems.org/gems/%{gem_name}-%{version}.gem
|
||||||
# Disable RPATH.
|
# Disable RPATH.
|
||||||
# https://bitbucket.org/ged/ruby-pg/issue/183
|
# https://bitbucket.org/ged/ruby-pg/issue/183
|
||||||
Patch0: rubygem-pg-0.17.1-remove-rpath.patch
|
Patch0: rubygem-pg-0.17.1-remove-rpath.patch
|
||||||
|
Patch1: Fix-date-matching-failure.patch
|
||||||
# Required in ext/pg_text_decoder.c
|
# Required in ext/pg_text_decoder.c
|
||||||
Requires: rubygem(bigdecimal)
|
Requires: rubygem(bigdecimal)
|
||||||
BuildRequires: ruby(release)
|
BuildRequires: ruby(release)
|
||||||
BuildRequires: rubygems-devel
|
BuildRequires: rubygems-devel
|
||||||
BuildRequires: ruby-devel
|
BuildRequires: ruby-devel
|
||||||
# Compiler is required for build of gem binary extension.
|
# Compiler is required for build of gem binary extension.
|
||||||
# https://fedoraproject.org/wiki/Packaging:C_and_C++#BuildRequires_and_Requires
|
# https://fedoraproject.org/wiki/Packaging:C_and_C++#BuildRequires_and_Requires
|
||||||
BuildRequires: gcc
|
BuildRequires: gcc
|
||||||
|
|
||||||
BuildRequires: postgresql-server libpq-devel
|
BuildRequires: postgresql-server libpq-devel
|
||||||
BuildRequires: rubygem(bigdecimal)
|
BuildRequires: rubygem(bigdecimal)
|
||||||
BuildRequires: rubygem(rspec)
|
BuildRequires: rubygem(rspec)
|
||||||
|
BuildRequires: make
|
||||||
|
|
||||||
%description
|
%description
|
||||||
This is the extension library to access a PostgreSQL database from Ruby.
|
This is the extension library to access a PostgreSQL database from Ruby.
|
||||||
This library works with PostgreSQL 9.1 and later.
|
This library works with PostgreSQL 9.1 and later.
|
||||||
|
|
||||||
|
|
||||||
%package doc
|
%package help
|
||||||
Summary: Documentation for %{name}
|
Summary: Documentation for %{name}
|
||||||
Requires: %{name} = %{version}-%{release}
|
Requires: %{name} = %{version}-%{release}
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
|
|
||||||
%description doc
|
%description help
|
||||||
Documentation for %{name}.
|
Documentation for %{name}.
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n %{gem_name}-%{version}
|
%setup -q -n %{gem_name}-%{version}
|
||||||
|
|
||||||
%patch0 -p1
|
%patch0 -p1
|
||||||
|
%patch1 -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
# Create the gem as gem install only works on a gem file
|
# Create the gem as gem install only works on a gem file
|
||||||
@ -102,7 +105,7 @@ popd
|
|||||||
%exclude %{gem_cache}
|
%exclude %{gem_cache}
|
||||||
%{gem_spec}
|
%{gem_spec}
|
||||||
|
|
||||||
%files doc
|
%files help
|
||||||
%doc %{gem_docdir}
|
%doc %{gem_docdir}
|
||||||
%doc %{gem_instdir}/ChangeLog
|
%doc %{gem_instdir}/ChangeLog
|
||||||
%doc %{gem_instdir}/Contributors.rdoc
|
%doc %{gem_instdir}/Contributors.rdoc
|
||||||
@ -116,5 +119,8 @@ popd
|
|||||||
%{gem_instdir}/spec
|
%{gem_instdir}/spec
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Tue Aug 02 2022 jiangxinyu <jiangxinyu@kylinos.cn> - 1.2.3-2
|
||||||
|
- Fix date matching failure
|
||||||
|
|
||||||
* Thu Mar 3 2022 caodongxia<caodongxia@huawei.com> - 1.2.3-1
|
* Thu Mar 3 2022 caodongxia<caodongxia@huawei.com> - 1.2.3-1
|
||||||
- Init package
|
- Init package
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user