Re: Django App DB replicas - call for suggestions

2015-02-21 Thread Lane Campbell
To accomplish what you've explained you could move forward with the app on the 
PI for the clients.  Each client would need to sync with a database somewhere.  
To achieve this I would explore how to individualize and track each machine in 
the field.  Then setup another django app in the cloud somewhere that has an 
api these clients are designed to access.  Set the sync interval at a low 
enough point that the user experience is good, but set it high enough that your 
server doesn't get overloaded.  

Sent from my iPhone

> On Feb 21, 2015, at 8:45 AM, Blazor  wrote:
> 
> Hi all,
> 
> I was asked to design a new django app by a client whose needs are a little 
> bit context-specific.
> 
> The purpose of this app is to introduce computer-assisted technologies in a 
> paper-based environment, in the e-Health domain. This client would like to 
> access a central server with a few mobile clients with the constraint of a 
> non-permanent internet connection, because the location of the mobile clients 
> is continuously changing and an internet connection might not always be 
> available.
> 
> My current idea is based on a portable small server (a nettop, or even a 
> raspberry pi, as the computing power is not a problem for this app) with a 
> django app on it and a wireless access point for providing mobile clients 
> with an always-on portable server reachability. At the same time, I'd like 
> other clients around the world (a very little number, though) to still be 
> able to access a central remote version of the same service, so I'd still 
> deploy the same app (with its own DB replica) within a remote server.
> 
> I hope I made my client's requirements clear: how would you manage the 
> synchronization between the two DBs, given that both DBs need a write access 
> and that the only relaxation of this constraint is that when the portable 
> server is on, the remote DB might work in a read-only mode (but this is not 
> required).
> 
> Thanks in advance for any suggestions you'll provide me with.
> B.
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/django-users.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/django-users/bb65e66c-4788-4010-9bfe-b8f20e41e5d1%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/1FE36215-A5B3-4BB9-9ED8-3A6123EDE88D%40strapr.com.
For more options, visit https://groups.google.com/d/optout.


Re: Django Tutorial Equivalent to Ruby on Rails Tutorial by Michael Hartl

2015-02-22 Thread Lane Campbell
Zach,

I am new to software development, I've spent years on the other side of the
spectrum working in telecom and infrastructure.  I joined this group to
learn more about Python and Django.  A developer I spoke with last week at
 Chicago Python (chipy.org) meetup event introduced me to the concept of
Behavior Driven Development and using Gherkins.  Since you shared this
maybe you wouldn't mind helping me understand the difference between TDD
and BDD?  Are there pros/cons to the two that are worth knowing about?

I've been reading about this tool:
http://lettuce.it/recipes/django-lxml.html#recipes-django-lxml

Any help/advice is appreciated!


Regards,
Lane Campbell
(312) 775-2632

On Sun, Feb 22, 2015 at 5:28 PM, Zach Swift  wrote:

> I realize this post is several years old, but this is for anyone still
> looking for an up to date Django tutorial on par with Michael Hartl rails
> tutorial. Here it is:
>
>
> The title of the book is very deceiving. Its a book about web development
> with python using django but doing it with test driven development.
>
> https://books.google.com/books?id=fTLJAwAAQBAJ&pg=PR2&dq=test+driven+development+with+python&hl=en&sa=X&ei=nmLqVNOqENGvyASPkIDYDA&ved=0CCcQ6AEwAg#v=onepage&q&f=false
>
> I say it's on par with Michal Hartl's because of these things:
>
> 1. You learn more of the generalities of web development instead of the
> scope being laser focused on django stuff only (like most django books out
> there assuming you already know web development)
>
> 2. It's a project based, where you build a web application with python and
> Django throughout the book.
>
> 3. Like the Hartl tutorial, you are also learning test driven development
> and Git along the way.
>
>
>
> On Monday, October 22, 2012 at 11:58:25 AM UTC-5, Tommy DANGerous wrote:
>>
>> Thanks everyone for the help. I've gone through several tutorials, such
>> as the one on the Django website and at http://lightbird.net/dbe/. Just
>> trying to get more familiar with Django before I start trying to write it
>> on my own. I'll take a look at the Django Book and the youtube videos you
>> all posted. Thank you for all the help!
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/django-users.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/2e4294cf-b9b8-4be3-9cf6-fc312113c3ba%40googlegroups.com
> <https://groups.google.com/d/msgid/django-users/2e4294cf-b9b8-4be3-9cf6-fc312113c3ba%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CADQXWrWyv2VJG%3Dwsb%3DCwsnxwwtXCxkbo4Cq5-H8xY%2BhZE0gCTw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Chicago Django Study Group

2015-03-31 Thread Lane Campbell
Hello All,

I'm hosting a weekly study group in Chicago. If anyone on the list is 
interested in stopping in and joining us please register (it's 
free): 
http://www.eventbrite.com/e/chicago-django-study-group-april-5th-2015-tickets-16386027048

Regards,
Lane

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/d36e7b70-52df-4201-b84d-945a8404ca87%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: job portal using django

2020-09-24 Thread Lane Campbell
There are a lot of tutorials for creating apps in Django that store and
read data submitted by users.

You can adapt the instructions to create a job portal.



On Thu, Sep 24, 2020 at 7:19 PM Ayush Shukla  wrote:

> is there any tutorial on creating job portals (like indeed ) using django
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/a0915fd4-d33b-4333-8d05-74664b047c44n%40googlegroups.com
> 
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CADQXWrUzur0skHNGvhxVynJ%2BtDEkm_G10-%2Bo64kbEhgeUBj-Ew%40mail.gmail.com.


Re: Apple M1 Silicon + Django = weird results

2021-01-09 Thread Lane Campbell
I'd put the code up on an x64 virtual machine and see if it behaves as
expected. If the issues are still present then you know it's not M1
related.



On Sat, Jan 9, 2021 at 11:57 PM Mike Dewhirst  wrote:

> In principle, Django and Python and anything else you can program incuding
> the database are completely independent of the lower layers of the IP
> stack.
>
> I would restore the infrastructure to manufacturer's defaults and test
> again.
>
> Removing unknowns is always a good start in debugging.
>
> Good luck
>
> Mike
>
>
>
> --
> (Unsigned mail from my phone)
>
>
>
>  Original message 
> From: Benjamin Schollnick 
> Date: 10/1/21 15:41 (GMT+10:00)
> To: django-users@googlegroups.com
> Subject: Re: Apple M1 Silicon + Django = weird results
>
> Okay, a further update.
>
> While rewrite the code, did seem to make a marginal difference, the
> corruption issue persisted intermittently.
>
> Just today, I did some more digging, and I remembered that I turned on
> Jumbo Frames for my ethernet port on the M1 Mac Mini.
>
> Turning that off, at first glance, seems to have resolved the corruption
> issue…
>
> I’m unclear if this is an Django, Rosetta 2, Big Sur, or M1 Mac mini
> hardware issue (or a combination of factors).
>
> I can’t check, but I’d swear that I had Jumbo frames turned on with My
> Catalina 2013 iMac.
>
> Any ideas or suggestions?
>
> - Benjamin
>
>
>
> On Dec 22, 2020, at 6:46 AM, Benjamin Schollnick <
> bscholln...@schollnick.net> wrote:
>
> Just an update.
>
> Working my way through the problem, it appears that either the data is
> being written truncated to the database, or Pillow is generating a
> truncated image preview (which is being stored to the database).
>
> The later is more likely, since I am seeing no other data corruption
> errors.
>
> Rewriting the thumbnail delivery code, seemed to reduce the amount of
> downloading issues, but they are still not Non-Zero…
>
> But I may just have to live with this, since there are too many moving
> parts to be able to point a finger at any one bit of code.  (It could be
> rosetta 2 overly optimizing the code in some way…  etc.)
>
> Plus, It might be time for me to just simply start rewriting the code from
> the ground up again, to better optimize and clean it up.
>
> - Benjamin
>
>
>
> On Dec 21, 2020, at 10:52 PM, Benjamin Schollnick <
> bscholln...@schollnick.net> wrote:
>
>
> Have you tried the download with various browsers? I wonder if Safari or
> Chrome released at the same time as the M1 chips is causing different Range
> header behavior than that code is designed to handle. So it might not be
> the M1 chip, but just an unrelated change in browser software that got
> pushed out at the same time. Speculating here.
>
>
> The only issue that I see, is that I started to use RangedFileResponse to
> allow the viewing of MP4, and other media files in the browser…  (
>
> So I know it works at least in that regard.
>
> But for debugging purposes, I’ll switch it around…
>
> - Benjamin
>
>
>
> On Mon, Dec 21, 2020 at 3:19 PM Benjamin Schollnick <
> bscholln...@schollnick.net> wrote:
>
>> Folks,
>>
>> I’m using django for an online gallery application, and I’ve seen some
>> weird results since switching over to the M1 Mac Mini.
>> (Please note, I am running it under Rosetta / Intel Translation, since
>> pillow doesn’t seem to build under M1 native).
>>
>> So this could be a quirk of Rosetta, Django, or some combination of these.
>>
>> I don’t think so, but it could be.
>>
>> *So What is happening?  *
>>
>> I never saw this under my 2013 intel iMac, but now under M1 (even under
>> Rosetta 2 / Intel translation) I am receiving a damaged / altered download
>> file roughly 6 out of 8 or 9 times (~25-33% successful).
>>
>> Just retrying the download will eventually be successful.
>>
>> This isn’t Pillow related, since the file is just being downloaded
>> directly (no thumbnails or alterations to the file is occurring).
>>
>> Does anyone have a suggestion on what to do at this time?  I’m uncertain
>> on where to start to dig.  Although removing ranged_response, might be a
>> starting point…
>>
>> URLs:
>> path("download/", frontend.views.new_download,
>> name="downloads"),
>> path('thumbnails/', frontend.views.thumbnails,
>> name="raw thumbnails"),
>>
>>
>> First, I am using these function for all graphics and/or file(s) being
>> sent:
>>
>> def new_download(request, d_uuid=None):
>> page = request.GET.get('page', None)
>> if page is None:
>> download = index_data.objects.filter(uuid=d_uuid,
>>  ignore=False,
>>  delete_pending=False)[0]
>> else:
>> print ("Attempting to find page %s in archive" % page)
>> print("\tDownloading - %s, %s" % (download.fqpndirectory.lower(),
>>   download.name))
>> return respond_as_inline(request,
>>  "%s%s%s"