diff --git a/rowers/dataprep.py b/rowers/dataprep.py index 9744b6b9..b6dbad35 100644 --- a/rowers/dataprep.py +++ b/rowers/dataprep.py @@ -518,7 +518,7 @@ def dataprep(rowdatadf,id=0,bands=True,barchart=True,otwpower=True, try: drivespeed = drivelength/rowdatadf[' DriveTime (ms)']*1.0e3 except TypeError: - drivespeed = 0.0*rowdatadf['TimeStam (sec)'] + drivespeed = 0.0*rowdatadf['TimeStamp (sec)'] drivespeed = drivespeed.fillna(value=0) driveenergy = drivelength*averageforce*4.44822 diff --git a/rowers/models.py b/rowers/models.py index 878929b4..303b4b76 100644 --- a/rowers/models.py +++ b/rowers/models.py @@ -532,5 +532,11 @@ class SiteAnnouncement(models.Model): self.expires = timezone.now()+datetime.timedelta(days=10) self.modified = timezone.now() if self.dotweet: - status = tweetapi.PostUpdate(self.announcement) + try: + status = tweetapi.PostUpdate(self.announcement) + except: + try: + status = tweetapi.PostUpdate(self.announcement[:135]) + except: + pass return super(SiteAnnouncement,self).save(*args, **kwargs) diff --git a/rowers/stravastuff.py b/rowers/stravastuff.py index 954f4dee..bc3c354f 100644 --- a/rowers/stravastuff.py +++ b/rowers/stravastuff.py @@ -247,13 +247,20 @@ def createstravaworkoutdata(w): def handle_stravaexport(file,workoutname,stravatoken,description=''): # w = Workout.objects.get(id=workoutid) client = stravalib.Client(access_token=stravatoken) - - act = client.upload_activity(file,'tcx',name=workoutname) - res = act.wait(poll_interval=5.0) + try: + act = client.upload_activity(file,'tcx',name=workoutname) + res = act.wait(poll_interval=5.0) - # description doesn't work yet. Have to wait for stravalib to update - act = client.update_activity(res.id,activity_type='Rowing',description=description) + # description doesn't work yet. Have to wait for stravalib to update + act = client.update_activity(res.id,activity_type='Rowing',description=description) + except: + with open("media/stravaerrors.log","a") as errorlog: + errorstring = str(sys.exc_info()[0]) + timestr = time.strftime("%Y%m%d-%H%M%S") + errorlog.write(timestr+errorstring+"\r\n") + errorlog.write("stravastuff.py line 262\r\n") + # w.uploadedtostrava = res.id diff --git a/rowers/templates/about_us.html b/rowers/templates/about_us.html index e562c356..a57e5e3a 100644 --- a/rowers/templates/about_us.html +++ b/rowers/templates/about_us.html @@ -130,6 +130,10 @@ You will be taken to the secure PayPal payment site. "instructions to seller".
+After you do the payment, we will manually change your membership to + "Pro". Depending on our availability, this may take some time + (typically one working day). Don't hesitate to contact us + if you have any questions at this stage.