Open pietrosperoni opened 12 years ago
Hi Pietro,
We are about to push a new master branch today or tomorrow that will fix several of those issues you are having.
We use ubuntu linux so can't be of much help with mac os x specific problems...
Best regards, Robert
Thanks Robert, I am looking forward to that. In the meantime we manage to get it running. We did it by taking away the captcha and modifying it so that it does not need to send emails when the administrator registers, but the functionalities are very limited since we still did not get the mail server to work (next thing we are working on).
One of the problem we had that I did not mention before was that it expects something in the DB in the table governments, column description. So I just open the DB and add a random string. If not I get an error.
As I said we are looking forward to the new release, and will also keep on working to get it fully functional here. Then we will share the steps we needed to take.
Best Regards, Pietro
Hi Robert,
I am working with Pietro in setting up the the site. We're both new to Ruby and Rails. Which version should we take, the master or shadow? Are there significant differences between the two?
Also, the captcha seems to be working now for new user signups, but for the first admin signup after creating the site there was that server crash Pietro mentioned. Has that been fixed?
Both categories and the government had nulls in the description fields which required me to enter strings to avoid errors. This sound right?
One last thing, is there anything we need to set up that's not mentioned in the readme file? Do I ned to configure Dalli, or the email server for example? Neither of there appear to be working at the moment.
Cheers,
Derek
Hi, so we have finally just merged the latest code into the master branch. You need to setup memcached and a working local email server for emails going out. Let me know how it goes.
Hi.
I installed memcached as you said - yes, I hadn't realised that needed to be done :-) Thanks.
However, when I cloned this one and tried to instal it, and still get the recaptcha not appearing the initial admin setup page, then it crashes as before. Odd, seeing as the recaptcha works once you get the site set up and start adding users.
Dear Robert, thank you very much. I am looking at your latest code right now. As Derek mentioned it looks like most of the same problems are still present. I am testing right now the code. In those days I have also started studying git and github. I now know how to clone, and fork code. So I have tried to fix some of the issues. Maybe you could pull in some of the code in the main repository. I am sure it would be useful for others in the same situation. You will find the branch yrpr in my directory holding mostly patches that we think it should be included in the main branch.
First of all, as I said before you should add
# encoding: utf-8
on the top of seeds.rb file in db/seeds.rb
this to make the file acceptable for a non icelandic audience.
Also the problem with the recaptcha has not gone away. The error we get is exactly the same as before. We tried to get a walk around on this by taking away the recaptcha in the first page. What is VERY weird is that once we manage to make the system run, and then we try to add other users, their recaptcha works!! This baffles us.
Also the work around to this you will find in the "yrpr" branch in my github fork. The fact is, we don't really understand why is there any need for a recaptcha at all when you start the system. It is extremely unlikely that a robot might get in between just in those 5 minutes while you are setting up the system. So maybe the recaptcha over there is really not that useful.
Also there seem to be an error because the system expects a description for the government, but there is no space in the installation to add such a description. So I added a
@government.description = "Description missing"
on line 32 of install_controller.rb Again you will find it all in the yrpr file.
In any case once all this walk around are inserted the program coming out of the master branch is your world priorities program (yrpr). Leaving aside that it does not even work (any link gives an error), this is really not what we are looking for. We just need to make a single instance. Possibly with no other partners. Just a single, isolated, community. Like the good old white house 2, or maybe like the system you have for Iceland. How do we do this?
Thanks, Pietro
Another thing that we are somewhat confused about is the translation system.
Could you tell us please,
1)Do we have to set up your I18nToTr8n plugin via the console (as described here https://github.com/rbjarnason/i18n_to_tr8n) or should that be working ok?
2)Are you actually using Tr8n? If so, there is no Tr8n gem installed. Should I install it?
3)The reason there are no language options appearing on the install page would appear to be the code, passing an empty array instead of a collection:
<%= f.collection_select :language_code, [], :first, :last %>
Do you know what we should change this to?
Cheers,
Ok, at first the tr8n issue, did you perform those actions from the Readme? rake tr8n:init rake tr8n:import_db rake tr8n:import_and_setup_iso_3166 rake utils:create_partners_from_iso
Tr8n is included with the git archive under vendor/plugins.
Yes, the government description is missing, we need to add that to the initial installation.
And, yes correct, no need to have the Captcha while creating the first admin user. For now, please use rails c to create the admin user before installation. Something like: rails c
u=User.new u.login = "admin" u.email = "admin@admin" u.first_name = "admin" u.last_name = "admin" u.is_admin = true u.save(false)
You can do the same for the description problem. rails c
g=Government.last g.description="description" g.save
Regarding the yrpri welcome page... If you are running in development mode you should not get the welcome page. Check the function current_partner in line 155, this function is now a bit of a hack to go between the different website we have running, this will be fixed at some point.
Thanks for the fork and we will look at pulling your changes in soon.
Hi Robert,
Yes, we installed as per the instructions.I think the translation stuff seems to work, I was just wanting to make sure I had set everything up OK.
Thanks for the information.
With regards current partner function, ok, not sure why we were getting the Welcome page, but I added a simple test to return nil if in development mode and can now get the main site. Many thanks :-)
I had started looking at the betrireykjavik branch to see if that was more in line with what we wanted, but still get to the yrpri welcome page. And yes I added a description field, and stripped out the recaptcha on the setup page to avoid the crash.
Thanks for your reply.
Couple of additional points:
So, should we use the Master branch, or is there a better branch for us if we don't want partner sites on subdomains?
I still get the flicker problem with the setting menu link when logged in as admin.
Thanks again :-)
Hello again Robert.
Still on the betrireykjavik branch.
OK. Only bug coming up seems to be a an undefined update_status_priority_url in app/views/priorities/_nav.html.erb when creating new priorities.
Missing resource in config/routes.rb?
Shall look into it anyway. Once I've read up on rails routing :-)
Yes, adding a route to the update_status method seemed to fix it, BUT I'm finding the drop down link menus like Actions and Settings are impossible to access because they disappear immediately I try and move the cursor off the top level link.
I'll keep going with it. This menu problem doesn't exist on your machine?
Otherwise, things seem to be shaping up nicely. Cool. :-)
We have recently merged the changes from betrireykjavik branch into master so they should be more or less identical.
Hmm, this is strange with update_status_priority_url - this was added a while ago and is not a problem on our side.
No, the menu problem does not appear on our side - do you see the same problem if you go to yrpri.org or betrireykjavik.
Great that its coming along :)
Hi Robert.
Well, the menu problem only occurs on the Settings menu, which you need an admin account to view, don't you? So, can't tell. The other popup menus boxes work OK, but the markup looks different. About popup for example has class 'test' so maybe that was added to fix a similar problem there.
The problem seems to be that there isn't enough room for the popup so the page is rearranged, the Settings link gets shifted down, is no longer under the cursor, so gets immediately shifted back up, and so on. I suspect increasing the popup's z-index might fix it, so it can rise above the side column.
All in all we still have the same problems as before.
Going through it properly this time, but trying to strip out stuff I don't think we'll need, like the first recaptcha (which spawns a bug in rails) and partners.
Most problems seem to come from NULL fields where text is expected.
One problems we have is with Issues. They are done as tags? They seem to be stored purely on the partner table, as required tags? This column is of course NULL so we get errors when we try to view Categories.
Does this mean without a partner we cannot use issues?
How does a site without partners create issues? Create a dummy partner for itself?
Wonder if we'd be better off going further back in the betrireykjavik branch to before partners were added? That looks a cool site.
Cheers :)
On 11/02/2012 15:03, Róbert Viðar Bjarnason wrote:
We have recently merged the changes from betrireykjavik branch into master so they should be more or less identical.
Hmm, this is strange with update_status_priority_url - this was added a while ago and is not a problem on our side.
No, the menu problem does not appear on our side - do you see the same problem if you go to yrpri.org or betrireykjavik.
Great that its coming along :)
Reply to this email directly or view it on GitHub: https://github.com/rbjarnason/open-active-democracy/issues/3#issuecomment-3921121
Ah, OK,
Robert, when I go to yrpri.org and follow the link to a UK priority:
http://uk.yrpri.org/priorities/83-ban-the-corporate-lobbying-of-politicians I do get the same problem, but this time with the Actions link.
You should not need to have any partners installed. The site should work fine without partners but noted we have not run the code with an empty database, well, since October so that explains the problems you are seeing with null fields. Let me know how it goes.
Hi Robert,
OK, well in the end I had only to change two lines in one of the view files to allow for current_partner not being set. So that wasn't so bad.
Yes, I'd realised the DB was the main source of our problems :) Still picking up ruby and rails, so I misread the code for fetching the tags. Problem was the seeded Categories had no matching entries in the tags table, so I added code to create appropriate entries for the seeded categories in the tags table and all seems OK, once the checks for no current_partner were added to the view.
How about the menu problem on the yrpri.org site, the screenshot I linked to in an earlier comment?
Pietro and I both get this in the latest versions of Firefox and Safari and Chrome, though I believe Pietro manages to tab through the options on Chrome.
In the screenshot the pointer is over the Action menu link and the popup is way over on the left, unreachable by the pointer.
You not get that?
Yes, we also get this menu problem and are looking into it.
There is now a ticket for this at: https://ibuar.lighthouseapp.com/projects/74915-your_priorities/tickets/642-menu-problem-on-master-yrpri
Also, Create Portlet displays a menu that slides up, but had no background. Might be an easy fix, dunno yet.
Are we supposed to create tickets on that site for problems we find in the master?
Cheers.
Hi Robert,
I did a temporary fix to the menu problem: 7238c3b
Doesn't solve the z-index problem but making it narrower means it can at least fit below the higher level menu link.
Cheers.
Great thanks :)
Hi Robert, so the last version from Derek of the system now seem to be quite easy to install. There are different communities that might ask us now to install a system for them. (we spoke with several of them). Of course we would like to reuse the translation made from one community in Italian for another community. And I guess you also might be interested for your yrpr website. So is there a way for us to save the translations done, and then reload them? And maybe even to merge different translations.
Cheers, Pietro
Hi Pietro,
Great news :) Please send us, if you like, some information about those communities when you have setup those pages, always fun to watch what is going on.
Yes, you can use: rake tr8n:import_db rake tr8n:export_db
This will only import and export the translation database, check the source code under vendor/plugins/tr8n/lib/tasks
Cheers, Robert
Thanks Robert, of course we will! Also I expect someone should contact you soon for Greece. There are at this time several people relating what has happened to Iceland with what has happened to Greece.
Also we shall study the translation DB and import and export from it.
How much do the Iceland website cost in terms of resources (RAM usage, bandwidth...). You have any suggestion regarding the server? We were going to try using Dreamhost (trying both with and without VPS) or Heroku but we still haven't made up our mind and we are testing different possibilities...
Cheers, Pietro
P.S. Sorry if I did not update for such a long time, leaving it to Derek, but we had such a cold winter here in Rome; everything paralized under 10 cm of snow and the temperature ever reached -5 C. Brrrr. ;-)
Hello again Robert,
Got a couple of calls to an undefined function env in the tr8n_task.rake file:
if ['production', 'stage', 'staging'].include?(Rails.env) and env('force') != 'true'
and
date = env('before') || (Date.today - 2.weeks)
and can find no definition of the env function in either ruby or rails, in the project code, and no reference to this function on the web.
Any idea what this function is? Does it rely on some library I might be missing?
Are you sure we don't need to add the tr8n gem, and the related ones listed in the tr8n installation instructions? It seems odd that we don't require them. Might the env() function used in the tr8n_tasks file not be defined in the tr8n gem?
Cheers.
The tr8n gem is not required because tr8n is included under vendor/plugins in the repository. I'm currently in the process of upgrading open-active-democracy from Rails 3.0 to 3.1, which includes switching to the tr8n gem instead of maintaining it under vendor/plugins. I'll take a look at the tr8n rake tasks while I'm at it.
Ah, OK, thanks.
Hi,
Just to say that on the new 3.1 version of Master it seems that once a new member has verified his email address the "Please verify your account" message is still appearing on the side panel.
Cheers.
I just fixed that issue in my branch (you'll have to create the user again). Róbert will merge it in soon.
OK, cool.
Could I not just set their activation code to NULL manually?
Specifically, the problem was that the on_active_entry method was not getting called for the user, so you can get the same effect by doing your_user.on_active_entry(nil, nil)
OK, thanks :-)
Just noticed that the Start Translating button is missing on the Select Language popup. Does this need to be activated somewhere in the configuration?
Cheers.
Dear Robert, we are trying to install open active democracy, but we are having several problems.
We have several communities in Italy that are interested in it. Some parties want to have it as a system to decide what people want to do. Then once we know how to install it we want to use it on other places as well. I also would like to apply to it some of my ideas on e-democracy, and the research I did in the last years.
I hope some of the development we do might merge back with your versions (if you are interested).
Unfortunately right now we seem to be unable to even install the basic version. For this I have several questions: 1) what branch should we be using?
It looks like there are several branches that are being developed in parallel.
And at least 3 of them seem to be active: master, better reykiavik, shadow. I assume better reykiavik is the code for http://betrireykjavik.is/,
(By the way, this: http://betrireykjavik.is/tr8n/settings gives an error page not found.)
and shadow might be the code for the website do decide the priorities for the whole iceland. Am I right?
So does this mean that the master branch is for: http://www.yrpri.org/welcome
Because then we probably should use the Shadow branch.
Then we have several problems which I would like to bring to your attention:
first of all, in the instructions you seem not to mention the file relic.yml
second, we kept on having problems because of internationalization, and we discovered we had to add the line
# encoding: utf-8
on the top of seeds.rb file in db/seeds.rbBut then the real sticking point, the element that are seem to be unable to surpass are the captcha.
When we finally succeed in running the servers, we go to the first page /install then from there to the second page /create_admin_user and in this page there is a captcha that should appear for us to "show our humanity". But the image never appears. Also the system seem to crash. This is what the Terminal says:
Now the line 11 of r_magick_backend.rb is:
image = Magick::Image.new(width.to_i, height.to_i)
so there might be some problem with the Magick library that maybe is not correctly installed. Both me and my collaborator are having the same problem. We both have a mac, mine is Mac OS X Snow Leopard, and my collaborator is a Mac OS X Lion.Also we do not understand why you are using such a complicated Captcha system. Usually people just use a small piece of javascript. Is it for security? Because you do not want to depend on an external company for the access to a website which is part of the Icelandic institutions?
In any case we are trying to make this system work, or at least to cut it off, and we seem to be unable to do either. Could you, or your programmer tell us what to do?
And then there is the problem of the language. When I start the server, I reach the /install page. But the list of available languages seem to be empty.
No reference to all this is in the readme file.
Any help would be greatly appreciated. Pietro