The freedom to make and distribute exact copies when you wish.
.
The freedom to make and distribute exact copies when you wish.
.
Users' control over the program requires four essential freedoms.
freedom to study the program's “source code,” and change it, so the program does your computing as you wish
freedom to run the program as you wish, for whatever purpose.
The first two freedoms mean each user can exercise individual control over the program
Either way, they give the program's developer power over the users, power that no one should have.
When a program respects users' freedom and community, we call it “free software.”
computer users' freedom—for users to control the software they use, rather than vice versa
(in its practitioners' perverse terminology) as “secure boot”
The computer will run, without prejudice, whatever software you install in it, and let that software do whatever its code says to do.
This means that computer does not impose one particular service rather than another, or one protocol rather than another. It does not require the user to get anyone else's permission to communicate via a certain protocol.
The computer will communicate, without prejudice, through whatever protocol your installed software implements, with whatever users and whatever other networked computers you direct it to communicate with.
Any software that can be replaced by someone else, the user must be empowered to replace.
However, the presence of nonfree software in the computer is an obstacle to verifying that the computer is loyal, or making sure it remains so.
For instance, the AMT functionality in recent Intel processors runs nonfree software that can talk to Intel remotely. Unless disabled, this makes the system disloyal.
The computer always permits you to analyze the operation of a program that is running.
This entails that the computer rejects remote attestation, that is, that it does not permit other computers to determine over the network whether your computer is running one particular software load. Remote attestation gives web sites the power to compel you to connect to them only through an application with DRM that you can't break, denying you effective control over the software you use to communicate with them.
When the computer communicates using any given protocol, it will support doing so, without prejudice, via whatever code you choose (assuming the code implements the intended protocol), and it will do nothing to help any other part of the Internet to distinguish which code you are using or what changes you may have made in it, or to discriminate based on your choice.
Free/Open Licenses Non-free Licenses
.
Free and open-source licenses use these existing legal structures for an inverse purpose
Creative Commons NonCommercial licenses (by-nc-*) do not support the OD 1.1#8., “No Discrimination Against Fields of Endeavor”, as they exclude usage in commercial activities.
Broadly speaking, an open license is one which grants permission to access, re-use and redistribute a work with few or no restrictions.
Opponents often state that this technology will be used primarily to enforce digital rights management policies (imposed restrictions to the owner) and not to increase computer security.
TC is controversial as the hardware is not only secured for its owner, but also against its owner, leading opponents of the technology like free software activist Richard Stallman to deride it as "treacherous computing"
The law in many countries allows users certain rights over data whose copyright they do not own (including text, images, and other media), often under headings such as fair use or public interest. Depending on jurisdiction, these may cover issues such as whistleblowing, production of evidence in court, quoting or other small-scale usage, backups of owned media, and making a copy of owned material for personal use on other owned devices or systems. The steps implicit in trusted computing have the practical effect of preventing users exercising these legal rights.
"please" and "thanks"
Provide a complete description of the issue. If it works on A but not on B and others have to ask you: "so what is different between A and B" you are wasting everyone's time.
Introduction of a lockfile: true/filename mechanism to prevent multiple schedulers from executing
So you need help. People can help you, but first help them help you, and don't waste their time.
I avoid running -d in development mode and bother about daemonizing only for production deployment.
There is the handy rails server -d that starts a development Rails as a daemon. The annoying thing is that the scheduler as seen above is started in the main process that then gets forked and daemonized. The rufus-scheduler thread (and any other thread) gets lost, no scheduling happens.
Using rufus-scheduler with Passenger or Unicorn requires a bit more knowledge and tuning, gently provided by a bit of googling and reading
I don't know what this Ruby thing is, where are my Rails? I'll drive you right to the tracks.
Go read how to report bugs effectively, twice. Update: help_help.md might help help you.
.
similar gems
Rufus-scheduler (out of the box) is an in-process, in-memory scheduler. It uses threads. It does not persist your schedules. When the process is gone and the scheduler instance with it, the schedules are gone.
Log to stdout. Shut down on TERM/INT. Reload config on HUP. Provide the necessary config file for your favorite init system to control your daemon.
Your application code should not be dealing with PID files, log redirection or other low-level concerns.
Let your operating system handle daemons, respawning and logging while you focus on your application features and users.
This makes developing a modern daemon much easier. The init config file is what you use to configure logging, run as a user, and many other things you previous did in code. You tweak a few init config settings; your code focuses less on housekeeping and more on functionality.
For years developers have followed the same arcane dozen steps to create a long-lived daemon process on Unix-based systems. These steps were state of the art in 2000 but they are no longer best practice today.
Less system administration, easier debugging, simpler code, all because you leveraged the init system to do the work for you!
The beauty of runit is its brevity and simplicity
Unfortunately newer init systems like systemd have become increasingly complex to handle more desktop-focused requirements. Here’s a list of systemd APIs: does having 100s of public API functions and commands inspire confidence in its reliability?
I can firmly recommend runit if you want a server-focused, reliable init system based on the traditional Unix philosophy.
Reliability of the init system is paramount so simplicity is a key attribute.
But fork does not copy the parent process's threads. Thus locks (in memory) that in the parent process were held by other threads are stuck in the child without owning threads to unlock them, ready to cause a deadlock when code tries to acquire any of them. Also any native library with forked threads will be in a broken state.
So fork is fast, unsafe, and maybe bloated.
spawn starts a Python child process from scratch without the parent process's memory, file descriptors, threads, etc. Technically, spawn forks a duplicate of the current process, then the child immediately calls exec to replace itself with a fresh Python, then asks Python to load the target module and run the target callable.
Did you actually fix a known issue? Let the author know about it.
Want to really annoy an open-source maintainer? Then ignore any communication channels they have setup for support.
I don't expect everyone to read every single line of the code for a project they are trying to use, that isn't very reasonable. What I do see though, is that a lot developers have a mental barrier to actually opening up the source code for the project they are trying to use. They will read the documentation, run the tests, use the example code, but when they are faced with a problem that could be solved through a one or two line change in the source code, they shut down completely. The point is that you shouldn't be afraid to jump into the source code. Even if you don't fully understand the source code, in many cases you should be able to isolate your issue to a specific block. If you can reference this block ( or line numbers ) when opening up your support request, it will help the author better understand your problem.
Developers want to improve their project. If you find an issue, bring it up. If it's a valid concern, the author will probably want to have it fixed. In many cases, the author will consider it a valid issue, but simply not have the personal time or need to address it immediately. This is where open-source is great. Just fork the project and fix it
Does something about a project really bother you? Does the author not care as much about it as you do?
.
On many occasions, I've opened up requests for support in the form of a Github pull request. This way, I am telling the author: I have found a potential problem with your library, here is how I fixed it for my circumstance, here is the code I used for reference. You get extra internet points if you open the pull request with: "I don't expect this pull request to get merged, but I wanted to you show you what I did".
Not everyone has time to adhere to the specific coding styles for a project, so if you can't do a full blown pull-request, there is NOTHING wrong with opening a pull-request that only has the intention of showing the author how you solved the problem.
There are no refunds for open-source. If you go in with the attitude that you are owed something, you will be thoroughly disappointed.
On behalf of all open-source developers and project maintainers, I ask you try and be polite the next time you ask for support. Try to remember that there is a real human being on the other side of the screen, and they actually want to help you.
Don't assume that because you opened up a pull request, that the author will accept it. There are many reasons that a maintainer might choose to not merge in your specific patch, many of which have nothing to do with you. If your patch isn't accepted, try to assume it's for a valid technical reason and not because the author hates you.
If you feel there has been an oversight, it's okay to not give up. As long as you are being logical and open to other people's views, you will find that you might learn something new, or even teach something to the maintainer.
Don't get upset, rejection is normal
If the author has taken the time to write unit tests for the project, you REALLY need to confirm the unit tests work before trying to get support.
If the information you need isn't covered in the documentation, let the author know. They probably will want to add this information so other people don't ask the same question.
The point is, take the time to actually research if the maintainer has setup a specific channel for support.
You need to understand that the person you are reaching out to has probably spent 100s of hours working on this project, for free. They do not owe you anything. The maintainers are extending a courtesy by giving away their work for free and then making themselves available to support it. The point is, you should try and be nice when filing for support. The maintainer of the project has literally no obligation to help you.
input
So tell them exactly what you did. If it's a graphical program, tell them which buttons you pressed and what order you pressed them in. If it's a program you run by typing a command, show them precisely what command you typed.
Providing your own diagnosis might be helpful sometimes, but always state the symptoms. The diagnosis is an optional extra, and not an alternative to giving the symptoms.
If you give the programmer a long list of inputs and actions, and they fire up their own copy of the program and nothing goes wrong, then you haven't given them enough information.
Try to avoid saying "It doesn't work", sentences like "it doesn't produce any output" are far better.
That's not enough to help you.
In particular, one thing that fork() doesn’t copy is threads. Any threads running in the parent process do not exist in the child process.
it’s time for a deep-dive into Python brokenness and the pain that is POSIX system programming, using exciting and not very convincing shark-themed metaphors!
A conundrum wherein fork() copying everything is a problem, and fork() not copying everything is also a problem.
may not actually be a dilemma, if there is a 3rd option...
Disable all observers in your test suite by default. They should not be complicating your model tests because they should have separate concerns anyway. You don't need to unit test that observers actually fire, because ActiveRecord's test suite does that, and your integration tests will cover it.
I emphatically disagree with BlueFish about observers being difficult to properly unit test. This is precisely the biggest point that distinguishes them from lifecycle callbacks: you can test observers in isolation, and doing so discourages you from falling into many of the state- and order-heavy design pitfalls BlueFish refers to (which again I think is more often true of lifecycle callbacks).
Rails' observers were partly inspired by aspect-oriented programming -- they're about cross-cutting concerns. If you're putting business logic in observers that is tightly coupled to the models they're observing, you're doing it wrong IMO.
I've been a UK resident for over 70 years, have two degrees from a very well known university, and find both zeros and zeroes quite acceptable as the plural form. So our perceptions are different. Do we toss a coin, or see who can shout the louder? ... Dictionaries are less open to subjective bias than individuals because of the averaging effect of carefully controlled large surveys (and acceptability is usage driven). It's good to realise that personal preferences may not be the best basis for judging correctness.
Note that dictionaries document the (current, at the time of going to press) usage of language, they aren't authoritative. 'Correct' is what is in common usage and largely understood to be correct, even if that contradicts a dictionary (in which case the dictionary is probably out-of-date).
Looks well-written, but probably not needed in a Rails project, which already has ActiveSupport for dealing with duration and periods
This functionality is used by LSync for performing backup rotation (i.e. deleting old backups).
Looks like LSync was renamed to synco https://github.com/ioquatix/synco
seems to auto-add this header:
header['List-Unsubscribe'] = "<#{Caffeinate::UrlHelpers.caffeinate_subscribe_url(mailing.subscription)}>"
:
after_commit on: :create do OnboardingDripper.subscribe!(self) end
drip engine for managing, creating, and performing scheduled messages sequences
What's wrong with this?
You're checking state in a mailer
It's going to be so fun to scale when you finally want to add more unsubscribe links for different types of sequences
If you have anything like this is your codebase, you need Caffeinate:
Is this thing dead? No! Not at all! There's not a lot of activity here because it's stable and working!
Fingerprint Integration
rotate
prune
Synco is a tool for scripted synchronization and backups. It provides a custom Ruby DSL for describing backup and synchronization tasks involving one more more system and disk. It is designed to provide flexibility while reducing the complexity multi-server backups.
Unfortunately, each of these systems is highly complex and can inflict all kinds of damage on data, much of the damage undetectable to humans.
Fingerprint is a general purpose data integrity tool that uses cryptographic hashes to detect changes in files and directory trees. The fingerprint command scans a directory tree and generates a fingerprint file containing the names and cryptographic hashes of the files in the tree. This snapshot can be later used to generate a list of files that have been created, deleted or modified. If so much as a single bit in the file data has changed, Fingerprint will detect it.
In cases where I've been concerned about the migration of data (e.g. copying my entire home directory from one system to another), I've used fingerprint to generate a transcript on the source machine, and then run it on the destination machine, to reassure me that the data was copied correctly and completely.
The terminology is used a little loosely
\begingroup This conflates general-purpose hash functions as used in e.g. data structures, which do indeed just aim to create 'buckets' of things, with cryptographic hash functions, whose aim it is to not allow finding any two documents with the same hash value.
hash digest returns an alphanumeric message which is the digest. that is incorrect, this alphanumeric message is a representation of the digest. The digest itself is a string of bits with a fixed length
# Plural is preferred, as in "1 or more days".
def initialize(count = 1, unit = :days)
gems.rb
Why is it called gems.rb instead of Gemfile? I do like that it has an .rb extension.
platform built on top of Utopia and Relaxo.
xnode view layer
Utopia is a content-centric web application platform. It leverages the file-system to provide a mapping between logical resources and files on disk.
Designed for both content-based websites and applications. Does not depend on a database.
Utopia is a website generation framework which provides a robust set of tools to build highly complex dynamic websites. It uses the filesystem heavily for content and provides functions for interacting with files and directories as structure representing the website.
My long term vision for Falcon is to make a web application platform which trivializes server deployment. Ideally, a web application can fully describe all its components: HTTP servers, databases, periodic jobs, background jobs, remote management, etc. Currently, it is not uncommon for all these facets to be handled independently in platform specific ways. This can make it difficult to set up new instances as well as make changes to underlying infrastructure. I hope Falcon can address some of these issues in a platform agnostic way.
As web development is something I'm passionate about, having a server like Falcon is empowering.
Relaxo is a transactional database built on top of git.
Relaxo uses the git persistent data structure for storing documents. This data structure exposes a file-system like interface, which stores any kind of data.
In practice, forks and threads are at odds with each other. If you try to fork while there are active threads, you will very likely run into bugs. Even if you didn't create the thread, some other library might have, so it can be very tricky in practice.
The small prefixes were also added, even without such a driver, in order to maintain symmetry.
Multithreading is a widespread programming and execution model that allows multiple threads to exist within the context of one process. These threads share the process's resources, but are able to execute independently.
mailer
Should this be mailing ?
This looks at Caffeinate::Mailing records where send_at has past, skipped_at is nil, and the associated Caffeinate::CampaignSubscription is has empty ended_at and unsubscribed_at values.
AbandonedCartDripper
For example, if you are Netflix and have a Subscription and a WatchHistory object. If a user does not finish watching a video, you may want to remind them that they can finish watching it. If their subscription lapses, you may want to also remind them in a separate campaign.
It has two relations that are similar, but different: subscriber, and user. The concept here is that a User may have many objects that are relevant to warrant their own Campaign. For this reason, we include this as a default. For example, if you are Netflix and have a Subscription and a WatchHistory object. If a user does not finish watching a video, you may want to remind them that they can finish watching it. If their subscription lapses, you may want to also remind them in a separate campaign. So, you'd have separate Caffeinate::CampaignSubscription objects where the subscriber is the relevant Subscription object or the WatchHistory object, and the user is the User.
the terms allowance and tolerance are used inaccurately and are improperly interchanged
“Accuracy” indicates the closeness of a measurement to the true value but it cannot be quantified because it is not possible to know the true value.
Updated
Sure, it is not needed, we can always write things in a different way. As a matter of fact, with such an argument, hardly any improvement should be accepted.
In practice when people use ||, they do mean ?? (whatever its spelling). It just so happens that most of the time, it does what you want, because you happen to not be dealing with Booleans. But the semantics you mean to express is not about "truthness", but about "nilness". And occasionally you get bitten because false does exist, and behaves differently.
Here's example code which works around the lack of a ??= operator in the wild:
In comparison, Perl/Python/Javascript, which also have the latter property, have other false-like values (0 and empty string), which make || differ from a null-coalescing operator in many more cases (numbers and strings being two of the most frequently used data types). This is what led Perl/Python/Javascript to add a separate operator while Ruby hasn't.
Examples by languages
the first operand evaluated to a value likened to logically false, in other words, a falsy value
f that operand evaluates to a value likened to logically true (according to a language-dependent convention, in other words, a truthy value)
And, of course, I'm grateful to be reunited with my long lost friend, false.
However, this idiom is only an approximation, and introduces subtle bugs when we try to allow false values:
Ruby, as a community, unfairly discriminates against false, and it needs to stop.
false is a perfectly non-nil object, and you're excluding it out of convenience!
Decimals are commonly used to approximate real numbers. By increasing the number of digits after the decimal separator, one can make the approximation errors as small as one wants, when one has a method for computing the new digits.
For example, the bathroom scale may convert a measured extension of a spring into an estimate of the measurand, the mass of the person on the scale. The particular relationship between extension and mass is determined by the calibration of the scale.
imperfect / not exact / not directly measured
The resolution is related to the precision with which the measurement is made, but they are not the same thing. A sensor's accuracy may be considerably worse than its resolution.
with stating it as the implied uncertainty (to prevent readers from recognizing it as the measurement uncertainty)
Round half to even, which rounds to the nearest even number. With this method, 1.25 is rounded down to 1.2. If this method applies to 1.35, then it is rounded up to 1.4. This is the method preferred by many scientific disciplines, because, for example, it avoids skewing the average value of a long list of values upwards.
For example, if the length of a road is reported as 45600 m without information about the reporting or measurement resolution, then it is not clear if the road length is precisely measured as 45600 m or if it is a rough estimate.
That right there almost works. It'd be incredible if it did because I love the way that reads.
The snag is that when the top-level match grabs the published_at value and applies it to the be_within(...), it is working with a string representation of the timestamp. We first need to parse that into a date object and there is no affordance for that here.
RSpec gives us the tools to make custom matchers so that we can preserve all the expressiveness while adding specialized or even domain-specific matchers.
If you'd like another method to do the waiting for you, e.g. Kernel.select, you can use Timers::Group#wait_interval to obtain the amount of time to wait. When a timeout is encountered, you can fire all pending timers with Timers::Group#fire
This is another way of achieving concurrency (progress made while waiting for other things) besides wrapping the timer's sleep in a separate thread like https://github.com/rubyworks/facets/blob/main/lib/standard/facets/timer.rb does.
I'm a company
I'm a developer
A concurrent system is one where a computation can advance without waiting for all other computations to complete.
new tag: display/view for audience
Envfile
Like the concept but don't like how you have to have a separate Envfile. (Maybe you don't and can use it directly?)
# booleans # simple: providing any value for ENV['FORCE_SSL'] means `true`: force_ssl = !!ENV['FORCE_SSL'] # more advanced: # only when we provide 'true' will `force_ssl` become true. force_ssl = ('true' == ENV['FORCE_SSL'])
variable :FORCE_SSL, :boolean, default: '1'
You can define a coercion to some type via definition
fiels :tags, Array, of: String
But nothing of them supports all features I need for:
I've explored these projects: Reform Mutations Interactor dry-rb
But you're able to remove (usually inherited) fields by: class ChildForm < ParentForm remove_field :field_from_parent end
Fields and nested forms are filling in order of their definition. But sometimes you want to change this order, for example, if you have a nested forms in ancestors which depends on data in children forms. For such cases you can use :depends_on option, which accepts fields and nested forms names as Symbol or Array of symbols. They will be filled (and initialized) before dependent.