Re: [pgadmin-hackers] theme to use while building docs
Hi, Any comments on this? I put 1.1 RPM package announcement on hold until we have a fix for this. Thanks! Regards, Devrim On Sat, 2016-11-12 at 22:54 +0300, Devrim Gündüz wrote: > Hi, > > While building docs on EL7 and F-23, I got this error: > > "no theme named 'classic' found (missing theme.conf?)" > > The reason is that sphinx in these distros don't have the classic theme. So, > I > can patch docs/en_US/conf.py , and change > > html_theme = 'default' > > in these distros. However, that will be a hack. Is this something we can fix > upstream, or should I really patch it myself? > > Regards, -- Devrim GÜNDÜZ EnterpriseDB: http://www.enterprisedb.com PostgreSQL Danışmanı/Consultant, Red Hat Certified Engineer Twitter: @DevrimGunduz , @DevrimGunduzTR signature.asc Description: This is a digitally signed message part
Re: [pgadmin-hackers] theme to use while building docs
On Sat, Nov 12, 2016 at 7:54 PM, Devrim Gündüz wrote: > > Hi, > > While building docs on EL7 and F-23, I got this error: > > "no theme named 'classic' found (missing theme.conf?)" > > The reason is that sphinx in these distros don't have the classic theme. So, I > can patch docs/en_US/conf.py , and change > > html_theme = 'default' > > in these distros. However, that will be a hack. Is this something we can fix > upstream, or should I really patch it myself? Hmmm. It's because the version of Sphinx for EL7 and friends is really quite old. We could probably add some Makefile magic to detect and change it, but frankly it's probably easier (and will certainly be much quicker) for you to just patch conf.py. Thanks. -- Dave Page Blog: http://pgsnake.blogspot.com Twitter: @pgsnake EnterpriseDB UK: http://www.enterprisedb.com The Enterprise PostgreSQL Company -- Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgadmin-hackers
[pgadmin-hackers] [pgAdmin4][Patch]: Dashboard JS - Set DOM Elements context
Hi, In dashboard.js, some of the DOM elements are in the global context, so, changed those elements to be used only for the Dashboard context. Please find the attached patch for the same. Thanks, Khushboo diff --git a/web/pgadmin/dashboard/templates/dashboard/js/dashboard.js b/web/pgadmin/dashboard/templates/dashboard/js/dashboard.js index d12e175..2f97138 100644 --- a/web/pgadmin/dashboard/templates/dashboard/js/dashboard.js +++ b/web/pgadmin/dashboard/templates/dashboard/js/dashboard.js @@ -354,15 +354,15 @@ function(r, $, pgAdmin, _, Backbone) { // Rock n' roll on the server dashboard init_server_dashboard: function(sid, version, session_stats_refresh, tps_stats_refresh, ti_stats_refresh, to_stats_refresh, bio_stats_refresh) { -var div_sessions = document.getElementById('graph-sessions'); -var div_tps = document.getElementById('graph-tps'); -var div_ti = document.getElementById('graph-ti'); -var div_to = document.getElementById('graph-to'); -var div_bio = document.getElementById('graph-bio'); -var div_server_activity = document.getElementById('server_activity'); -var div_server_locks = document.getElementById('server_locks'); -var div_server_prepared = document.getElementById('server_prepared'); -var div_server_config = document.getElementById('server_config'); +var div_sessions = $('.dashboard-container').find('#graph-sessions')[0]; +var div_tps = $('.dashboard-container').find('#graph-tps')[0]; +var div_ti = $('.dashboard-container').find('#graph-ti')[0]; +var div_to = $('.dashboard-container').find('#graph-to')[0]; +var div_bio = $('.dashboard-container').find('#graph-bio')[0]; +var div_server_activity = $('.dashboard-container').find('#server_activity'); +var div_server_locks = $('.dashboard-container').find('#server_locks'); +var div_server_prepared = $('.dashboard-container').find('#server_prepared'); +var div_server_config = $('.dashboard-container').find('#server_config'); var dataset_sessions = []; var data_sessions = []; var dataset_tps = []; -- Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgadmin-hackers
[pgadmin-hackers] pgAdmin 4 commit: Include SQL templates in the translation template.
Include SQL templates in the translation template. Branch -- master Details --- http://git.postgresql.org/gitweb?p=pgadmin4.git;a=commitdiff;h=74e5b5a492c7386d5b98bc5d0952b1451c31d8d6 Modified Files -- web/babel.cfg| 1 + web/pgadmin/messages.pot | 924 --- 2 files changed, 873 insertions(+), 52 deletions(-) -- Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgadmin-hackers
Re: [pgadmin-hackers] theme to use while building docs
Hi, On Mon, 2016-11-14 at 09:41 +, Dave Page wrote: > It's because the version of Sphinx for EL7 and friends is really > quite old. Right. > We could probably add some Makefile magic to detect and > change it, but frankly it's probably easier (and will certainly be > much quicker) for you to just patch conf.py. Ok, I can patch for now, but given that EL7 will be out for a long time, if there is a Makefile hack for next versions, that would be awesome. Regards, -- Devrim GÜNDÜZ EnterpriseDB: http://www.enterprisedb.com PostgreSQL Danışmanı/Consultant, Red Hat Certified Engineer Twitter: @DevrimGunduz , @DevrimGunduzTR signature.asc Description: This is a digitally signed message part
[pgadmin-hackers] pgAdmin 4 commit: Add missing strings from the dashboards.
Add missing strings from the dashboards. Branch -- master Details --- http://git.postgresql.org/gitweb?p=pgadmin4.git;a=commitdiff;h=052a9fc840e1073bc94f40fa87dbbbc1802bba97 Modified Files -- .../templates/dashboard/database_dashboard.html| 24 - .../templates/dashboard/server_dashboard.html | 28 +- .../templates/dashboard/welcome_dashboard.html | 23 - web/pgadmin/messages.pot | 60 -- 4 files changed, 91 insertions(+), 44 deletions(-) -- Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgadmin-hackers
Re: [pgadmin-hackers] pgAdmin4 Chinese (Simplified) translation Patch
Hi (Khushboo, please see below) On Sun, Nov 13, 2016 at 1:26 PM, lambda wrote: > for the first question, pybabel support Chinese with zh_Hans_CN > > #pybabel --list-locales |grep zh > b'zh Chinese' > b'zh_Hans Chinese (Simplified)' > b'zh_Hans_CN Chinese (Simplified, China)' > b'zh_Hans_HK Chinese (Simplified, Hong Kong SAR China)' > b'zh_Hans_MO Chinese (Simplified, Macau SAR China)' > b'zh_Hans_SG Chinese (Simplified, Singapore)' > b'zh_Hant Chinese (Traditional)' > b'zh_Hant_HK Chinese (Traditional, Hong Kong SAR China)' > b'zh_Hant_MO Chinese (Traditional, Macau SAR China)' > b'zh_Hant_TW Chinese (Traditional, Taiwan)' Right, but if I try to match with 'zh-CN' (which is what Chrome offers for Chinese Simplified), then I get: 2016-11-14 11:53:52,919: INFO werkzeug: 127.0.0.1 - - [14/Nov/2016 11:53:52] "GET / HTTP/1.1" 500 - Traceback (most recent call last): File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", line 2000, in __call__ return self.wsgi_app(environ, start_response) File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", line 1991, in wsgi_app response = self.make_response(self.handle_exception(e)) File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", line 1567, in handle_exception reraise(exc_type, exc_value, tb) File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", line 1988, in wsgi_app response = self.full_dispatch_request() File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", line 1634, in full_dispatch_request self.try_trigger_before_first_request_functions() File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", line 1660, in try_trigger_before_first_request_functions func() File "/Users/dpage/git/pgadmin4/web/pgadmin/utils/__init__.py", line 42, in create_module_preference self.register_preferences() File "/Users/dpage/git/pgadmin4/web/pgadmin/browser/__init__.py", line 192, in register_preferences gettext("Show system objects?"), 'boolean', False, File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask_babel/__init__.py", line 539, in gettext t = get_translations() File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask_babel/__init__.py", line 216, in get_translations catalog = support.Translations.load(dirname, [get_locale()]) File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask_babel/__init__.py", line 248, in get_locale locale = Locale.parse(rv) File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/babel/core.py", line 270, in parse parts = parse_locale(identifier, sep=sep) File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/babel/core.py", line 1096, in parse_locale raise ValueError('expected only letters, got %r' % lang) ValueError: expected only letters, got 'zh-cn' zh_Hans_CN isn't offered by the browser at all, so that doesn't work. Maybe the answer is to not use the browser's language negotiation at all, but make it a configurable setting? >2.for the compile error, it seems an bug in pybabel choose ignore it, > it well ok.in my vim , line 7283 nearly it highlights '% u' in " 20% use" > i do not known why both '%' and 'u' high here. > in my laptop, although it make an error massage as you show, it > generate the po file ok! >now i update the 7283 line with '20% use' with '20%\ use' >it will compile without errror, >attatchment is updated version. >Thank you! In testing I found a couple of issues: 1) We weren't extracting strings from SQL templates for translation 2) Strings in some of the dashboards weren't marked for translation I've fixed those two issues and updated the template. Can you please update your translation? Khushboo; I also noticed that the treeview collection labels aren't getting translated. Can you look to see why please? Thanks. -- Dave Page Blog: http://pgsnake.blogspot.com Twitter: @pgsnake EnterpriseDB UK: http://www.enterprisedb.com The Enterprise PostgreSQL Company -- Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgadmin-hackers
Re: [pgadmin-hackers] pgAdmin4 Chinese (Simplified) translation Patch
On Mon, Nov 14, 2016 at 5:37 PM, Dave Page wrote: > Hi > > (Khushboo, please see below) > > On Sun, Nov 13, 2016 at 1:26 PM, lambda wrote: > > for the first question, pybabel support Chinese with zh_Hans_CN > > > > #pybabel --list-locales |grep zh > > b'zh Chinese' > > b'zh_Hans Chinese (Simplified)' > > b'zh_Hans_CN Chinese (Simplified, China)' > > b'zh_Hans_HK Chinese (Simplified, Hong Kong SAR China)' > > b'zh_Hans_MO Chinese (Simplified, Macau SAR China)' > > b'zh_Hans_SG Chinese (Simplified, Singapore)' > > b'zh_Hant Chinese (Traditional)' > > b'zh_Hant_HK Chinese (Traditional, Hong Kong SAR China)' > > b'zh_Hant_MO Chinese (Traditional, Macau SAR China)' > > b'zh_Hant_TW Chinese (Traditional, Taiwan)' > > Right, but if I try to match with 'zh-CN' (which is what Chrome offers > for Chinese Simplified), then I get: > > 2016-11-14 11:53:52,919: INFO werkzeug: 127.0.0.1 - - [14/Nov/2016 > 11:53:52] "GET / HTTP/1.1" 500 - > Traceback (most recent call last): > File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site- > packages/flask/app.py", > line 2000, in __call__ > return self.wsgi_app(environ, start_response) > File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site- > packages/flask/app.py", > line 1991, in wsgi_app > response = self.make_response(self.handle_exception(e)) > File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site- > packages/flask/app.py", > line 1567, in handle_exception > reraise(exc_type, exc_value, tb) > File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site- > packages/flask/app.py", > line 1988, in wsgi_app > response = self.full_dispatch_request() > File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site- > packages/flask/app.py", > line 1634, in full_dispatch_request > self.try_trigger_before_first_request_functions() > File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site- > packages/flask/app.py", > line 1660, in try_trigger_before_first_request_functions > func() > File "/Users/dpage/git/pgadmin4/web/pgadmin/utils/__init__.py", line > 42, in create_module_preference > self.register_preferences() > File "/Users/dpage/git/pgadmin4/web/pgadmin/browser/__init__.py", > line 192, in register_preferences > gettext("Show system objects?"), 'boolean', False, > File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site- > packages/flask_babel/__init__.py", > line 539, in gettext > t = get_translations() > File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site- > packages/flask_babel/__init__.py", > line 216, in get_translations > catalog = support.Translations.load(dirname, [get_locale()]) > File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site- > packages/flask_babel/__init__.py", > line 248, in get_locale > locale = Locale.parse(rv) > File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site- > packages/babel/core.py", > line 270, in parse > parts = parse_locale(identifier, sep=sep) > File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site- > packages/babel/core.py", > line 1096, in parse_locale > raise ValueError('expected only letters, got %r' % lang) > ValueError: expected only letters, got 'zh-cn' > > zh_Hans_CN isn't offered by the browser at all, so that doesn't work. > > Maybe the answer is to not use the browser's language negotiation at > all, but make it a configurable setting? > > >2.for the compile error, it seems an bug in pybabel choose ignore > it, > > it well ok.in my vim , line 7283 nearly it highlights '% u' in " 20% > use" > > i do not known why both '%' and 'u' high here. > > in my laptop, although it make an error massage as you show, it > > generate the po file ok! > >now i update the 7283 line with '20% use' with '20%\ use' > >it will compile without errror, > >attatchment is updated version. > >Thank you! > > In testing I found a couple of issues: > > 1) We weren't extracting strings from SQL templates for translation > > 2) Strings in some of the dashboards weren't marked for translation > > I've fixed those two issues and updated the template. Can you please > update your translation? > > Khushboo; I also noticed that the treeview collection labels aren't > getting translated. Can you look to see why please? > > Sure. Will look into this. > Thanks. > > -- > Dave Page > Blog: http://pgsnake.blogspot.com > Twitter: @pgsnake > > EnterpriseDB UK: http://www.enterprisedb.com > The Enterprise PostgreSQL Company >
Re: [pgadmin-hackers] [pgAdmin4][Patch]: Dashboard JS - Set DOM Elements context
Thanks, applied. On Mon, Nov 14, 2016 at 10:48 AM, Khushboo Vashi wrote: > Hi, > > In dashboard.js, some of the DOM elements are in the global context, so, > changed those elements to be used only for the Dashboard context. > > Please find the attached patch for the same. > > Thanks, > Khushboo > > > -- > Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org) > To make changes to your subscription: > http://www.postgresql.org/mailpref/pgadmin-hackers > -- Dave Page Blog: http://pgsnake.blogspot.com Twitter: @pgsnake EnterpriseDB UK: http://www.enterprisedb.com The Enterprise PostgreSQL Company -- Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgadmin-hackers
[pgadmin-hackers] pgAdmin 4 commit: Move some DOM elements out of the global context.
Move some DOM elements out of the global context. Branch -- master Details --- http://git.postgresql.org/gitweb?p=pgadmin4.git;a=commitdiff;h=83a1808bfdf59989bf5a6a93c5a806d9039935f6 Author: Khushboo Vashi Modified Files -- .../dashboard/templates/dashboard/js/dashboard.js | 18 +- 1 file changed, 9 insertions(+), 9 deletions(-) -- Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgadmin-hackers
[pgadmin-hackers] pgAdmin website commit: Add an FAQ
Add an FAQ Branch -- master Details --- http://git.postgresql.org/gitweb?p=pgadmin-www.git;a=commitdiff;h=0b4b9277d79f9f2bdfe26f03deeed837894441cf Modified Files -- faq.php | 49 + 1 file changed, 49 insertions(+) -- Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgadmin-hackers
Re: [pgadmin-hackers] pgAdmin4 Chinese (Simplified) translation Patch
with web/config.py add ``` LANGUAGES = { 'zh_cn' : 'zh_CN', 'en' : 'English' } ``` ok ? 在 2016-11-14 20:16:47,"Khushboo Vashi" 写道: On Mon, Nov 14, 2016 at 5:37 PM, Dave Page wrote: Hi (Khushboo, please see below) On Sun, Nov 13, 2016 at 1:26 PM, lambda wrote: > for the first question, pybabel support Chinese with zh_Hans_CN > > #pybabel --list-locales |grep zh > b'zh Chinese' > b'zh_Hans Chinese (Simplified)' > b'zh_Hans_CN Chinese (Simplified, China)' > b'zh_Hans_HK Chinese (Simplified, Hong Kong SAR China)' > b'zh_Hans_MO Chinese (Simplified, Macau SAR China)' > b'zh_Hans_SG Chinese (Simplified, Singapore)' > b'zh_Hant Chinese (Traditional)' > b'zh_Hant_HK Chinese (Traditional, Hong Kong SAR China)' > b'zh_Hant_MO Chinese (Traditional, Macau SAR China)' > b'zh_Hant_TW Chinese (Traditional, Taiwan)' Right, but if I try to match with 'zh-CN' (which is what Chrome offers for Chinese Simplified), then I get: 2016-11-14 11:53:52,919: INFO werkzeug: 127.0.0.1 - - [14/Nov/2016 11:53:52] "GET / HTTP/1.1" 500 - Traceback (most recent call last): File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", line 2000, in __call__ return self.wsgi_app(environ, start_response) File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", line 1991, in wsgi_app response = self.make_response(self.handle_exception(e)) File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", line 1567, in handle_exception reraise(exc_type, exc_value, tb) File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", line 1988, in wsgi_app response = self.full_dispatch_request() File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", line 1634, in full_dispatch_request self.try_trigger_before_first_request_functions() File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", line 1660, in try_trigger_before_first_request_functions func() File "/Users/dpage/git/pgadmin4/web/pgadmin/utils/__init__.py", line 42, in create_module_preference self.register_preferences() File "/Users/dpage/git/pgadmin4/web/pgadmin/browser/__init__.py", line 192, in register_preferences gettext("Show system objects?"), 'boolean', False, File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask_babel/__init__.py", line 539, in gettext t = get_translations() File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask_babel/__init__.py", line 216, in get_translations catalog = support.Translations.load(dirname, [get_locale()]) File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask_babel/__init__.py", line 248, in get_locale locale = Locale.parse(rv) File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/babel/core.py", line 270, in parse parts = parse_locale(identifier, sep=sep) File "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/babel/core.py", line 1096, in parse_locale raise ValueError('expected only letters, got %r' % lang) ValueError: expected only letters, got 'zh-cn' zh_Hans_CN isn't offered by the browser at all, so that doesn't work. Maybe the answer is to not use the browser's language negotiation at all, but make it a configurable setting? >2.for the compile error, it seems an bug in pybabel choose ignore it, > it well ok.in my vim , line 7283 nearly it highlights '% u' in " 20% use" > i do not known why both '%' and 'u' high here. > in my laptop, although it make an error massage as you show, it > generate the po file ok! >now i update the 7283 line with '20% use' with '20%\ use' >it will compile without errror, >attatchment is updated version. >Thank you! In testing I found a couple of issues: 1) We weren't extracting strings from SQL templates for translation 2) Strings in some of the dashboards weren't marked for translation I've fixed those two issues and updated the template. Can you please update your translation? Khushboo; I also noticed that the treeview collection labels aren't getting translated. Can you look to see why please? Sure. Will look into this. Thanks. -- Dave Page Blog: http://pgsnake.blogspot.com Twitter: @pgsnake EnterpriseDB UK: http://www.enterprisedb.com The Enterprise PostgreSQL Company
[pgadmin-hackers] pgAdmin website commit: A few FAQ tweaks, before enabling it.
A few FAQ tweaks, before enabling it. Branch -- master Details --- http://git.postgresql.org/gitweb?p=pgadmin-www.git;a=commitdiff;h=7315509f404503f2c1958da389c1615d535e61fb Modified Files -- faq.php | 10 +- menu.php | 1 + 2 files changed, 6 insertions(+), 5 deletions(-) -- Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgadmin-hackers
Re: [pgadmin-hackers] pgAdmin4 Chinese (Simplified) translation Patch
Hi On Mon, Nov 14, 2016 at 3:22 PM, lambda wrote: > > > with web/config.py add > > ``` > LANGUAGES = { > 'zh_cn' : 'zh_CN', > 'en' : 'English' > } > ``` > ok ? Hmm, I'm sure that failed yesterday - I remember debugging it! It's working now though, so let's use zh_cn. BTW; the second field above is just a label, so I'd probably put "Chinese (Simplified)" in there. Can you update your catalog with the latest changes please? > 在 2016-11-14 20:16:47,"Khushboo Vashi" 写道: > > > > On Mon, Nov 14, 2016 at 5:37 PM, Dave Page wrote: >> >> Hi >> >> (Khushboo, please see below) >> >> On Sun, Nov 13, 2016 at 1:26 PM, lambda wrote: >> > for the first question, pybabel support Chinese with zh_Hans_CN >> > >> > #pybabel --list-locales |grep zh >> > b'zh Chinese' >> > b'zh_Hans Chinese (Simplified)' >> > b'zh_Hans_CN Chinese (Simplified, China)' >> > b'zh_Hans_HK Chinese (Simplified, Hong Kong SAR China)' >> > b'zh_Hans_MO Chinese (Simplified, Macau SAR China)' >> > b'zh_Hans_SG Chinese (Simplified, Singapore)' >> > b'zh_Hant Chinese (Traditional)' >> > b'zh_Hant_HK Chinese (Traditional, Hong Kong SAR China)' >> > b'zh_Hant_MO Chinese (Traditional, Macau SAR China)' >> > b'zh_Hant_TW Chinese (Traditional, Taiwan)' >> >> Right, but if I try to match with 'zh-CN' (which is what Chrome offers >> for Chinese Simplified), then I get: >> >> 2016-11-14 11:53:52,919: INFO werkzeug: 127.0.0.1 - - [14/Nov/2016 >> 11:53:52] "GET / HTTP/1.1" 500 - >> Traceback (most recent call last): >> File >> "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", >> line 2000, in __call__ >> return self.wsgi_app(environ, start_response) >> File >> "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", >> line 1991, in wsgi_app >> response = self.make_response(self.handle_exception(e)) >> File >> "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", >> line 1567, in handle_exception >> reraise(exc_type, exc_value, tb) >> File >> "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", >> line 1988, in wsgi_app >> response = self.full_dispatch_request() >> File >> "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", >> line 1634, in full_dispatch_request >> self.try_trigger_before_first_request_functions() >> File >> "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", >> line 1660, in try_trigger_before_first_request_functions >> func() >> File "/Users/dpage/git/pgadmin4/web/pgadmin/utils/__init__.py", line >> 42, in create_module_preference >> self.register_preferences() >> File "/Users/dpage/git/pgadmin4/web/pgadmin/browser/__init__.py", >> line 192, in register_preferences >> gettext("Show system objects?"), 'boolean', False, >> File >> "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask_babel/__init__.py", >> line 539, in gettext >> t = get_translations() >> File >> "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask_babel/__init__.py", >> line 216, in get_translations >> catalog = support.Translations.load(dirname, [get_locale()]) >> File >> "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask_babel/__init__.py", >> line 248, in get_locale >> locale = Locale.parse(rv) >> File >> "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/babel/core.py", >> line 270, in parse >> parts = parse_locale(identifier, sep=sep) >> File >> "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/babel/core.py", >> line 1096, in parse_locale >> raise ValueError('expected only letters, got %r' % lang) >> ValueError: expected only letters, got 'zh-cn' >> >> zh_Hans_CN isn't offered by the browser at all, so that doesn't work. >> >> Maybe the answer is to not use the browser's language negotiation at >> all, but make it a configurable setting? >> >> >2.for the compile error, it seems an bug in pybabel choose ignore >> > it, >> > it well ok.in my vim , line 7283 nearly it highlights '% u' in " 20% >> > use" >> > i do not known why both '%' and 'u' high here. >> > in my laptop, although it make an error massage as you show, it >> > generate the po file ok! >> >now i update the 7283 line with '20% use' with '20%\ >> > use' >> >it will compile without errror, >> >attatchment is updated version. >> >Thank you! >> >> In testing I found a couple of issues: >> >> 1) We weren't extracting strings from SQL templates for translation >> >> 2) Strings in some of the dashboards weren't marked for translation >> >> I've fixed those two issues and updated the template. Can you please >> update your translation? >> >> Khushboo; I also noticed that the treeview collection labels aren't >> getting translated. Can you look to see why please? >> > > Sure. Will look into this. > >>
Re: [pgadmin-hackers] pgAdmin4 Chinese (Simplified) translation Patch
Hi, this is the new updated version, thank you! :) At 2016-11-14 23:41:21, "Dave Page" wrote: >Hi > >On Mon, Nov 14, 2016 at 3:22 PM, lambda wrote: >> >> >> with web/config.py add >> >> ``` >> LANGUAGES = { >> 'zh_cn' : 'zh_CN', >> 'en' : 'English' >> } >> ``` >> ok ? > >Hmm, I'm sure that failed yesterday - I remember debugging it! It's >working now though, so let's use zh_cn. > >BTW; the second field above is just a label, so I'd probably put >"Chinese (Simplified)" in there. > >Can you update your catalog with the latest changes please? > >> 在 2016-11-14 20:16:47,"Khushboo Vashi" 写道: >> >> >> >> On Mon, Nov 14, 2016 at 5:37 PM, Dave Page wrote: >>> >>> Hi >>> >>> (Khushboo, please see below) >>> >>> On Sun, Nov 13, 2016 at 1:26 PM, lambda wrote: >>> > for the first question, pybabel support Chinese with zh_Hans_CN >>> > >>> > #pybabel --list-locales |grep zh >>> > b'zh Chinese' >>> > b'zh_Hans Chinese (Simplified)' >>> > b'zh_Hans_CN Chinese (Simplified, China)' >>> > b'zh_Hans_HK Chinese (Simplified, Hong Kong SAR China)' >>> > b'zh_Hans_MO Chinese (Simplified, Macau SAR China)' >>> > b'zh_Hans_SG Chinese (Simplified, Singapore)' >>> > b'zh_Hant Chinese (Traditional)' >>> > b'zh_Hant_HK Chinese (Traditional, Hong Kong SAR China)' >>> > b'zh_Hant_MO Chinese (Traditional, Macau SAR China)' >>> > b'zh_Hant_TW Chinese (Traditional, Taiwan)' >>> >>> Right, but if I try to match with 'zh-CN' (which is what Chrome offers >>> for Chinese Simplified), then I get: >>> >>> 2016-11-14 11:53:52,919: INFO werkzeug: 127.0.0.1 - - [14/Nov/2016 >>> 11:53:52] "GET / HTTP/1.1" 500 - >>> Traceback (most recent call last): >>> File >>> "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", >>> line 2000, in __call__ >>> return self.wsgi_app(environ, start_response) >>> File >>> "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", >>> line 1991, in wsgi_app >>> response = self.make_response(self.handle_exception(e)) >>> File >>> "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", >>> line 1567, in handle_exception >>> reraise(exc_type, exc_value, tb) >>> File >>> "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", >>> line 1988, in wsgi_app >>> response = self.full_dispatch_request() >>> File >>> "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", >>> line 1634, in full_dispatch_request >>> self.try_trigger_before_first_request_functions() >>> File >>> "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask/app.py", >>> line 1660, in try_trigger_before_first_request_functions >>> func() >>> File "/Users/dpage/git/pgadmin4/web/pgadmin/utils/__init__.py", line >>> 42, in create_module_preference >>> self.register_preferences() >>> File "/Users/dpage/git/pgadmin4/web/pgadmin/browser/__init__.py", >>> line 192, in register_preferences >>> gettext("Show system objects?"), 'boolean', False, >>> File >>> "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask_babel/__init__.py", >>> line 539, in gettext >>> t = get_translations() >>> File >>> "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask_babel/__init__.py", >>> line 216, in get_translations >>> catalog = support.Translations.load(dirname, [get_locale()]) >>> File >>> "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/flask_babel/__init__.py", >>> line 248, in get_locale >>> locale = Locale.parse(rv) >>> File >>> "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/babel/core.py", >>> line 270, in parse >>> parts = parse_locale(identifier, sep=sep) >>> File >>> "/Users/dpage/.virtualenvs/pgadmin4/lib/python2.7/site-packages/babel/core.py", >>> line 1096, in parse_locale >>> raise ValueError('expected only letters, got %r' % lang) >>> ValueError: expected only letters, got 'zh-cn' >>> >>> zh_Hans_CN isn't offered by the browser at all, so that doesn't work. >>> >>> Maybe the answer is to not use the browser's language negotiation at >>> all, but make it a configurable setting? >>> >>> >2.for the compile error, it seems an bug in pybabel choose ignore >>> > it, >>> > it well ok.in my vim , line 7283 nearly it highlights '% u' in " 20% >>> > use" >>> > i do not known why both '%' and 'u' high here. >>> > in my laptop, although it make an error massage as you show, it >>> > generate the po file ok! >>> >now i update the 7283 line with '20% use' with '20%\ >>> > use' >>> >it will compile without errror, >>> >attatchment is updated version. >>> >Thank you! >>> >>> In testing I found a couple of issues: >>> >>> 1) We weren't extracting strings from SQL templates for translation >>> >>> 2) Strings in some of the dashboards weren't marked for translation >>> >>> I've fixed those
[pgadmin-hackers] [pgAdmin][Patch]: Backgrid password cell css
Hi, Please find the attached patch for the Backgrid password cell css. Currently the password cell does not have proper css in the edit mode. Thanks, Khushboo diff --git a/web/pgadmin/static/css/overrides.css b/web/pgadmin/static/css/overrides.css index 5af03ba..9f8aa79 100755 --- a/web/pgadmin/static/css/overrides.css +++ b/web/pgadmin/static/css/overrides.css @@ -1427,3 +1427,26 @@ table.backgrid { .help-block { white-space: normal; } + +.backgrid td.editor input[type=password] { + display: block; + width: 100%; + height: 100%; + padding: 0 5px; + margin: 0; + background-color: transparent; + border: 0; + outline: 0; + -webkit-box-shadow: none; + -moz-box-shadow: none; + box-shadow: none; + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + box-sizing: border-box; + -webkit-appearance: none; + -moz-appearance: none; +} + +.backgrid td.editor input[type=password]::-ms-clear { + display: none; +} -- Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgadmin-hackers