Fbs

Latest version: v1.2.2

Safety actively analyzes 638066 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 10 of 19

0.6.2

This new module lets you very easily implement a license key functionality for your app. Please see the associated [documentation](https://build-system.fman.io/manual/#license-keys).

0.6.1

See `ApplicationContextexcepthook`.

0.6.0

Also add an example of this to the default `main.py` that gets generated when you do `fbs startproject`.

0.5.9

See 67.

0.5.8

A common thing to do is to display the version of your app in the GUI. In previous versions of fbs, this was difficult. The reason for this is that the version was stored in (usually) the `base.json` settings file, which is theoretically available when you run from source, but not when running the frozen form of your app.

This release of fbs adds a property called `public_settings` to `ApplicationContext`. It lets you easily access certain settings (such as `version`) from your application. For an example, please see [the associated documentation](https://build-system.fman.io/manual/#public_settings).

0.5.7

Let `f` and `h` be Python functions and `g` be a function of Qt. If

f() -> g() -> h()

(where "`->`" means "calls"), and an exception occurs in `h()`, then the
traceback does not contain `f`. This can make debugging very difficult.

This version of fbs adds a custom `excepthook` that adds the missing
traceback entries. You can change it by overwriting the
`cached_property` `ApplicationContext.excepthook`.

The code below can be used to reproduce the `f() -> g() -> h()`
problem. It opens a window with a button. When you click it, an error
occurs whose traceback does not include `f()`.

The problem described here is not specific to PyQt5 - It occurs for
PySide2 as well. To see this, replace `PyQt5` by `PySide2` below.

from PyQt5.QtWidgets import *
from PyQt5.QtCore import Qt

class Window(QWidget):
def __init__(self):
super().__init__()
btn = QPushButton('Click me', self)
btn.clicked.connect(self.f)
def f(self, _):
self.inputMethodQuery(Qt.ImAnchorPosition)
def inputMethodQuery(self, query):
if query == Qt.ImAnchorPosition:
Make Qt call inputMethodQuery(ImCursorPosition).
This is our "g()":
return super().inputMethodQuery(query) "g()"
self.h()
def h(self):
raise Exception()

app = QApplication([])
window = Window()
window.show()
app.exec_()

Page 10 of 19

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.