outlierventures / buyco-procurement-data-browser Goto Github PK
View Code? Open in Web Editor NEWMeteor app for browsing and visualising procurement data stored in a BigchainDB/MongoDB backend.
License: Apache License 2.0
Meteor app for browsing and visualising procurement data stored in a BigchainDB/MongoDB backend.
License: Apache License 2.0
The grouped charts (category, supplier, service) suggest they group by organisation, but they actually don't. The organisation name shown in the bars is the first organisation within the query with that group value, effectively a random one.
For category and service that's usually less apparent because all councils use different values there. However with supplier it becomes apparent. See for example a search for suppliers that contain "siemens":
Here we see 4.5M for Barnsley Council - SIEMENS PLC. The 4.5M is actually the total amount for SIEMENS PLC over all councils.
Cause: invalid group clause in publish.js
for spendingGrouped
.
Seen on iPad 2 and iPhone 6 emulator. Only the top and bottom bars show, no menu options work. Details to be added.
Related to #73.
After clicking on a category:
The filter is stored in the session both as top level and as sub level:
Then when we unset on top level the filter is correctly unset in the UX:
However in the session, the sub filter still remains:
Then when we reload the page, the filter is applied in the UX again, because the group filter loads it from the session and then applies it as the global filter as per #73.
Similar to #76 but for a different use case. When changing organisations, the charts refresh multiple times. This is bad UX.
This issue is not about the fact that the reload takes a long time. That can and should be improved, but the experience during the load should be better, even if it were shorter.
Screen capture of the following:
The switching process as a whole takes +- 30s. During this process the charts reload several times. There's no indicator to the user that loading is not complete, so users can't be expected to understand whether the chart they look is final or waiting for some further data to load.
https://drive.google.com/file/d/0B5qbOn1QUh5LYXkzLXpETkswNk0/view?usp=sharing
Group by month doesn't work on develop
. Seems to group by quarter but display as Month 3, 6, 12, ..
As noted in https://trello.com/c/mxAUpla3/217-show-summed-totals-in-time-chart-when-all-organisations-selected, this happens for me in develop
at commit f36de08:
However somehow for @BearandYoon it works correctly:
Since today I see this on both https://dev.app.publicdata.works/ and https://staging.app.publicdata.works/.
Possibly related, yesterday evening I imported new data for City of York.
When using the app, many warnings are logged in the developer console. They originate from the DevExpress chart components and contain a message like "The [field name] data field is absent."
I suspect this happens when the chart gets initialised with series, but the data source is still empty.
This is not a new issue, and not critical, but it should be solved.
8029a7e….js?meteor_js_resource=true:22 W2002 - The clientValue data field is absent. See:
http://js.devexpress.com/error/16_2/W2002
When we click on a bar in the time chart, that period is applied as an extra filter to the group charts (example 2015 Q4). In the group charts this is shown as "Filter applied: 2015 Q4":
The value is saved in the Session and reloaded when we reload the page. It is applied to the group charts too; they show the same values. However the label "Filter applied: 2015 Q4" is not shown.
For some values, filtering data on the top level causes the spendingGroupedChart
s for other group fields to be empty.
Example:
Expected: the charts for Supplier and Service show some data. There are data points for this category and period with a Supplier and Service.
Result: the charts for Supplier and Service are empty.
Steps:
Expected: there's a bar in the time chart up to £18.5M. I would expect bars in the spendingGroupedChart
s that show this amount. For other periods (2015-09, 2015-10, 2015-12) that is indeed the case.
Result: for 2015-11, no data is shown in the sub charts:
Steps:
meteor run
/spending
Result: in the server console, messages like this appear:
W20170124-11:39:19.330(0)? (STDERR) { [ReqlDriverError: Cursor is closed.]
W20170124-11:39:19.339(0)? (STDERR) name: 'ReqlDriverError',
W20170124-11:39:19.341(0)? (STDERR) msg: 'Cursor is closed.',
W20170124-11:39:19.343(0)? (STDERR) frames: undefined,
W20170124-11:39:19.349(0)? (STDERR) message: 'Cursor is closed.' }
The result in the browser eventually appears, although a bit slow.
It seems that on each key event, a new search query is started. The RethinkDB server gets pretty busy. The code to open and close the cursor might not be thread-safe leading to the cursor not being open when it's called in one of the search actions.
Selection filters can be added by clicking bars in the chart. For example, if the category chart shows categories A, B and C, we can click on category B. The selection filter "category B" is then applied to the other charts. To remove this filter, we click the bar again.
By applying and removing multiple selection filters in sequence, it is however possible to end up in a situation where the selection filter is not shown in the chart anymore, and the user is hence unable to click it. The selection filter can then not be removed. Only by applying the same set of filters again, can the filter be removed.
Example. Here the selection filter Service: CHILDRENS AND EDUCATION SERVICES is applied. We click the bar in Supplier for St Helens Council - EUROPEAN CARE & LIFESTYLES (UK) LTD.
This selection filter for Supplier has now been applied. Now we click the bar in Service for CHILDRENS AND EDUCATION SERVICES to remove that selection filter:
Now there's still a selection filter for Supplier: EUROPEAN CARE & LIFESTYLES (UK) LTD active. But this supplier is not visible in the chart anymore. We can't remove it (without reapplying another filter to make the bar visible again):
Suggested approach: add an explicit removal button for selection filters in the applicable chart. So in the example case in the Supplier chart.
When clicking on a bar in a grouped chart, that bar should keep the "selected" style to indicate it has been applied as a filter. Clicking on it again should remove the filter.
Currently the bar doesn't keep the "selected" style. To make that happen we have to click another time. Then click a third time to remove the filter.
Steps:
Expected: a filter is applied for this supplier; the bar gets diagonal stripes.
Result: the filter is applied, however the bar doesn't get the style.
Initial situation after 1:
Clicking the bar:
Situation after 2. (not as expected):
After 3. (desired situation):
Then after 4, filter gets removed correctly:
We have two kinds of filters:
The top-level filters limit what is shown in any of the charts. So when we filter on Category "A", we don't see category "B" and "C" anywhere.
The sub filters limit what is shown in other charts. So in the category chart, categories A, B and C might be shown. When we click on category A, it is shown in "selected" style, and category B and C are still visible. Data in the other charts only shows data for category A.
This has previously worked correctly. However currently, the grouped charts behave like sub-filters when a top-level filter is applied.
See the below example. Category: Agency Charges - Escort is applied as a top-level filter. However we see all the other categories in the Category group chart. Because the selected category is not in the top 10, it's not visible at all. That's not how it should be, and bad UX.
On live development the RethinkDB version still runs. On staging the newer develop
branch runs which queries MongoDB. The data for Wakefield 2015 Q2/Q3 is different. It seems like some or all data from Q3 is grouped into Q2.
https://dev.app.publicdata.works/, master
branch:
https://staging.app.publicdata.works/, develop
branch:
Same symptoms as #53. Unknown if the cause is the same, so creating as separate issue.
This is Internet Explorer 11 on Windows 8.1, https://staging.app.publicdata.works/spending/time.
Steps (reproduced on my Win8 laptop, Chrome):
Result:
Expected result:
The queries to get the data run quick (100s of milliseconds max). So it has to be some other issue. The issue happened already before we moved to the DevExpress chart component and still used nvd3
.
With the Chrome Developer panel open, I often (1-2x per day) get out of memory errors. During development, it can also be seen that the Chrome process for the developer panel takes 1-2GB of memory.
Whilst this is not an issue end users will experience, it does suggest some inefficiencies within our code and/or the libraries we use.
The initial load is very slow, with the client browser using 100% of one CPU core and unresponsive throughout. Reproduced on Google Chrome and Firefox on Windows. On mobile it's visible as well.
With the current setup where all organisations are loaded initially this is very apparent. However reducing the number of initially visible organisations is not enough, there's something definitely off here.
We've seen this before in #17. Not reloading the category boxes was a workaround, however I don't think we really solved the underlying problem.
I've made a screen recording to illustrate this, with the CPU usage of the Chrome process visible side by side: https://drive.google.com/file/d/0B5qbOn1QUh5LZXViNF9tNGdWT2c/view?usp=sharing
Screenshots of the CPU usage during this period. It's about 40 seconds. Slightly longer because of screen recording, but the difference is just a couple of seconds. This recording was done with a logged in user, so client data was loaded. Results for not logged on users are similar.
When clicking on a bar in a group chart, the other charts are filtered (selection filter). In that case the chart refresh multiple times while they would only require a single reload with the new, filtered data. This causes a flashing experience in the UX, and possibly slower performance if some actions happen twice.
Here's a screen capture of that happening:
https://drive.google.com/file/d/0B5qbOn1QUh5LR1hhWV9tSnh2MEU/view?usp=sharing
The worst part UX-wise is that the chart that is clicked on also refreshes.
For comparison see what happens when clicking on a time chart bar. Here the time chart doesn't refresh, only the group charts. The latter are refreshed twice though.
https://drive.google.com/file/d/0B5qbOn1QUh5LS193Qmd3TFZRVDA/view?usp=sharing
After fixing #54 the app works on IE11. However when opening, the charts are never shown and IE keeps using 100% CPU.
This continues as long as "All organisations" is selected. The UX is responsive, e.g. we can select another organisation.
When we select another organisation (For example "Bradford MDC"), the app functions correctly and albeit slower than Chrome, at reasonably usable performance.
What seems to happen is something similar to #17: a lot of time (in this case seemingly unlimited time) is spent updating the filter boxes. I conclude this from:
It's unclear why this happens on IE and not on other browsers.
Issue #17 was solved by removing some of the responsive relations between UX elements. And that's where it seems to originate: UX events triggering other UX events triggering (...). More research needed.
The filter bars in the group charts (category, supplier, service) are marked as selected when they are clicked, i.e. a sub filter has been applied.
In cases where the group value is empty (i.e. the council data contains an empty string for category, supplier or service - this happens quite often), the bar is incorrectly marked as selected even if the user hasn't clicked it. See the top category in the screenshot below ("Bradford MDC - ").
In general it's not good UX to show these empty categories in this way. A possible approach could be to show them for example like "Bradford MDC - (no category set)". That would automatically solve this issue.
After recent commits, no legend visible in grouped charts. Legend for client series is shown. And there obviously are series in the chart.
Guess: on initialisation of the chart the series aren't loaded yet. Then on reload, the series data is set, but the chart doesn't pick it up (even though the series
object is configured with bindingOptions: { ... }
)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.