public inbox for [email protected]  
help / color / mirror / Atom feed
From: Sanket Mehta <[email protected]>
To: pgadmin-hackers <[email protected]>
Subject: Re: [pgAdmin 4 - Bug #1292] ERROR: template database "!@#$%^&*()_+{}|:"<>?=-\\][';/.," does not exist message throws if template database contain special charterers
Date: Mon, 20 Jun 2016 19:26:52 +0530
Message-ID: <CA+yw=mMMC-e5eTAd0zdQOPhberf+-2N7GBAPnEQ18ifH24EiAg@mail.gmail.com> (raw)
In-Reply-To: <redmine.journal-2631.20160613094255.50340dcbfb33bf96@postgresql.org>
References: <[email protected]>
	<redmine.journal-2631.20160613094255.50340dcbfb33bf96@postgresql.org>
List-Unsubscribe:  <mailto:[email protected]?body=unsub%20pgadmin-hackers>

Hi,

PFA the revised patch to resolve this issue which consists the change in
control formatter.


Regards,
Sanket Mehta
Sr Software engineer
Enterprisedb

On Mon, Jun 13, 2016 at 3:12 PM, <[email protected]> wrote:

> Issue #1292 has been updated by Dave Page.
>
>    - *Target version* deleted (*1.0 Beta 1*)
>
> ------------------------------
> Bug #1292: ERROR: template database "!@#$%^&*()_+{}|:"<>?=-\\][';/.," does
> not exist message throws if template database contain special charterers
> <https://redmine.postgresql.org/issues/1292#change-2631;
>
>    - Author: Fahar Abbas
>    - Status: In Progress
>    - Priority: Normal
>    - Assignee: Sanket Mehta
>    - Category:
>    - Target version:
>
> Commit ID:
> -----------
> commit 954163b4957c1dce89c0632d009b845cbe90faf4
>
> Browser version:
> ----------------
> Firefox 45.0.2
>
> Python version:
> ----------------
> 3.5.1+
>
> Platforms:
> All
>
> ERROR: template database "!@#$%^&*()_+{}|:"<>?=-\\][';/.," does not exist
> message throws if user try to create database with template database that
> name contain special charterers.
>
> Please note that this issue is not reproducible in other template
> databases that name is simple one.
>
> Please note that this is not reproduce in pgAdmin3.
>
> Steps:
>
> 1. Install pgAdmin4 on Ubuntu 16.04
> 2. Install PG-9.6-beta 1 installer
> 3. Expand database node
> 4. give it's name !#$%^&*()_+{}|:"<>?=-\][';/.,
> 5. Database created successfully
> 6. Again create new database and give it's name abcd
> 7. Click on definition tab
> 8. select template database !#$%^&*()_+{}|:"<>?=-\][';/.,
> 9. Click on Save button
> Files Screen Shot 2016-06-02 at 10.25.34 am.png
> <https://redmine.postgresql.org/attachments/download/1197/Screen%20Shot%202016-06-02%20at%2010.25.34%...;
> (1020 KB)
> Screen Shot 2016-06-02 at 10.26.01 am.png
> <https://redmine.postgresql.org/attachments/download/1198/Screen%20Shot%202016-06-02%20at%2010.26.01%...;
> (1.03 MB)
> ------------------------------
>
> You have received this notification because you have either subscribed to
> it, or are involved in it.
> To change your notification preferences, please click here:
> https://redmine.postgresql.org/my/account
>


-- 
Sent via pgadmin-hackers mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgadmin-hackers


Attachments:

  [text/x-patch] RM_1292V2.patch (563B, 3-RM_1292V2.patch)
  download | inline diff:
diff --git a/web/pgadmin/static/js/backform.pgadmin.js b/web/pgadmin/static/js/backform.pgadmin.js
index c33289c..4466c1c 100644
--- a/web/pgadmin/static/js/backform.pgadmin.js
+++ b/web/pgadmin/static/js/backform.pgadmin.js
@@ -1787,7 +1787,7 @@
   var Select2Formatter = function() {};
   _.extend(Select2Formatter.prototype, {
     fromRaw: function(rawData, model) {
-      return JSON.stringify(_.escape(rawData));
+      return JSON.parse(JSON.stringify(_.escape(rawData)));
     },
     toRaw: function(formattedData, model) {
       return formattedData;


view thread (6+ messages)  latest in thread

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected]
  Subject: Re: [pgAdmin 4 - Bug #1292] ERROR: template database "!@#$%^&*()_+{}|:"<>?=-\\][';/.," does not exist message throws if template database contain special charterers
  In-Reply-To: <CA+yw=mMMC-e5eTAd0zdQOPhberf+-2N7GBAPnEQ18ifH24EiAg@mail.gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox