Giter Site home page Giter Site logo

ictv's People

Contributors

anthonygego avatar drumor avatar l9kd1 avatar mpiraux avatar nrybowski avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ictv's Issues

Wrong field type in Templates class

The image type returned by the template class is given as img but in the doc it is given as image.
After some tests, it appears that the correct type is image.

Provide a minimal configuration

The configuration.example.yaml file contains redundant configuration that is not needed for a minimal configuration file. The documentation should provide a minimal configuration file. A note should be added to indicate that production instances should not use the minimal configuration file.

Bundle orientation

As I first implement in #21, I thought it is a good idea to extend orientation of a channel to a bundle. This allows user to subscribe their vertical screen to a bundle that contains all the vertical channels for example.
Does it make sense?

`RuntimeError` when trying to launch `ictv-webapp` into python3.7 virtualenv

Hi,

I installed ICTV via the pip3 command given here into a fresh python3.7 virtualenv and I got this error :

ictv-webapp 0.0.0.0:8080 --config configuration.yaml 

Exception encountered when starting the application
Traceback (most recent call last):
  File "<$HOME>/ICTV/env/lib/python3.7/site-packages/web/utils.py", line 526, in take
    yield next(seq)
StopIteration

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "<$HOME>/ICTV/env/lib/python3.7/site-packages/ictv/app.py", line 506, in main
    app = get_app(config_file)
  File "<$HOME>/ICTV/env/lib/python3.7/site-packages/ictv/app.py", line 404, in get_app
    app = web.application(app_urls, globals())
  File "<$HOME>/ICTV/env/lib/python3.7/site-packages/web/application.py", line 62, in __init__
    self.init_mapping(mapping)
  File "<$HOME>/ICTV/env/lib/python3.7/site-packages/web/application.py", line 130, in init_mapping
    self.mapping = list(utils.group(mapping, 2))
  File "<$HOME>/ICTV/env/lib/python3.7/site-packages/web/utils.py", line 531, in group
    x = list(take(seq, size))
RuntimeError: generator raised StopIteration
Traceback (most recent call last):
  File "<$HOME>/ICTV/env/lib/python3.7/site-packages/web/utils.py", line 526, in take
    yield next(seq)
StopIteration

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "<$HOME>/ICTV/env/bin/ictv-webapp", line 67, in <module>
    main(config_file)
  File "<$HOME>/ICTV/env/lib/python3.7/site-packages/ictv/app.py", line 517, in main
    raise e
  File "<$HOME>/ICTV/env/lib/python3.7/site-packages/ictv/app.py", line 506, in main
    app = get_app(config_file)
  File "<$HOME>/ICTV/env/lib/python3.7/site-packages/ictv/app.py", line 404, in get_app
    app = web.application(app_urls, globals())
  File "<$HOME>/ICTV/env/lib/python3.7/site-packages/web/application.py", line 62, in __init__
    self.init_mapping(mapping)
  File "<$HOME>/ICTV/env/lib/python3.7/site-packages/web/application.py", line 130, in init_mapping
    self.mapping = list(utils.group(mapping, 2))
  File "<$HOME>/ICTV/env/lib/python3.7/site-packages/web/utils.py", line 531, in group
    x = list(take(seq, size))
RuntimeError: generator raised StopIteration

I have the same issue when running the source code with python3.7

I tried the same installation with a python3.6 virtualenv and all is working like a charm.

[concurrency] client kickstart file generation may fail at startup

During the route initialization process, the client_pages module is loaded to add the route to the client kickstart files.

from ictv.client.pages import client_pages

However, this module also generates the kickstart zip when it is loaded the first time.

make_system_zip()

In a multi-threaded/process environnement, the function generating the zip file is called multiple times in parallel, and may try to unlink a file that has already been unlinked by a parallel process. This ends up with a FileNotFoundError exception being raised at the application startup if such a case occurs.

def make_system_zip():
system_zip_path = os.path.join(get_root_path(), 'client', 'ks', 'system' + os.extsep + 'zip')
if os.path.exists(system_zip_path):
os.unlink(system_zip_path)
def add_file(file):
system_zip.write(os.path.join(get_root_path(), 'client', 'ks', file), arcname=file)
with ZipFile(system_zip_path, 'w') as system_zip:
add_file(os.path.join('etc', 'pam.d', 'xserver'))
add_file(os.path.join('home', 'ictv', '.xinitrc'))

Writing the file in parallel should also be avoided in case ZipFile does not implement an internal lock/is not threadsafe.

Set parameters for susbcriptions

It should be possible to set parameters (like time to display) depending subscriptions.
As example: we have a request for displaying an embed channel more than 10 sec on one client. If i change this parameter, all clients will be impacted which is not the expected behavior.

Live feature

As already talk, it should be interesting to get a full live system feature to let users display a livestream.

Let's have this issue as a reminder.

Subscriptions seems to be linked to screen orientation

Hi,

It seems that screen subscriptions seems to be associated with the screen orientation.

Step to reproduce :

  • create a screen in landscape and subscribe to some channel
  • change screen orientation (via 'edit')
  • the subscriptions are not visible when visualizing the screen (but still there when visualizing the channels)

What do you think ?

Is Travis working correctly on PR?

Let's try submitting a minimal PR, e.g. adding a single space somewhere, to see if Travis is still ok. Oddly, commits directly on the master branch are fine.

The asset caching mechanism should update assets based on HTTP headers

Currently, the caching mechanism is not updating assets in cache at any time. It should use the information exposed in HTTP headers (Last-Modified, Cache-Control, etc) to update assets in cache.

We have to define a policy for this update mechanism to trigger. Sending an HTTP request every time the PluginManager sees a slide referencing an external asset seems a bit heavy, but it is the policy that ensures the most consistent cache.

Ergonomics

I got those propositions to enhance the user interface:

  • Channels : Get a "my channels" tab to find user's channels easier.
  • Channels - User Permissions : Put contrib,admins,... on the top of the list.
  • Channels - Buttons : "Configure" -> "Settings" and "Application"->"Edit"
  • Channels - Subscriptions: Get the previous window while clicking on back.Nowadays, you have to do the search again.
  • Channels - Details : Get the previous window while clicking on back.Nowadays, you have to do the search again.
    -Channels - Preview : Get the previous window while clicking on back.Nowadays, you have to do the search again.
  • Channels - Configure : Get the previous window while clicking on back.Nowadays, you have to do the search again.
  • Editor plugin : Replace "Edit" -> "Settings", "Open" -> "Edit".
  • Editor plugin : When editing a slide, the selected template and made layout is lost. (It's more a bug than an enhancement)
  • Screens : Change "Configure" -> "Settings"
  • Screens : Put the subscribed screens on the top of the list.

exceptions.IOError thrown on ICTVs

Hello,

It has been a while since I have first seen this error on the TVs and I thought it might be good to share it here.
I can't see the full trace and can't find the ictv.py file, so I have no clue how to help you.

However, I see that you are using Python 2 which has been officially deprecated since 2015, and I think it might be a good idea to switch to a more recent Python version. I can also help with the recurring UTF encoding errors we can see on some screens, since Python 3 better handles string encoding.
ingi_ictv_error

If I can help, please tell me.

Jérome

Improve subscription presentation

To improve the interface and user experience, a different button should be presented when visualizing a screen or a channel. In one case, the button "subscription" will show a list of channels, and in the other case, a button with the same label will show a list of screens.

It may be good to have a different label on theses buttons.

[concurrency] templates and themes loading may fail at startup

Templates are themes table are re-initialized at application startup in a transaction that empties the database table and feeds it using the discovered files.

sqlhub.doInTransaction(load_templates_and_themes)

ICTV/ictv/app.py

Lines 87 to 90 in 97c8dcb

def load_templates_and_themes():
Template.deleteMany(None)
for template in next((os.walk(os.path.join(get_root_path(), 'renderer/templates/'))))[2]:
Template(name=template.replace('.html', ''))

In a multi-process setup with (u)wsgi and lazy-apps set to true, multiple transactions may be performed in parallel during application startup. This leads to the failure and rollback of one or several of them because the first one may be in the commit stage while the other is in the processing stage.

This is not destructive as the transaction is rolled back but sqlobject.dberrors.DuplicateEntryError as well as psycopg2.errors.UniqueViolation exceptions are raised and never caught, making the app crash.

While we could logically accept such a failure and pass on sqlobject.dberrors.DuplicateEntryError, it is not sufficient to catch the sqlobject backend underlying exception (psyscopg in the case of postgre). Catching all exceptions and passing could lead to more instable behaviour (I/O erros, ...)...

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.