pgAdmin 4 commit: Added ability to generate code coverage reports for j

2020-08-07 Thread Akshay Joshi
Added ability to generate code coverage reports for java script files.

Branch
--
master

Details
---
https://git.postgresql.org/gitweb?p=pgadmin4.git;a=commitdiff;h=68a5027d15a8889e5cffd8338210e21b88a9ffc9
Author: Pramod Ahire 

Modified Files
--
.gitignore  |   3 +-
web/karma.conf.js   |  12 +
web/package.json|   5 +-
web/regression/javascript/pgadmin_utils_spec.js |   2 +-
web/webpack.test.config.js  |  12 +-
web/yarn.lock   | 287 +++-
6 files changed, 305 insertions(+), 16 deletions(-)



pgAdmin 4 commit: Replace the generic exception class with a more speci

2020-08-07 Thread Akshay Joshi
Replace the generic exception class with a more specific one.

Branch
--
master

Details
---
https://git.postgresql.org/gitweb?p=pgadmin4.git;a=commitdiff;h=d6400bbcae1cddba5f77a7c39b3b2876b7c9a1db
Author: Aditya Toshniwal 

Modified Files
--
web/pgAdmin4.py   |  5 +++--
web/pgadmin/__init__.py   |  3 ++-
web/pgadmin/browser/server_groups/servers/types.py|  3 ++-
web/pgadmin/feature_tests/file_manager_test.py|  8 
web/pgadmin/feature_tests/query_tool_auto_complete_tests.py   |  4 ++--
web/pgadmin/feature_tests/xss_checks_pgadmin_debugger_test.py |  2 +-
web/pgadmin/misc/__init__.py  |  1 +
web/pgadmin/misc/bgprocess/processes.py   |  4 ++--
web/pgadmin/misc/file_manager/__init__.py |  3 ++-
web/pgadmin/tools/sqleditor/command.py| 11 ++-
.../tools/sqleditor/utils/is_query_resultset_updatable.py |  3 ++-
web/pgadmin/tools/user_management/__init__.py |  5 +++--
web/pgadmin/utils/driver/psycopg2/__init__.py |  5 +++--
web/pgadmin/utils/driver/psycopg2/server_manager.py   |  8 +---
web/pgadmin/utils/paths.py|  5 +++--
web/regression/feature_utils/app_starter.py   |  4 ++--
web/regression/feature_utils/pgadmin_page.py  |  4 ++--
web/regression/runtests.py|  2 +-
18 files changed, 46 insertions(+), 34 deletions(-)



Re: [pgAdmin][SonarQube] Replace the generic exception class with a more specific one

2020-08-07 Thread Akshay Joshi
Thanks, patch applied.

On Fri, Aug 7, 2020 at 11:36 AM Aditya Toshniwal <
aditya.toshni...@enterprisedb.com> wrote:

> Hi Hackers,
>
> Attached is the followup patch to fix all the remaining issues (around 30)
> related to replacing the generic exception class with more specific ones.
> Please review.
>
> On Wed, Aug 5, 2020 at 12:42 PM Akshay Joshi <
> akshay.jo...@enterprisedb.com> wrote:
>
>> Thanks, patch applied.
>>
>> On Wed, Aug 5, 2020 at 11:09 AM Aditya Toshniwal <
>> aditya.toshni...@enterprisedb.com> wrote:
>>
>>> Hi Hackers,
>>>
>>> Attached is the patch to replace the generic exception class with a
>>> newly added ExecuteError class for all the places where error occurs when a
>>> SQL is executed.
>>> This fixes around 34 issues.
>>>
>>> Please review.
>>> --
>>> Thanks,
>>> Aditya Toshniwal
>>> pgAdmin hacker | Sr. Software Engineer | *edbpostgres.com*
>>> 
>>> "Don't Complain about Heat, Plant a TREE"
>>>
>>
>>
>> --
>> *Thanks & Regards*
>> *Akshay Joshi*
>> *pgAdmin Hacker | Sr. Software Architect*
>> *EDB Postgres *
>>
>> *Mobile: +91 976-788-8246*
>>
>
>
> --
> Thanks,
> Aditya Toshniwal
> pgAdmin hacker | Sr. Software Engineer | *edbpostgres.com*
> 
> "Don't Complain about Heat, Plant a TREE"
>


-- 
*Thanks & Regards*
*Akshay Joshi*
*pgAdmin Hacker | Sr. Software Architect*
*EDB Postgres *

*Mobile: +91 976-788-8246*


Re: Code coverage report generation for JS files

2020-08-07 Thread Pramod Ahire
Thank you :)

 

Pramod Ahire

Software Engineer

 

 

C: +91-020-66449600/601

D: +91-9028697679

edbpostgres.com

 

 

From: Akshay Joshi 
Date: Friday, 7 August 2020 at 12:38 PM
To: Pramod Ahire 
Cc: Aditya Toshniwal , pgadmin-hackers 
, Dave Page 
Subject: Re: Code coverage report generation for JS files

 

Thanks, patch applied.




Re: Code coverage report generation for JS files

2020-08-07 Thread Dave Page
Was a Makefile target added? Maybe "make coverage"...

On Fri, Aug 7, 2020 at 8:10 AM Pramod Ahire 
wrote:

> Thank you :)
>
>
>
> *Pramod Ahire*
>
> *Software Engineer*
>
>
>
> [image:
> https://lh4.googleusercontent.com/U1erEuyI_d0xEUA0CrKjwx9aWQ52HNCxc38dMsLP-ZrLgfVNrhsrNobxlmeOdb1kMPtrrxcUwEHZgbGJC4R0qR4r1sBZa_z9R8ihFRaP2Hr_Wnhq6HcIQHe1ZoviDPwUkTdzNcg]
>
>
>
> C: +91-020-66449600/601
>
> D: +91-9028697679
>
> *edbpostgres.com *
>
>
>
>
>
> *From: *Akshay Joshi 
> *Date: *Friday, 7 August 2020 at 12:38 PM
> *To: *Pramod Ahire 
> *Cc: *Aditya Toshniwal ,
> pgadmin-hackers , Dave Page <
> dp...@pgadmin.org>
> *Subject: *Re: Code coverage report generation for JS files
>
>
>
> Thanks, patch applied.
>
>

-- 
Dave Page
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake

EDB: http://www.enterprisedb.com


pgAdmin 4 commit: Clarify some of the differences when running in serve

2020-08-07 Thread Dave Page
Clarify some of the differences when running in server mode in the docs. Fixes 
#5724

Branch
--
master

Details
---
https://git.postgresql.org/gitweb?p=pgadmin4.git;a=commitdiff;h=d9c20de31fbb66690a4e3a86f22c1aa07f75f165

Modified Files
--
docs/en_US/release_notes_4_25.rst | 3 ++-
docs/en_US/server_deployment.rst  | 9 +
2 files changed, 11 insertions(+), 1 deletion(-)



[pgAdmin][RM5713]:Incorrect DROP SQL for Catalog and Foreign Server

2020-08-07 Thread Nikhil Mohite
Hi Team,

I have resolved the issue in SQL statements for RM-5713
.

PFA patch.


RM_5713_v1.patch
Description: Binary data


Bug #5670 - Backup dialog error message does not have close button

2020-08-07 Thread Yogesh Mahajan
Hello,

Please find a patch which adds a close button to error messages shown in
backup, restore tab.
Also fix width issue

Thanks,
Yogesh Mahajan
QA - Team
EnterpriseDB Corporation

Phone: +91-9741705709


RM5670_v1.patch
Description: Binary data


pgAdmin 4 commit: Fixed an issue where the error message does not have

2020-08-07 Thread Akshay Joshi
Fixed an issue where the error message does not have a close button on utility 
dialogs. Fixes #5670

Branch
--
master

Details
---
https://git.postgresql.org/gitweb?p=pgadmin4.git;a=commitdiff;h=3672013ddc2369970883cfa3c2a7f9e16461c39c
Author: Yogesh Mahajan  

Modified Files
--
docs/en_US/release_notes_4_25.rst  |  1 +
web/pgadmin/browser/static/js/browser.js   | 49 +-
.../misc/file_manager/static/js/file_manager.js|  4 +-
web/pgadmin/preferences/static/js/preferences.js   |  2 +-
web/pgadmin/tools/backup/static/js/backup.js   |  6 +--
.../backup/static/js/backup_dialog_wrapper.js  |  7 
.../tools/import_export/static/js/import_export.js |  7 
web/pgadmin/tools/restore/static/js/restore.js |  2 +-
.../restore/static/js/restore_dialog_wrapper.js|  7 
.../search_objects/static/js/search_objects.js |  2 +-
.../javascript/file_manager/file_manager_specs.js  | 45 +---
11 files changed, 88 insertions(+), 44 deletions(-)



pgAdmin 4 commit: Added make file target for the coverage of JS files.

2020-08-07 Thread Akshay Joshi
Added make file target for the coverage of JS files.

Branch
--
master

Details
---
https://git.postgresql.org/gitweb?p=pgadmin4.git;a=commitdiff;h=23a12efd29598d71344c44d9792380434a47a378
Author: Pramod Ahire 

Modified Files
--
Makefile | 3 +++
1 file changed, 3 insertions(+)



pgAdmin 4 commit: Corrected DROP SQL syntax for catalog. Fixes #5713

2020-08-07 Thread Akshay Joshi
Corrected DROP SQL syntax for catalog. Fixes #5713

Branch
--
master

Details
---
https://git.postgresql.org/gitweb?p=pgadmin4.git;a=commitdiff;h=9ad7476a34c77999bc43ecc0f6a03b7cd01862fd
Author: Nikhil Mohite  

Modified Files
--
docs/en_US/release_notes_4_25.rst   | 1 +
web/pgadmin/browser/server_groups/servers/databases/schemas/__init__.py | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)



pgAdmin 4 commit: Added the 'ORDER BY' clause for the privileges type t

2020-08-07 Thread Akshay Joshi
Added the 'ORDER BY' clause for the privileges type to fix schema diff issue. 
Fixes #5689

Branch
--
master

Details
---
https://git.postgresql.org/gitweb?p=pgadmin4.git;a=commitdiff;h=518b13c77981125fe03be28b4d08694400efee8b

Modified Files
--
docs/en_US/release_notes_4_25.rst   | 1 +
.../foreign_tables/templates/foreign_tables/sql/9.2_plus/acl.sql| 2 +-
.../schemas/functions/templates/functions/pg/sql/default/acl.sql| 2 +-
.../schemas/functions/templates/functions/ppas/sql/default/acl.sql  | 2 +-
.../schemas/functions/templates/procedures/pg/sql/11_plus/acl.sql   | 2 +-
.../schemas/functions/templates/procedures/ppas/sql/default/acl.sql | 2 +-
.../functions/templates/trigger_functions/pg/sql/default/acl.sql| 2 +-
.../functions/templates/trigger_functions/ppas/sql/default/acl.sql  | 2 +-
.../databases/schemas/packages/templates/packages/ppas/9.1_plus/acl.sql | 2 +-
.../databases/schemas/packages/templates/packages/ppas/9.2_plus/acl.sql | 2 +-
.../databases/schemas/tables/templates/tables/sql/10_plus/acl.sql   | 2 +-
.../databases/schemas/tables/templates/tables/sql/9.1_plus/acl.sql  | 2 +-
.../servers/databases/schemas/types/templates/types/sql/default/acl.sql | 2 +-
13 files changed, 13 insertions(+), 12 deletions(-)



Re: Bug #5670 - Backup dialog error message does not have close button

2020-08-07 Thread Akshay Joshi
Thanks, patch applied.

On Fri, Aug 7, 2020 at 3:14 PM Yogesh Mahajan <
yogesh.maha...@enterprisedb.com> wrote:

> Hello,
>
> Please find a patch which adds a close button to error messages shown in
> backup, restore tab.
> Also fix width issue
>
> Thanks,
> Yogesh Mahajan
> QA - Team
> EnterpriseDB Corporation
>
> Phone: +91-9741705709
>


-- 
*Thanks & Regards*
*Akshay Joshi*
*pgAdmin Hacker | Sr. Software Architect*
*EDB Postgres *

*Mobile: +91 976-788-8246*


Re: [pgAdmin][RM5713]:Incorrect DROP SQL for Catalog and Foreign Server

2020-08-07 Thread Akshay Joshi
Thanks, patch applied.

On Fri, Aug 7, 2020 at 2:49 PM Nikhil Mohite 
wrote:

> Hi Team,
>
> I have resolved the issue in SQL statements for RM-5713
> .
>
> PFA patch.
>


-- 
*Thanks & Regards*
*Akshay Joshi*
*pgAdmin Hacker | Sr. Software Architect*
*EDB Postgres *

*Mobile: +91 976-788-8246*


Re: Code coverage report generation for JS files

2020-08-07 Thread Pramod Ahire
Thank you ! appreciates your quick action.

 

Pramod Ahire

Software Engineer

 

 

C: +91-020-66449600/601

D: +91-9028697679

edbpostgres.com

 

 

From: Akshay Joshi 
Date: Friday, 7 August 2020 at 5:25 PM
To: Pramod Ahire 
Cc: Dave Page , Aditya Toshniwal 
, pgadmin-hackers 

Subject: Re: Code coverage report generation for JS files

 

Have attached the patch for same, please do let me know if needed anything else.






Bug #5664 SQL DDL output generator for view

2020-08-07 Thread Rahul Shirsat
Hi Hackers,

Please find the attached patch below which resolves the following issue of
SQL DDL output generator for view (preserving default values of columns)

Also, when changing VIEW's column's default value, the SQL generates ALTER
TABLE, now this would be as ALTER VIEW instead.

This fix could not be associated with its test cases, as the changes are
related to VIEW's column, in which we cannot add columns to the VIEW and
test it.

-- 
*Rahul Shirsat*
Software Engineer | EnterpriseDB Corporation.


RM5664.patch
Description: Binary data


Re: WIP: SQL Formatter

2020-08-07 Thread Dave Page
On Mon, Aug 3, 2020 at 10:51 AM Aditya Toshniwal <
aditya.toshni...@enterprisedb.com> wrote:

> Hi,
>
> On Mon, Aug 3, 2020 at 3:06 PM Dave Page  wrote:
>
>>
>>
>> On Mon, Aug 3, 2020 at 10:31 AM Aditya Toshniwal <
>> aditya.toshni...@enterprisedb.com> wrote:
>>
>>> Hi,
>>>
>>> On Fri, Jul 31, 2020 at 6:03 PM Dave Page  wrote:
>>>
 Hi

 Currently, all the CodeMirrors in pgAdmin use the settings from the
> Query tool -> Editor, even though they're not related.  I think
> you're right. We should move all CodeMirror settings out of the Query tool
> and move it to a new node - "SQL" may be. Editor and Auto-format would be
> sub nodes under SQL. With that, the editor settings will apply at all the
> places where CodeMirror editing is used(function body, query tool). What 
> do
> you say ?
>

 Turns out that's more work than I really have time for at the moment,
 because it means making the editors be able to handle automatic reloads of
 multiple preference sections. We can always think about moving the
 formatting preferences into their own section later.

 In the meantime, this update to the patch does what was originally
 suggested and puts the options into a Query Tool -> SQL Formatting section.

>>> Cool.
>>>

 Comments? Obviously docs will need updating too, once we're all happy
 with the basics.

>>> It works nice. A shortcut and auto format only selected text would be
>>> helpful.
>>>
>>
>> Yeah, the shortcut crossed my mind. Any thoughts on what it could be? I
>> was struggling to find something that made sense and wasn't used by Chrome
>> or elsewhere.
>>
> I can only find Shift+Cmd+K available.
>
>>
>> Formatting only the selected text might be troublesome; it may create
>> some very strange results if a partial statement is selected.
>>
> Formatter should not be blamed in that case. It did what was asked. :P
>

*shrug*. OK. How's about this?

-- 
Dave Page
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake

EDB: http://www.enterprisedb.com


SQL_Formatting_v3.patch
Description: Binary data